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

Siddharth Seth commented on TEZ-1070:
-------------------------------------

I'm actually in favour of removing the methods which try to setContext and 
numInputs. It's fairly straightforward for users to implement. Trying to 
synchronize implies they have to use synchronization on the object itself if i 
understand things correctly (using alternate locking mechanisms may not work 
very well). Making it volatile is just horrible - since it creates multiple 
potential accidental memory accesses.

> getContext() in Abstract Input/Output/Processor not thread safe
> ---------------------------------------------------------------
>
>                 Key: TEZ-1070
>                 URL: https://issues.apache.org/jira/browse/TEZ-1070
>             Project: Apache Tez
>          Issue Type: Bug
>            Reporter: Siddharth Seth
>            Priority: Blocker
>
> Post TEZ-695, getContext() and getNumInputs/getNumOutputs are not thread 
> safe. initialize and start are almst always invoked in different threads.



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Reply via email to