You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@rocketmq.apache.org by GitBox <gi...@apache.org> on 2020/04/08 03:12:53 UTC

[GitHub] [rocketmq] duhenglucky commented on issue #1881: [ISSUE #1879] Prevent blocked by group transfer service

duhenglucky commented on issue #1881: [ISSUE #1879] Prevent blocked by group transfer service
URL: https://github.com/apache/rocketmq/pull/1881#issuecomment-610727791
 
 
   > Run example `org.apache.rocketmq.example.quickstart.Producer` to send a msg.
   > 
   > for debug, i add a sout here
   > 
   > ```java
   > @Override
   > public void asyncProcessRequest(ChannelHandlerContext ctx, RemotingCommand request, RemotingResponseCallback responseCallback) throws Exception {
   > 	asyncProcessRequest(ctx, request).thenAcceptAsync(
   > 			r -> {
   > 				System.out.println(r);
   > 				responseCallback.callback(r);
   > 			},
   > 			this.brokerController.getSendMessageExecutor());
   > }
   > ```
   > 
   > debug result:
   > 
   > 1. `org.apache.rocketmq.broker.processor.SendMessageProcessor#handlePutMessageResult` is invoked in GroupCommitService thread.
   > 
   > ```java
   > {
   >   System.out.println(r);
   >   responseCallback.callback(r);
   > }
   > ```
   > 
   > is invoked in SendMessageThread_1, and r is null
   
   r is null just because of the succeed send message response returned to the client directly by org.apache.rocketmq.broker.processor.AbstractSendMessageProcessor#doResponse in org.apache.rocketmq.broker.processor.SendMessageProcessor#handlePutMessageResult method and these responses will not be processed by AfterRPCHook, the code here is a little confusing

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services