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 2021/01/12 11:17:15 UTC

[GitHub] [rocketmq] kelvin17 opened a new issue #2588: Duplicate invoke countDownLatch.countDown on Reply-Request

kelvin17 opened a new issue #2588:
URL: https://github.com/apache/rocketmq/issues/2588


   version:4.8.0
   
   When use Reply-Request,DefaultMQProducer.request to send a msg, and waiting for the reply on DefaultMQProducerImpl#waitResponse (use countDownLatch.await)
   
   When the reply message back,the process is org.apache.rocketmq.client.impl.ClientRemotingProcessor#processReplyMessage.
   
   There is duplicate invoke of countDownLatch.countDown . L279 and L286
   
   private void processReplyMessage(MessageExt replyMsg) {
           final String correlationId = replyMsg.getUserProperty(MessageConst.PROPERTY_CORRELATION_ID);
           final RequestResponseFuture requestResponseFuture = RequestFutureTable.getRequestFutureTable().get(correlationId);
           if (requestResponseFuture != null) {
               _**requestResponseFuture.putResponseMessage(replyMsg);**_
   
               RequestFutureTable.getRequestFutureTable().remove(correlationId);
   
               if (requestResponseFuture.getRequestCallback() != null) {
                   requestResponseFuture.getRequestCallback().onSuccess(replyMsg);
               } else {
                   _**requestResponseFuture.putResponseMessage(replyMsg);**_
               }
           } else {
               String bornHost = replyMsg.getBornHostString();
               log.warn(String.format("receive reply message, but not matched any request, CorrelationId: %s , reply from host: %s",
                   correlationId, bornHost));
           }
       }


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



[GitHub] [rocketmq] RongtongJin closed issue #2588: Duplicate invoke countDownLatch.countDown on Reply-Request

Posted by GitBox <gi...@apache.org>.
RongtongJin closed issue #2588:
URL: https://github.com/apache/rocketmq/issues/2588


   


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