gue icon indicating copy to clipboard operation
gue copied to clipboard

prevent enqueuing same job,

Open mcbenjemaa opened this issue 1 year ago • 3 comments

Any idea how to prevent enqueuing same job?

Maybe like if a job with same args exists More then 3 then we can prevent enqueuing it again?

mcbenjemaa avatar Jun 22 '23 10:06 mcbenjemaa

Same as in https://github.com/vgarvardt/gue/issues/197 - jobs do not know anything about other jobs unless you implement some additional functionality to track created jobs. This is simple queuing system focused on strong consistency.

vgarvardt avatar Jun 22 '23 10:06 vgarvardt

I'm facing a similar problem where i don't want to enqueue certain jobs multiple times. My case would be solved if i have control over the generated id in the execEnqueue func, thinking about creating a PR for this...

Insteadof avatar Jul 12 '23 15:07 Insteadof

just an idea but i am tend to have a brainstorm here about this issue, could we generate the task id based on the other columns. like similar to sonyflake?

so that if an identical task in enqueued into the jobs gue can discard it automatically

berkantay avatar Aug 31 '23 12:08 berkantay