File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -11,7 +11,7 @@ use database::{
11
11
} ;
12
12
use parking_lot:: RwLock ;
13
13
use std:: { str:: FromStr , sync:: Arc } ;
14
- use tokio:: time:: { self , Duration } ;
14
+ use tokio:: time:: { self , Duration , MissedTickBehavior } ;
15
15
16
16
pub fn run_new_queue ( ) -> bool {
17
17
std:: env:: var ( "RUN_CRON" )
@@ -372,6 +372,8 @@ async fn cron_enqueue_jobs(ctxt: &SiteCtxt) -> anyhow::Result<()> {
372
372
/// Entry point for the cron job that manages the benchmark request and job queue.
373
373
pub async fn cron_main ( site_ctxt : Arc < RwLock < Option < Arc < SiteCtxt > > > > , run_interval : Duration ) {
374
374
let mut interval = time:: interval ( run_interval) ;
375
+ interval. set_missed_tick_behavior ( MissedTickBehavior :: Delay ) ;
376
+
375
377
let ctxt = site_ctxt. clone ( ) ;
376
378
377
379
loop {
You can’t perform that action at this time.
0 commit comments