Skip to content
Discussion options

You must be logged in to vote

I looked at the uniqueness feature but my understanding is that I cannot exclude already running jobs from the constraint, is that correct?

Yeah that's correct. Running is a required state in the unique states list.

I should point out first that either the pro features sequences or batching would be a reasonable way to approach this problem.

Aside from those, one thing you could do is use unique jobs, but include an identifier in the args for the largest known ID that had to be processed, and make the jobs unique on args.

So if two operations were to insert jobs for the same work that'd produce a no-op, you'd insert:

{"last_operation_id":123}
{"last_operation_id":123}

These would dedup…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@vblcc
Comment options

Answer selected by vblcc
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants