-
Notifications
You must be signed in to change notification settings - Fork 9
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
Some tasks go unnoticed in a simple case #61
Comments
A bit of a brainteaser. May still be some edge cases out there in which case I can take a look tmrw. |
Awesome, thanks! Looks fixed on my end. |
Fyi, these tasks were never lost - simply pre-assigned to particular servers at dispatcher as |
My initial diagnosis was actually incorrect. It was not the case that tasks were 'pre-assigned'. Hence the re-implementation in ce6b92f provides a more elegant and targeted fix. This just ensures the dispatcher loop is run again whenever a result is returned, if it would otherwise not have done. This is enough to ensure that any waiting tasks are dispatched. |
The above eliminates the need for an extra dispatcher loop. All as it should be. |
I was revisiting https://github.com/wlandau/crew/blob/main/tests/throughput/test-persistent.R just now, and I noticed a task that did not seem to register with the dispatcher. It was easy to create a quick reproducible example of this behavior with just
mirai
:When I run the code above,
daemons()$daemons
tells me that only 7 of the 10 tasks were assigned and completed:Whenever I run this with starting with
daemons(n = 4)
, the number of tasks assigned/completed is always 7. And interestingly, ifn = 2
, then assigned and completed both are 9. Trying a grid ofn
values from 1 to 10, I always seen
+ assigned = 11. For n > 10, I see assigned = 1 and completed = 1.I tried
mirai
versions 0.8.7.9006, 0.8.7, and 0.8.4, all with the same result.nanonext
is at 0.8.3.9001. Findings are the same on both my local Ubuntu machine and my Macbook.nanonext::nng_version()
returnsc("1.6.0pre", "mbed TLS 3.4.0")
on both machines.The text was updated successfully, but these errors were encountered: