-
Notifications
You must be signed in to change notification settings - Fork 137
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
Tasks get schedules multiple times when multiple workers are running #9
Comments
Interesting, that no one found that sooner - or that I didnt see any issues with it in the past. |
Yesterday I couldn't come up with a solution and I was wondering if you had any ideas. But I'll give it another go. :) |
Closing in favor of the PR. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi Mark,
I found a bug, but I don't quite know how to solve it. I'm seeing tasks rescheduled to quickly before timeout has passed. I nailed it down to this line:
Model/QueuedTask.php:154
The problem here is that you reference to $task which is part of the loop a few lines higher. This results in always the last element. Since I use your Plugin and plugins are parsed later the last (alphabetically) task's timeout wins. Which is always 10 seconds.
So, when 10 seconds are passed, the task is rescheduled when other un-finished tasks are also found. (Otherwise another if-statement catches it.)
Any ideas for fixes?
Greetings,
Rik
The text was updated successfully, but these errors were encountered: