Feature to update delayed Interval for a Job. #2138
waseem-winzo
started this conversation in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
While working on a problem I came across a scenario where I had to update delayed interval for a Job.
My use case was to only increase the delayed interval based on some event.
I had gone through DOC and Code and asked around On StackOverFlow but could not find any existing method to achieve this.
Also created a Q&A Discussion as well: Q&A discussion
So I came up with the following approach:
But this approach is not optimal, Since job.remove() is (as @manast suggested):
O(n) of the number of waiting jobs, and O(logN) for the rest of the states (which use sets)
.It would be very good to have function which can update (extend or reduce) delayed interval of an existing Job.
Beta Was this translation helpful? Give feedback.
All reactions