-
-
Notifications
You must be signed in to change notification settings - Fork 200
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Race condition with concurency control #378
Comments
Thanks for documenting this. I have an explanation for why it's happening, but unfortunately, I don't have a solution as I think it's inherent in the reason why Here's what's happening:
The problem lies within the #317 happened to prevent a raise-condition on I will think some more about this and please tell me if what I wrote here helps you understand what's happening. |
@bensheldon thanks for explaining, it does make sense. I can confirm it is correct. The number of extra jobs is linked to the number of worker threads. I don't have any suggestions for fixing it, but I would recommend mentioning that in readme. E.g.
|
There is a race condition bug when the enqueued jobs can exceed the limit. I mentioned the bug in #366
Steps to reproduce (tested on de2184b):
cd spec/test_app
andbundle exec good_job start
good_jobs
table is empty (clear all rows if not)enqueue_limit: 1, perform_limit: 0
Expected: 1 job to be queued.
The text was updated successfully, but these errors were encountered: