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

Jonathan Turner Eagles commented on TEZ-4090:
---------------------------------------------

Synchronization could be optimized perhaps, but not removed

{quote}
https://docs.oracle.com/javase/7/docs/api/java/util/WeakHashMap.html
Like most collection classes, this class is not synchronized. A synchronized 
WeakHashMap may be constructed using the Collections.synchronizedMap method.
{quote}

> TezIDCache::getInstance sync lock
> ---------------------------------
>
>                 Key: TEZ-4090
>                 URL: https://issues.apache.org/jira/browse/TEZ-4090
>             Project: Apache Tez
>          Issue Type: Bug
>            Reporter: Rajesh Balamohan
>            Priority: Minor
>         Attachments: tez-task-id-concurrency.png
>
>
> profiler output shared by [~gopalv]. 
> Looking at the code, it is not mandatory to have sync on getInstance. 
> https://github.com/apache/tez/blob/master/tez-common/src/main/java/org/apache/tez/dag/records/TezID.java#L48



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

Reply via email to