Open srijs opened 8 years ago
Ops! This PR seems to have triggered a regression in the test suite (or simply our test suite is not very good and this is a transient failure). In any case, these are my sparse comments (typed at 8:26AM, where I'm still half-asleep, so ignore the nonsense, if any):
shutdownSupervisor
accordingly or run this cleanup code in the Left
branch of the forkFinally
call (which acts as a bracket
, essentially).Message
s).So, in a nutshell:
Thanks!
Hi @adinapoli!
Let me attempt a proof by construction to show that the concrete #5 case is still an issue with epochs. You obviously know the internals better than me, so you might be able to disprove me here:
It may be possible to fix the issue by making the shutdownSupervisor aware of epochs as well, but since we already defined a more general solution to data race conditions, I figured we might just as well solve it directly like that.
How I imagine it working with the queued Shutdown instruction:
What would happen with a queued Shutdown instruction, if the order of steps 3 and 4 is reversed:
Hey @srijs , thank you very much for this! It was exactly the kind of proof of construction I needed to see things clearly. Sorry if I gave the impression of not play it constructively here, but I think such "rubber duck debugging" are super useful and I feel we are really on the same page. I now see the value of your proposal!
Not intending to merge this yet, purely to illustrate a possible solution to the problem outlined in #5.