From 73db2970ff9fc5bfa018af3715b9cf641346cbe3 Mon Sep 17 00:00:00 2001 From: zongtanghu Date: Sun, 1 Aug 2021 18:22:54 +0800 Subject: [PATCH] [#Issue3205]Fix the issue of code style in client and broker modules. --- .../broker/processor/AbstractSendMessageProcessor.java | 1 - .../apache/rocketmq/client/producer/RequestFutureTable.java | 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/broker/src/main/java/org/apache/rocketmq/broker/processor/AbstractSendMessageProcessor.java b/broker/src/main/java/org/apache/rocketmq/broker/processor/AbstractSendMessageProcessor.java index 2debf790..35f8660e 100644 --- a/broker/src/main/java/org/apache/rocketmq/broker/processor/AbstractSendMessageProcessor.java +++ b/broker/src/main/java/org/apache/rocketmq/broker/processor/AbstractSendMessageProcessor.java @@ -22,7 +22,6 @@ import java.net.SocketAddress; import java.util.HashMap; import java.util.List; import java.util.Map; -import java.util.Objects; import java.util.Random; import org.apache.rocketmq.broker.BrokerController; import org.apache.rocketmq.broker.mqtrace.SendMessageContext; diff --git a/client/src/main/java/org/apache/rocketmq/client/producer/RequestFutureTable.java b/client/src/main/java/org/apache/rocketmq/client/producer/RequestFutureTable.java index 52cda3e8..9bdc3da4 100644 --- a/client/src/main/java/org/apache/rocketmq/client/producer/RequestFutureTable.java +++ b/client/src/main/java/org/apache/rocketmq/client/producer/RequestFutureTable.java @@ -32,7 +32,7 @@ import org.apache.rocketmq.logging.InternalLogger; public class RequestFutureTable { private static InternalLogger log = ClientLogger.getLog(); private static ConcurrentHashMap requestFutureTable = new ConcurrentHashMap(); - private static final AtomicInteger producerNum = new AtomicInteger(0); + private static final AtomicInteger PRODUCER_NUM = new AtomicInteger(0); public static ConcurrentHashMap getRequestFutureTable() { return requestFutureTable; @@ -64,6 +64,6 @@ public class RequestFutureTable { } public static AtomicInteger getProducerNum() { - return producerNum; + return PRODUCER_NUM; } } -- GitLab