ivandika3 commented on code in PR #1721:
URL: https://github.com/apache/ratis/pull/1721#discussion_r4794203393


##########
ratis-server/src/main/java/org/apache/ratis/server/impl/ServerProtoUtils.java:
##########
@@ -66,16 +66,17 @@ static RequestVoteRequestProto toRequestVoteRequestProto(
   }
 
   static StartLeaderElectionReplyProto toStartLeaderElectionReplyProto(
-      RaftPeerId requestorId, RaftGroupMemberId replyId, boolean success) {
+      RaftPeerId requestorId, RaftGroupMemberId replyId, boolean success, long 
callId) {
     return StartLeaderElectionReplyProto.newBuilder()
-        .setServerReply(toRaftRpcReplyProtoBuilder(requestorId, replyId, 
success))
+        .setServerReply(toRaftRpcReplyProtoBuilder(requestorId, replyId, 
success).setCallId(callId))

Review Comment:
   > Let's add a callId parameter to toRaftRpcReplyProtoBuilder, which 
currently pass null callId to ClientProtoUtils.toRaftRpcReplyProtoBuilder as 
above.
   
   Thanks for the review, updated.
   
   > For the other rpcs such as toInstallSnapshotReplyProto and 
toReadIndexReplyProto, they probably have a similar bug. See if you would fix 
it here or we can fix it separately. (we can pass null as the callId parameter 
for now)
   
   Let's address it in another ticket. Checking with AI and only 
InstallSnapshot can have impact since InstallSnapshot can use Netty, raised 
RATIS-2851 for InstallSnapshot. Currently 
RaftServerAsynchronousProtocol#readIndexAsync is only supported by the gRPC 
which does not need to call ID to correlate request and response. I raised 
RATIS-2852 to support the RaftServerAsynchronousProtocol for Netty (at least 
the readIndexAsync for now).



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

Reply via email to