fix: also dispatch right away
This commit is contained in:
parent
9a260a14c3
commit
205b729f16
2 changed files with 3 additions and 1 deletions
|
@ -72,7 +72,7 @@ pub async fn post(
|
|||
|
||||
model::job::Entity::insert(job).exec(ctx.db()).await?;
|
||||
|
||||
ctx.wake_workers();
|
||||
ctx.wake_workers(); // process immediately
|
||||
|
||||
Ok(CreationResult(aid))
|
||||
}
|
||||
|
|
|
@ -148,5 +148,7 @@ pub async fn process(ctx: Context, job: &model::job::Model) -> crate::JobResult<
|
|||
|
||||
tx.commit().await?;
|
||||
|
||||
ctx.wake_workers(); // dispatch immediately
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue