diff --git a/bookkeeper-server/src/main/java/org/apache/bookkeeper/proto/PerChannelBookieClient.java b/bookkeeper-server/src/main/java/org/apache/bookkeeper/proto/PerChannelBookieClient.java index 41add30ca56..f84343a71b4 100644 --- a/bookkeeper-server/src/main/java/org/apache/bookkeeper/proto/PerChannelBookieClient.java +++ b/bookkeeper-server/src/main/java/org/apache/bookkeeper/proto/PerChannelBookieClient.java @@ -187,7 +187,7 @@ public class PerChannelBookieClient extends ChannelInboundHandlerAdapter { final int startTLSTimeout; private final ConcurrentOpenHashMap completionObjects = - ConcurrentOpenHashMap.newBuilder().build(); + ConcurrentOpenHashMap.newBuilder().autoShrink(true).build(); // Map that hold duplicated read requests. The idea is to only use this map (synchronized) when there is a duplicate // read request for the same ledgerId/entryId