accumulo-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Josh Elser (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (ACCUMULO-2872) Lack of synchronization when accessing lastCompactID in Tablet#setLastCompactionID()
Date Sun, 08 Jun 2014 02:39:02 GMT

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

Josh Elser commented on ACCUMULO-2872:
--------------------------------------

It isn't a bug presently, because that method is only invoked in a synchronized block of the
instance of Tablet. However, it would be good to ensure that the method is either restricted
to only be invoked inside of Tablet and in a synchronized block, or the implementation itself
is synchronized.

> Lack of synchronization when accessing lastCompactID in Tablet#setLastCompactionID()
> ------------------------------------------------------------------------------------
>
>                 Key: ACCUMULO-2872
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-2872
>             Project: Accumulo
>          Issue Type: Bug
>    Affects Versions: 1.7.0
>            Reporter: Ted Yu
>            Priority: Minor
>
> {code}
>   public void setLastCompactionID(Long compactionId) {
>     if (compactionId != null)
>       this.lastCompactID = compactionId;
>   }
> {code}
> Lock on Tablet.this should be held when assigning lastCompactID.



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

Mime
View raw message