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/04/09 03:42:47 UTC

[GitHub] [rocketmq] crazy-pizza edited a comment on issue #2782: Why does BROADCASTING consumer use different MQClientInstance than CLUSTERING consumer

crazy-pizza edited a comment on issue #2782:
URL: https://github.com/apache/rocketmq/issues/2782#issuecomment-816378680


   > InstanceName is used to splice clientId,the broadcast mode does not require consumer rebalance, and there is no need to ensure that the ClientId is different.
   
   我明白你的意思,你是站着集群模式消费的角度考虑的。
   但是我想说的是,如果广播消费的instanceName也使用PID,就可以在一个进程内与集群消费共享网络连接。
   
   并且由于广播消费的消费进度存储在本地,位置在: 
   ```
   this.storePath = LOCAL_OFFSET_STORE_DIR + File.separator +
               this.mQClientFactory.getClientId() + File.separator +
               this.groupName + File.separator +
               "offsets.json";
   ```
   如果广播消费的instanceName固定是DEFAULT的话,那么将不能在一台机器上启动两个相同组名的消费者,否则Offset存储会发生冲突
   


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