You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In my use case i need the ability to refresh or change a specific repeatable jobs repeat limit (and reset the current count). For example, let's say i create a job with the following...
Let's say this job has been processing away for a while and has complete 90 of its 100 iterations. How would i go about refreshing the job so that it continues with another 100 iterations, or allow me to change the limit and reset the count without skipping an iteration?
I know i can remove the repeatable job by key, and add another job in its place. But wouldn't that cause potential issues in edge cases, such as if the remove function was called whilst a job is actually processing in a worker? Or leave an orphan delayed job that would run alongside our new repeatable job?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
In my use case i need the ability to refresh or change a specific repeatable jobs repeat limit (and reset the current count). For example, let's say i create a job with the following...
await myQueue.add( 'myjobtype', { u_id: 1 }, { repeat: { pattern: '30 * * * * *', limit: 100, }, }, );
Let's say this job has been processing away for a while and has complete 90 of its 100 iterations. How would i go about refreshing the job so that it continues with another 100 iterations, or allow me to change the limit and reset the count without skipping an iteration?
I know i can remove the repeatable job by key, and add another job in its place. But wouldn't that cause potential issues in edge cases, such as if the remove function was called whilst a job is actually processing in a worker? Or leave an orphan delayed job that would run alongside our new repeatable job?
Beta Was this translation helpful? Give feedback.
All reactions