YARN-11668. Fix RM crash for potential concurrent modification exception when updating node attributes (#6681) Contributed by Junfan Zhang.

Reviewed-by: Dinesh Chitlangia <dineshc@apache.org>
Signed-off-by: Shilun Fan <slfan1989@apache.org>
This commit is contained in:
Junfan Zhang 2024-03-29 09:45:16 +08:00 committed by GitHub
parent f3f6340746
commit f1f2abe641
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -613,7 +613,7 @@ public void setHostName(String hostName) {
} }
public Host(String hostName) { public Host(String hostName) {
this(hostName, new HashMap<NodeAttribute, AttributeValue>()); this(hostName, new ConcurrentHashMap<NodeAttribute, AttributeValue>());
} }
public Host(String hostName, public Host(String hostName,