[ 
https://issues.apache.org/jira/browse/HDDS-7544?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ivan Andika reassigned HDDS-7544:
---------------------------------

    Assignee: Neo Chien

> ContainerStateMap uses HashSet to store container replica lists
> ---------------------------------------------------------------
>
>                 Key: HDDS-7544
>                 URL: https://issues.apache.org/jira/browse/HDDS-7544
>             Project: Apache Ozone
>          Issue Type: Sub-task
>            Reporter: Duong
>            Assignee: Neo Chien
>            Priority: Major
>              Labels: pull-request-available
>
> ContainerStateMap uses HashSets to store container replica lists, 
> [link|https://github.com/apache/ozone/blob/master/hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/container/states/ContainerStateMap.java#L91-L91].
> Each HashSet instance is backed by a HashMap whose default size is 16. This 
> set stores 3 replica references at max.
> So, for each container, a buffer of at least 13 * 8 ~ 108 bytes is never used.
>  
> Using Set for container replica is not mandatory for the logic of 
> ContainerStateMap, a replacement of LinkedList would offer the same without 
> indicating waste buffer.
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

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

Reply via email to