jvarenina commented on a change in pull request #6477:
URL: https://github.com/apache/geode/pull/6477#discussion_r640446735



##########
File path: 
geode-core/src/main/java/org/apache/geode/internal/cache/TXCommitMessage.java
##########
@@ -391,9 +404,16 @@ void send(TXLockId lockId) {
                 
setRecipientsSendData(Collections.singleton(indivRecip.next()), processor, rcl);
               }
             } else {
-              // Run in normal mode sending to multiple recipients in
-              // one shot
-              setRecipientsSendData(recipients, processor, rcl);
+              if (this.notificationOnlyMembers.isEmpty()) {
+                // Run in normal mode sending to multiple recipients in one 
shot
+                setRecipientsSendData(recipients, processor, rcl);
+              } else {
+                recipients.removeAll(this.notificationOnlyMembers);
+                setRecipientsSendData(recipients, processor, rcl);
+
+                this.txState.setTailKeyOnEntries(-1L);
+                setRecipientsSendData(notificationOnlyMembers, processor, rcl);

Review comment:
       Hi @DonalEvans ,
   
   Not sure that I completely understand your question:
   
   "Since we're now splitting the sending of this message up into two separate 
calls to DistributionManager.putOutgoing() might there be problems if the first 
call succeeds but the second doesn't?"
   
   What I could see from code and some tests is that this 
`DistributionManager.putOutgoing()` is executed asynchronously. This means that 
messages are first sent to the receivers and then replies are checked later on 
with `CommitReplyProcessor` processor. `CommitReplyProcessor` will wait for 
replies from all receivers (used in first and second call of 
DistributionManager.putOutgoing()). If any commit message fail (for example 
second call of `DistributionManager.putOutgoing()`) this will be recorded in 
processor and `org.apache.geode.cache.CommitIncompleteException` will be 
returned to client.
   
   I have tested both that exception only occurs on member that host secondary 
bucket (first call of `DistributionManager.putOutgoing()`) or only on member 
that host only CQ queue(second call of `DistributionManager.putOutgoing()`). 
Same exception `CommitIncompleteException` propagated to client.
   
   Not sure if you had something else in mind?




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

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to