Skip to content

Commit

Permalink
fix: fix recycler ddl computation
Browse files Browse the repository at this point in the history
  • Loading branch information
jiegec committed Mar 11, 2024
1 parent 351029c commit 8f74158
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion server/src/recycler.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ pub async fn recycler_worker_inner(pool: DbPool) -> anyhow::Result<()> {
.get()
.context("Failed to get db connection from pool")?;

let deadline = Utc::now() - chrono::Duration::try_seconds(-300).unwrap();
let deadline = Utc::now() - chrono::Duration::try_seconds(300).unwrap();
let res = jobs::dsl::jobs
.inner_join(workers::dsl::workers)
.filter(workers::dsl::last_heartbeat_time.lt(deadline))
Expand Down

0 comments on commit 8f74158

Please sign in to comment.