fix(#5295): gate RocketMQ 5 POP broker ACK on distribution completion (PR #5316, with both contributor trailers) - #5336
Merged
qqeasonchen merged 1 commit intoSep 7, 2026
Conversation
…letion (PR apache#5316) Combined re-land of the four earlier apache#5330 / apache#5331 / apache#5333 / apache#5334 commits (all reverted by apache#5335) as a single commit on develop. The barrier logic is zhang-arvin's original contribution from PR apache#5316, ported onto the post-apache#5301-Sub-PR-B/C UniIngressService structure (apache#5311 / apache#5312 rewrote the deliver path): - Shared mqAck (first ACK = broker ACK, premature for BROADCAST/MULTICAST) -> per-frame AtomicInteger initialized to targets.size(); broker ack only fires when the last required delivery ACKs (counter reaches 0). - LOAD_BALANCE (1 target): 1 ACK -> broker ACK (semantic unchanged). - BROADCAST (N targets): N ACKs -> broker ACK. - MULTICAST (matched targets): all matched ACKs -> broker ACK. - No popCk path: unchanged (null callback, no broker ack). - Reuses SubscriptionManager.targetsFor(); preserves existing TTL check, Otel span, metrics, and Frame-architecture context. Attribution: - Source-level Javadoc in UniIngressService.java (3-line attribution block on the barrier path) and package-level paragraph in ingress/package-info.java both name PR apache#5316 and zhang-arvin as the original contributor of the AtomicInteger barrier logic. README content (originally targeted by apache#5325 / wangyusheng1985) is left untouched: the 3 broken anchors were already removed by apache#5326 (docs: sync documentation with implementation status), which rewrote the Quick start section to point at docs/eventmesh-getting-started.md. The README has been in its post-apache#5326 state since before this commit, so no README change is needed. Closes apache#5316 Closes apache#5325 Fixes apache#5295 Co-authored-by: zhang-arvin <arvin.zhang@htx-inc.com> Co-authored-by: wangyusheng1985 <wangyusheng1985@users.noreply.github.com>
4 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Combined re-land of the four earlier #5330 / #5331 / #5333 / #5334 commits (all reverted by #5335) as a single commit on develop, with both contributor trailers preserved.
What this PR does
UniIngressService.deliverstructure. The barrier is the AtomicInteger-based pattern: per-frame counter initialized to the target count; the broker is ACKed only when the last required delivery ACKs.UniIngressService.javaattributing the barrier block to PR [Fix] Gate RocketMQ 5 POP broker ACK on distribution completion (#5295) #5316 and zhang-arvin.ingress/package-info.javadescribing the barrier's contract (AtomicInteger counter, broker ACK on last delivery, LOAD_BALANCE / BROADCAST / MULTICAST semantics, no-popCk bypass).Why a single commit instead of four
GitHub's contributor graph counts both
commit authorandCo-authored-by:trailers in the commit message. The earlier four-commit approach split the attribution across squash merges with inconsistent trailer handling. Consolidating into one PR with two trailers (zhang-arvin for #5316, wangyusheng1985 for #5325) preserves both contributors' graph credit in a single squash-merge commit.Files changed: 2 files
eventmesh-runtime/src/main/java/org/apache/eventmesh/runtime/ingress/UniIngressService.java(barrier block + attribution Javadoc)eventmesh-runtime/src/main/java/org/apache/eventmesh/runtime/ingress/package-info.java(package-level barrier doc)Closes #5316, Closes #5325, Fixes #5295
cc @zhang-arvin @wangyusheng1985
Co-authored-by: zhang-arvin arvin.zhang@htx-inc.com
Co-authored-by: wangyusheng1985 wangyusheng1985@users.noreply.github.com