You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-issues@hadoop.apache.org by "Daryn Sharp (JIRA)" <ji...@apache.org> on 2018/05/02 14:32:00 UTC

[jira] [Commented] (HADOOP-15373) Clear the code of Callqueuemanager

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

Daryn Sharp commented on HADOOP-15373:
--------------------------------------

I see no benefit to changing it.  The {{AtomicReference}} is internally using a volatile and the getter/setter will be inlined by the jvm so it's functionally equivalent. Even though CAS methods aren't currently being used, past experience is people may be prone to removing a volatile keyword.  The atomic ref is harder to accidentally change and slip through a review.

Unless there's a compelling reason I'm overlooking, please close as not a problem.

> Clear the code of Callqueuemanager
> ----------------------------------
>
>                 Key: HADOOP-15373
>                 URL: https://issues.apache.org/jira/browse/HADOOP-15373
>             Project: Hadoop Common
>          Issue Type: Bug
>          Components: common
>    Affects Versions: 3.2.0
>            Reporter: maobaolong
>            Assignee: maobaolong
>            Priority: Minor
>
> The CallQueueManager contain two member, putRef and takeRef. They seems shouldn't have to use AtomicReference, it can use the volatile directly.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: common-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-issues-help@hadoop.apache.org