You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ozone.apache.org by "Ivan Andika (Jira)" <ji...@apache.org> on 2025/09/07 06:40:00 UTC
[jira] [Assigned] (HDDS-7544) ContainerStateMap uses HashSet to store container replica lists
[ 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: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org