You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@zookeeper.apache.org by "Thawan Kooburat (JIRA)" <ji...@apache.org> on 2013/09/25 23:33:03 UTC

[jira] [Commented] (ZOOKEEPER-1638) Redundant zk.getZKDatabase().clear();

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

Thawan Kooburat commented on ZOOKEEPER-1638:
--------------------------------------------

Can you add a comment into a patch saying that db is clear as part of deserializeSnapshot()?

I will +1 and commit the patch after the change


                
> Redundant zk.getZKDatabase().clear();
> -------------------------------------
>
>                 Key: ZOOKEEPER-1638
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-1638
>             Project: ZooKeeper
>          Issue Type: Improvement
>            Reporter: Alexander Shraer
>            Assignee: neil bhakta
>            Priority: Trivial
>              Labels: newbie
>             Fix For: 3.5.0
>
>         Attachments: ZOOKEEPER-1638.patch
>
>
> Learner.syncWithLeader calls zk.getZKDatabase().clear() right before zk.getZKDatabase().deserializeSnapshot(leaderIs); Then the first thing deserializeSnapshot does is another clear(). 
> Suggest to remove the clear() in syncWithLeader.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira