Make ctx.abort() (for stateless workers) non-experimental. - #6930
Conversation
It's difficult to actually make this happen (required a low-level C++ test), but theoretically possible that an IoContext could become aborted while we waited for the isolate lock, after we'd already checked the abort exception. Re-checking again after locking solves the problem. (Bug identified, fixed, and tested by Fable 5.)
|
I notice the difference in style: line 1348 uses Let me also check the Looking at the test: Actually, looking at the test flow:
After both promises are waited on, This all looks correct. The changes are clean and well-tested. The only potential concern would be the types snapshot, but that's handled by CI (it will fail if the snapshot isn't regenerated). The PR description addresses all the original TODO items that were blocking the feature from going GA. LGTM |
|
The generated output of |
Merging this PR will not alter performance
Comparing Footnotes
|
All of the concerns in the TODO bullet points had already been addressed: * We already use TerminateExecution(). * Abort handling has been significantly refactored closing most ways that code could keep running after abort. One remaining issue was fixed in the previous commit. * The refactoring of abort handling also ensured that the correct exception propagates. * All event handler paths were verified as respecting abort. * The Durable Object version was un-gated a long time ago. (Fable 5 reviewed the code to verify all this.)
d0ccd7f to
322d59b
Compare
All of the concerns in the TODO bullet points had already been addressed: