[ISSUE #10924] Fix gRPC FIFO batch send ordering - #10926
Draft
qianye1001 wants to merge 2 commits into
Draft
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #10926 +/- ##
=============================================
- Coverage 48.45% 48.37% -0.09%
+ Complexity 13588 13573 -15
=============================================
Files 1380 1380
Lines 101196 101242 +46
Branches 13130 13140 +10
=============================================
- Hits 49038 48974 -64
- Misses 46190 46272 +82
- Partials 5968 5996 +28 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
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.
What changed
bodyEncoding=GZIP;IDENTITYandENCODING_UNSPECIFIEDremain valid as uncompressed input;SEND_BATCH_MESSAGErequest;Why
For requests containing more than one message,
SendMessageQueueSelectorignoredmessageGroupand used the normal queue-selection pipeline. Consecutive FIFO batches for the same message group could therefore select different queues and lose ordering.The batch validation also did not explicitly enforce the constraints required by one Broker batch request at the gRPC boundary. A compressed body cannot be put into
MessageBatchsafely with the current Broker batch protocol, so compressed gRPC batches are rejected before the Broker invocation.Fixes #10924.
Validation
JDK 8:
mvn -pl proxy -DskipITs -Dspotbugs.skip=true -Dcheckstyle.skip=true -Djacoco.skip=true \ -Dtest=SendMessageActivityTest \ -Dsurefire.failIfNoSpecifiedTests=false testThe gRPC activity test passed 16/16; all selected tests passed 17/17.
The protocol-level
MQClientAPIExtTest#testSendMessageListAsyncalso passed and verifies one remoting invocation with request codeSEND_BATCH_MESSAGEcontaining the complete batch.