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 2022/03/15 02:24:34 UTC

[GitHub] [rocketmq-mqtt] pingww commented on a change in pull request #25: [ISSUE #19] fix '#' check in topicFilter

pingww commented on a change in pull request #25:
URL: https://github.com/apache/rocketmq-mqtt/pull/25#discussion_r826525702



##########
File path: mqtt-cs/src/main/java/org/apache/rocketmq/mqtt/cs/session/infly/InFlyCache.java
##########
@@ -61,9 +61,7 @@ public void cleanResource(String clientId,String channelId) {
 
     public void put(CacheType cacheType, String channelId, int mqttMsgId) {
         ConcurrentMap<String, Set<Integer>> cache = whichCache(cacheType);
-        if (!cache.containsKey(channelId)) {

Review comment:
       Adding judgment is mainly to avoid unnecessary temporary object generation




-- 
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: dev-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org