He-Pin opened a new pull request, #3331:
URL: https://github.com/apache/pekko/pull/3331

   ### Motivation
   
   Fork-join workers can execute another submitted dispatcher batch on the same 
worker while helping a `ForkJoinTask` join. `BatchingExecutor` rejected that 
nested `Batch.run` or `BlockableBatch.run` invocation, producing `requirement 
failed` before the nested tasks could run.
   
   ### Modification
   
   - Preserve and restore the previous batching context around both regular and 
blockable batch execution.
   - Add a deterministic regression test for both `resubmitOnBlock` modes and 
verify that the outer batch continues draining its queued work.
   - Document nested fork-join dispatcher execution and retain the 
dedicated-dispatcher guidance for external blocking.
   
   ### Result
   
   Reentrant batches execute without failing or losing the outer batch's queued 
work. The normal path reuses the existing `ThreadLocal.get`, adds no allocation 
or locking, and only adds a predictable null branch before the existing 
`ThreadLocal.remove`.
   
   ### Tests
   
   - `sbt "+actor-tests / Test / testOnly 
org.apache.pekko.dispatch.ExecutionContextSpec"` - passed: 13 tests on Scala 
2.13.18 and 13 tests on Scala 3.3.8.
   - `sbt headerCreateAll +headerCheckAll checkCodeStyle "docs / paradox"` - 
passed.
   - `sbt +mimaReportBinaryIssues` - passed on Scala 2.13.18 and Scala 3.3.8.
   - `scalafmt --list --mode diff-ref=origin/main` - passed.
   - `git diff --check` - passed.
   - `sbt validatePullRequest` - not completed; interrupted at requester 
direction (exit 130) during the long-running impacted-module suite. An earlier 
forked test JVM exited with code 255, so this run is not reported as passing.
   - Qoder CLI blocker review - No must-fix findings.
   
   ### References
   
   Fixes #1708
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to