rocketmq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ifplu...@apache.org
Subject [rocketmq-client-cpp] 02/29: remove redundant code
Date Tue, 29 Dec 2020 03:36:19 GMT
This is an automated email from the ASF dual-hosted git repository.

ifplusor pushed a commit to branch re_dev
in repository https://gitbox.apache.org/repos/asf/rocketmq-client-cpp.git

commit 8e6c3b939c2a18a0ecf20b1cffadb5f51b6176fe
Author: James Yin <ywhjames@hotmail.com>
AuthorDate: Thu May 28 10:59:51 2020 +0800

    remove redundant code
---
 src/producer/MQFaultStrategy.cpp | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/src/producer/MQFaultStrategy.cpp b/src/producer/MQFaultStrategy.cpp
index a73b149..9abef32 100644
--- a/src/producer/MQFaultStrategy.cpp
+++ b/src/producer/MQFaultStrategy.cpp
@@ -33,9 +33,7 @@ const MQMessageQueue& MQFaultStrategy::selectOneMessageQueue(const TopicPublishI
         auto pos = index++ % messageQueueList.size();
         const auto& mq = messageQueueList[pos];
         if (m_latencyFaultTolerance.isAvailable(mq.getBrokerName())) {
-          if (lastBrokerName.empty() || mq.getBrokerName() != lastBrokerName) {
-            return mq;
-          }
+          return mq;
         }
       }
     }


Mime
View raw message