[ 
https://issues.apache.org/jira/browse/YARN-10296?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17124121#comment-17124121
 ] 

Wangda Tan commented on YARN-10296:
-----------------------------------

[~bteke], 

It makes sense to covert other method which uses containerId to synchronized as 
well, for example, {{getProto}}, performance should not be a big concern here, 
as multiple threads not likely access same Container object. (Because we have 
many container objects in the memory).

> Make ContainerPBImpl#getId/setId synchronized
> ---------------------------------------------
>
>                 Key: YARN-10296
>                 URL: https://issues.apache.org/jira/browse/YARN-10296
>             Project: Hadoop YARN
>          Issue Type: Bug
>    Affects Versions: 3.3.0
>            Reporter: Benjamin Teke
>            Assignee: Benjamin Teke
>            Priority: Minor
>         Attachments: YARN-10296.001.patch
>
>
> ContainerPBImpl getId and setId methods can be accessed from multiple 
> threads. In order to avoid any simultaneous accesses and race conditions 
> these methods should be synchronized.
> The idea came from the issue described in YARN-10295, however that patch is 
> only applicable to branch-3.2 and 3.1.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: yarn-issues-unsubscr...@hadoop.apache.org
For additional commands, e-mail: yarn-issues-h...@hadoop.apache.org

Reply via email to