Github user Jaskey commented on a diff in the pull request:
https://github.com/apache/incubator-rocketmq/pull/60#discussion_r105594848
--- Diff:
client/src/main/java/org/apache/rocketmq/client/impl/producer/DefaultMQProducerImpl.java
---
@@ -449,9 +449,9 @@ private SendResult sendDefaultImpl(//
String[] brokersSent = new String[timesTotal];
for (; times < timesTotal; times++) {
String lastBrokerName = null == mq ? null :
mq.getBrokerName();
- MessageQueue tmpmq =
this.selectOneMessageQueue(topicPublishInfo, lastBrokerName);
- if (tmpmq != null) {
- mq = tmpmq;
+ MessageQueue mqAttempt =
this.selectOneMessageQueue(topicPublishInfo, lastBrokerName);
--- End diff --
IMO , any variable named like XXXtmp is bad. Maybe we can rename it to
another one but tmpMq is far from good enough
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---