Check existing job using job Id
Closed this issue · 2 comments
leizard commented
Hi,
How can I check if a job with an existing job Id exists before calling Queue.createJob() ?
adampatarino commented
@leizard try using Kue's get function:
kue.Job.get( id, function( err, job ) {
// err - job doesn't exist
// job - found a job with that id
});
lykmapipo commented
@leizard
kue-scheduler
its just a utility on top of kue and we tried as much as we can not to over-rule kue
logics. So anything applies in kue
is same as in kue-scheduler
and infact kue-scheduler
export the same kue
queue instance.
So @adampatarino point it correctly.
Hope it helps.