cchung100m commented on code in PR #8990:
URL: https://github.com/apache/ozone/pull/8990#discussion_r2589102250


##########
hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/container/states/ContainerEntry.java:
##########
@@ -31,7 +33,10 @@
  */
 public class ContainerEntry {
   private final ContainerInfo info;
-  private final Map<DatanodeID, ContainerReplica> replicas = new HashMap<>();
+  // Most containers will have 3 replicas, and some may have 14, for example, 
in the case of EC 10-4
+  // so an initial capacity of 8 should be sufficient to avoid resize for most 
cases
+  private final Map<DatanodeID, ContainerReplica> replicas = new HashMap<>(8);

Review Comment:
   Hi @adoroszlai  Thanks for reply. I updated the part which suggested by 
@sodonnel 



-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to