Aaron-TangCode commented on issue #3680:
URL: https://github.com/apache/rocketmq/issues/3680#issuecomment-1007953680
```java
public MQClientInstance getOrCreateMQClientInstance(final ClientConfig
clientConfig, RPCHook rpcHook) {
this.markIndex(clientConfig);
String clientId = clientConfig.buildMQClientId();//这里已经构建了一次ClientId
if (instance == null) {
instance = createInstance(clientConfig,
rpcHook);//这里面又再次构建ClientId,这里是否还有更优雅的实现方式
}
```
```java
private MQClientInstance createInstance(final ClientConfig clientConfig,
RPCHook rpcHook) {
String clientId = clientConfig.buildMQClientId();//再次构建ClientId
...
```
不清楚,这里再次构建ClientId的目的是啥,感觉还可以有更好的实现方式,你觉得呢?
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]