You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ratis.apache.org by GitBox <gi...@apache.org> on 2019/11/20 09:14:51 UTC

[GitHub] [incubator-ratis] adoroszlai opened a new pull request #48: RATIS-758. Illegal state transition in LeaderElection: RUNNING to CLOSED

adoroszlai opened a new pull request #48: RATIS-758. Illegal state transition in LeaderElection: RUNNING to CLOSED
URL: https://github.com/apache/incubator-ratis/pull/48
 
 
   ## What changes were proposed in this pull request?
   
   Make sure `LeaderElection` is transitioned to `CLOSED` via `CLOSING`.  Even if `askForVotes` has no chance for any iteration due to already being changed to follower.
   
   The first commit contains repro code, and can be dropped or reworked, eg. if mocking or exposing some methods only for testing is not desirable.
   
   The second commit is the fix itself.
   
   https://issues.apache.org/jira/browse/RATIS-758
   
   ## How was this patch tested?
   
   Added unit test case to reproduce the problem and verify the fix.  Currently running all tests to check for regressions.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services