keranbingaa commented on code in PR #6337:
URL: https://github.com/apache/rocketmq/pull/6337#discussion_r1151296498


##########
remoting/src/main/java/org/apache/rocketmq/remoting/netty/NettyRemotingAbstract.java:
##########
@@ -355,19 +355,22 @@ private Runnable 
buildProcessRequestHandler(ChannelHandlerContext ctx, RemotingC
     public void processResponseCommand(ChannelHandlerContext ctx, 
RemotingCommand cmd) {
         final int opaque = cmd.getOpaque();
         final ResponseFuture responseFuture = responseTable.get(opaque);
+        final String remoteAddr = ctx == null ? "" : 
RemotingHelper.parseChannelRemoteAddr(ctx.channel());
         if (responseFuture != null) {
             responseFuture.setResponseCommand(cmd);
 
             responseTable.remove(opaque);
 
+            doAfterRpcHooks(remoteAddr, responseFuture.getRequestCommand(), 
cmd);

Review Comment:
   I mean in func invokesync of NettyRemotingClient, the doAfterRpcHooks is 
called now, if you call doAfterRpcHooks in this place, may the doAfterRpcHooks 
will be called twice?



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