Skip to content

Commit f432272

Browse files
committed
Do not abort the job queue if master or release artifacts cannot be created
We do not necessarily have to enqueue these artifacts immediately, if their web resources are not working, we should still be able to continue with operating the job queue.
1 parent 8ff0df6 commit f432272

File tree

1 file changed

+16
-2
lines changed

1 file changed

+16
-2
lines changed

site/src/job_queue/mod.rs

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -391,11 +391,25 @@ async fn perform_queue_tick(ctxt: &SiteCtxt) -> anyhow::Result<()> {
391391
let mut requests_inserted = false;
392392
// Put the master commits into the `benchmark_requests` queue
393393
if insertion_enabled {
394-
requests_inserted |= create_benchmark_request_master_commits(ctxt, &*conn, &index).await?;
394+
match create_benchmark_request_master_commits(ctxt, &*conn, &index).await {
395+
Ok(inserted) => requests_inserted |= inserted,
396+
Err(error) => {
397+
log::error!(
398+
"Could not insert master benchmark requests into the database: {error:?}"
399+
);
400+
}
401+
}
395402
}
396403
// Put the releases into the `benchmark_requests` queue
397404
if insertion_enabled {
398-
requests_inserted |= create_benchmark_request_releases(&*conn, &index).await?;
405+
match create_benchmark_request_releases(&*conn, &index).await {
406+
Ok(inserted) => requests_inserted |= inserted,
407+
Err(error) => {
408+
log::error!(
409+
"Could not insert release benchmark requests into the database: {error:?}"
410+
);
411+
}
412+
}
399413
}
400414
// Enqueue waiting requests and try to complete in-progress ones
401415
let completed_reqs = process_benchmark_requests(&mut *conn).await?;

0 commit comments

Comments
 (0)