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

   ### Motivation
   `AsyncWriteJournal` can emit an entire recovery stream without waiting for 
the recovering actor to process it. A large journal can therefore enqueue an 
unbounded number of replay messages in the persistent actor mailbox and exhaust 
the heap.
   
   ### Modification
   - Add configurable, acknowledged replay batching with a default batch size 
of 1000.
   - Let classic and typed persistent actors opt in while retaining the 
existing `ReplayMessages` request for compatibility with journal plugins that 
do not understand batching.
   - Preserve replay limits, ordering, sender semantics, replay-filter state, 
cancellation, and recovery isolation across actor or journal restarts.
   - Forward the batching protocol through the persistence plugin proxy.
   - Add focused classic, typed, replay-filter, protocol, and remote-proxy 
regression coverage.
   - Document the replay batching behavior and configuration.
   
   ### Result
   Recovery bounds the number of replayed events in flight without truncating 
recovered history. Existing journal plugins continue to use the legacy replay 
path unless they support the opt-in batching marker.
   
   ### Tests
   - Focused classic protocol, replay filter, and replay batching tests: 24 
passed
   - Focused typed replay batching tests: 2 passed
   - `sbt "persistence / Test / test"`: 63 passed; LevelDB JNI emitted an Apple 
ARM64/x86 architecture warning
   - `sbt "persistence-typed-tests / Test / test"`: 204 passed
   - `sbt "persistence-shared / Test / testOnly 
org.apache.pekko.persistence.journal.leveldb.PersistencePluginProxySpec"`: 1 
passed
   - `sbt headerCreateAll`, `sbt +headerCheckAll`, `sbt checkCodeStyle`, `sbt 
docs/paradox`, and `sbt +mimaReportBinaryIssues`: passed; Paradox reported 
duplicate-anchor warnings
   - `scalafmt --list --mode diff-ref=origin/main` and `git diff --check`: 
passed
   - `sbt sortImports`: environment/task failure; the project-scoped key was 
unavailable and root scalafix raised `NoSuchMethodError`
   - `sbt validatePullRequest`: ran for 28m26s and failed on this macOS ARM64 
host because LevelDB JNI 1.8 contains x86 binaries; unrelated docs tests also 
failed from a missing `pekko.dispatch.UnboundedMailbox` class and UDP multicast 
timeouts on all local interfaces
   
   ### References
   Fixes #3241


-- 
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