lirong-Lee commented on issue #347:
URL: 
https://github.com/apache/rocketmq-client-cpp/issues/347#issuecomment-781803870


   MQClientInstance.cpp:432
   ```
   if (topicRouteData != nullptr) {
           LOG_INFO_NEW("updateTopicRouteInfoFromNameServer has data");
           auto old = getTopicRouteData(topic);
           bool changed = topicRouteDataIsChange(old.get(), 
topicRouteData.get());
   
           if (changed) {
             LOG_INFO_NEW("updateTopicRouteInfoFromNameServer changed:{}", 
topic);
   
             // update broker addr
             const auto& brokerDatas = topicRouteData->broker_datas();
             for (const auto& bd : brokerDatas) {
               LOG_INFO_NEW("updateTopicRouteInfoFromNameServer changed with 
broker name:{}", bd.broker_name());
               addBrokerToAddrTable(bd.broker_name(), bd.broker_addrs());
             }
   
             // update publish info
             {
               TopicPublishInfoPtr 
publishInfo(topicRouteData2TopicPublishInfo(topic, topicRouteData));
               updateProducerTopicPublishInfo(topic, publishInfo);
             }
   
             // update subscribe info
             if (getConsumerTableSize() > 0) {
               std::vector<MQMessageQueue> subscribeInfo = 
topicRouteData2TopicSubscribeInfo(topic, topicRouteData);
               updateConsumerTopicSubscribeInfo(topic, subscribeInfo);
             }
   
             addTopicRouteData(topic, topicRouteData);    
   
           }
   ```
   **Prodouct will addTopicRouteData, causing the consumer to come in and 
changed is false, and updateConsumerTopicSubscribeInfo will not be executed**
   


----------------------------------------------------------------
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:
[email protected]


Reply via email to