Todd Lipcon has submitted this change and it was merged.
Change subject: KUDU-1365. Add leader pre-elections
KUDU-1365. Add leader pre-elections
This implements the "pre-election" extension to the Raft algorithm.
The idea is that, before calling a leader election, a candidate first
sends a pre-election vote request to all voters. The voters respond
as they would have in a real vote, except they don't actually record
Cluster tests verify that this substantially reduces the election storms
after a node has a temporarily slow disk or otherwise freezes.
A new experimental flag 'raft_enable_pre_election' is introduced which
defaults the feature to on, but provides a safety valve to disable this
in case we find some bug after release.
Tested this patch (along with the following series of cleanups) with:
 1000 loops of RaftConsensusITest.MultiThreadedInsertWithFailovers
 500 loops of raft-consensus-itest overall
 1000 loops of exactly_once_writes-itest
The above tests have usually been pretty good about finding bugs in
consensus in the past.
Tested-by: Kudu Jenkins
Reviewed-by: David Ribeiro Alves <dral...@apache.org>
10 files changed, 309 insertions(+), 144 deletions(-)
David Ribeiro Alves: Looks good to me, approved
Kudu Jenkins: Verified
To view, visit http://gerrit.cloudera.org:8080/4694
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Owner: Todd Lipcon <t...@apache.org>
Gerrit-Reviewer: David Ribeiro Alves <dral...@apache.org>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Reviewer: Mike Percy <mpe...@apache.org>
Gerrit-Reviewer: Tidy Bot
Gerrit-Reviewer: Todd Lipcon <t...@apache.org>