You are viewing a plain text version of this content. The canonical link for it is here.
Posted to hdfs-dev@hadoop.apache.org by "farmmamba (Jira)" <ji...@apache.org> on 2023/09/21 03:18:00 UTC
[jira] [Resolved] (HDFS-17203) ReplicaMap#map should better use ConcurrentHashMap rather than HashMap
[ https://issues.apache.org/jira/browse/HDFS-17203?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
farmmamba resolved HDFS-17203.
------------------------------
Resolution: Fixed
> ReplicaMap#map should better use ConcurrentHashMap rather than HashMap
> ----------------------------------------------------------------------
>
> Key: HDFS-17203
> URL: https://issues.apache.org/jira/browse/HDFS-17203
> Project: Hadoop HDFS
> Issue Type: Improvement
> Components: datanode
> Affects Versions: 3.4.0
> Reporter: farmmamba
> Assignee: farmmamba
> Priority: Major
>
> Even though we use BP write lock in ReplicaMap#initBlockPool method to initial <bpid,lightWeightResizableGSet> entry, we'd better change ReplicaMap#map from HashMap to ConcurrentHashMap. Because in ReplicaMap#add or ReplicaMap#addAndGet methods, we only use BP read lock to protect initialization.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: hdfs-dev-unsubscribe@hadoop.apache.org
For additional commands, e-mail: hdfs-dev-help@hadoop.apache.org