You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ozone.apache.org by "Andrei Mikhalev (Jira)" <ji...@apache.org> on 2024/06/03 10:41:00 UTC
[jira] [Updated] (HDDS-10971) Replace ConcurrentHashMap with HashMap in PipelineStateMap
[ https://issues.apache.org/jira/browse/HDDS-10971?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Andrei Mikhalev updated HDDS-10971:
-----------------------------------
Summary: Replace ConcurrentHashMap with HashMap in PipelineStateMap (was: Replace ConcurrentHashMap with HashMap protected in PipelineStateMap)
> Replace ConcurrentHashMap with HashMap in PipelineStateMap
> ----------------------------------------------------------
>
> Key: HDDS-10971
> URL: https://issues.apache.org/jira/browse/HDDS-10971
> Project: Apache Ozone
> Issue Type: Improvement
> Components: SCM
> Affects Versions: 1.4.0
> Reporter: Andrei Mikhalev
> Assignee: Andrei Mikhalev
> Priority: Major
>
> There is a class [PipelineStateMap|https://github.com/apache/ozone/blob/master/hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/pipeline/PipelineStateMap.java#L50] with 2 fields:
> # {{ConcurrentHashMap<PipelineID, Pipeline> pipelineMap}}
> # {{ConcurrentHashMap<PipelineID, NavigableSet<ContainerID>> pipeline2container}}
> Both *read* and *write* in _PipelineStateMap_ are protected by {*}lock{*} in [PipelineStateManagerImpl|https://github.com/apache/ozone/blob/master/hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/pipeline/PipelineStateManagerImpl.java#L49] .
> We can safely replace _ConcurrentHashMap_ with pure _HashMap_
--
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