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
This will allow a consumer to prevent duplicates in a very simple way.
Provide a way to replace a task with another bearing the same ID. Without a special way to do this, it will not be possible to schedule a continuation task from the processor of a task with the same ID. (Actually it is possible, using ID's that incorporate time-window counters, but that's inconvenient). How about throw new RescheduleTask() or done(new RescheduleTask())? - No, call schedule in the usual way, and it should just work - maybe with a flag to override the duplicate ID error.
Tests
The text was updated successfully, but these errors were encountered:
- Specify an ID when scheduling a task to guarantee that only one such
task will exist. This is to make it easy to prevent duplicates.
- Change rescheduling mechanism to update the `_dueAt` time and the
number of `_attempts` on the existing task object, instead of deleting
one task and creating another.
Most of the work required by #18
This will allow a consumer to prevent duplicates in a very simple way.
throw new RescheduleTask()
ordone(new RescheduleTask())
? - No, call schedule in the usual way, and it should just work - maybe with a flag to override the duplicate ID error.The text was updated successfully, but these errors were encountered: