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

Benjamin Reed commented on ZOOKEEPER-335:
-----------------------------------------

yes this is the scenario that creates the issue. note that step 5 has to occur 
soon after step 4 otherwise 55 will get a state transfer rather than a diff and 
the problem will be fixed.

the fix isn't really performing a null transaction. (it is a work around, but 
you also need to get the timing right.) the problem is actually two parts: 1) 
the new epoch isn't getting logged properly. 2) once we do log properly we also 
need to make sure that we distinguish epochs that we tried to join from epochs 
that we did join. see 
https://cwiki.apache.org/confluence/display/ZOOKEEPER/Zab1.0 for the details.

fixing it is rather easy, it is making sure that it is backwards compatible 
that is a bit tricky. i should have it done today hopefully. well at least a 
first cut. the problem is that method is rather complicated and adding in the 
backwards compatibility makes it more so. i'm going to avoid refactoring for 
the first cut so that it is clear what i have modified. note that this affects 
both the leading code and the leader election code.


> zookeeper servers should commit the new leader txn to their logs.
> -----------------------------------------------------------------
>
>                 Key: ZOOKEEPER-335
>                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-335
>             Project: ZooKeeper
>          Issue Type: Bug
>          Components: server
>    Affects Versions: 3.1.0
>            Reporter: Mahadev konar
>            Assignee: Mahadev konar
>            Priority: Blocker
>             Fix For: 3.4.0
>
>         Attachments: ZOOKEEPER-790.travis.log.bz2, faultynode-vishal.txt, 
> zk.log.gz, zklogs.tar.gz
>
>
> currently the zookeeper followers do not commit the new leader election. This 
> will cause problems in a failure scenarios with a follower acking to the same 
> leader txn id twice, which might be two different intermittent leaders and 
> allowing them to propose two different txn's of the same zxid.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to