socutes commented on code in PR #6116:
URL: https://github.com/apache/rocketmq/pull/6116#discussion_r1111412920
##########
remoting/src/main/java/org/apache/rocketmq/remoting/netty/NettyRemotingClient.java:
##########
@@ -95,7 +96,7 @@ public class NettyRemotingClient extends
NettyRemotingAbstract implements Remoti
private final ConcurrentHashMap<String /* cidr */, Bootstrap> bootstrapMap
= new ConcurrentHashMap<>();
private final ConcurrentMap<String /* addr */, ChannelWrapper>
channelTables = new ConcurrentHashMap<>();
- private final Timer timer = new Timer("ClientHouseKeepingService", true);
+ private final HashedWheelTimer timer = new HashedWheelTimer(r -> new
Thread(r, "ClientHouseKeepingService"));
Review Comment:
In my opinion, the network module as the basic component, we should try to
optimize every detail.
Especially in the stream processing scenario, some details of the
performance issues, this can cause some unexpected performance problems.
HashedWheelTimer is more reasonable and better than Timer in terms of
performance and implementation.
--
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]