Alexey Serbin has posted comments on this change. ( http://gerrit.cloudera.org:8080/8297 )
Change subject: consensus: support changing between VOTER and NON_VOTER ...................................................................... Patch Set 3: (6 comments) http://gerrit.cloudera.org:8080/#/c/8297/3/src/kudu/consensus/raft_consensus.cc File src/kudu/consensus/raft_consensus.cc: http://gerrit.cloudera.org:8080/#/c/8297/3/src/kudu/consensus/raft_consensus.cc@1674 PS3, Line 1674: type > can you use ChangeConfigType_Name here to get it stringified? Done http://gerrit.cloudera.org:8080/#/c/8297/3/src/kudu/consensus/raft_consensus.cc@2428 PS3, Line 2428: if (cmeta_->IsVoterInConfig(peer_uuid(), COMMITTED_CONFIG)) { : EnableFailureDetector(boost::none); : } else { : DisableFailureDetector(); : } > we have this same bit of code in a bunch of places, maybe we can extract a Done: added ToggleFailureDetector(). Though I'm not sure it has safe enough signature for all cases. Raft consensus state looks tricky. http://gerrit.cloudera.org:8080/#/c/8297/3/src/kudu/integration-tests/raft_consensus_nonvoter-itest.cc File src/kudu/integration-tests/raft_consensus_nonvoter-itest.cc: http://gerrit.cloudera.org:8080/#/c/8297/3/src/kudu/integration-tests/raft_consensus_nonvoter-itest.cc@157 PS3, Line 157: Status RaftConsensusNonVoterITest::PromoteReplica( > this function seems identical to DemoteReplica except for the constant VOTE Done http://gerrit.cloudera.org:8080/#/c/8297/3/src/kudu/integration-tests/raft_consensus_nonvoter-itest.cc@595 PS3, Line 595: 64 > why the power of two here? seems a bit unnecessarily magic changed to 50 http://gerrit.cloudera.org:8080/#/c/8297/3/src/kudu/integration-tests/raft_consensus_nonvoter-itest.cc@723 PS3, Line 723: while (workload.rows_inserted() < 1000) { > I think it would be better to capture the number of rows inserted right aft Good idea. Done. http://gerrit.cloudera.org:8080/#/c/8297/3/src/kudu/integration-tests/raft_consensus_nonvoter-itest.cc@751 PS3, Line 751: approrpiate > typo Done -- To view, visit http://gerrit.cloudera.org:8080/8297 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: I978cbed683b0e95a903f2bd2b57496aee71cb33a Gerrit-Change-Number: 8297 Gerrit-PatchSet: 3 Gerrit-Owner: Mike Percy <mpe...@apache.org> Gerrit-Reviewer: Alexey Serbin <aser...@cloudera.com> Gerrit-Reviewer: David Ribeiro Alves <davidral...@gmail.com> Gerrit-Reviewer: Kudu Jenkins Gerrit-Reviewer: Tidy Bot Gerrit-Reviewer: Todd Lipcon <t...@apache.org> Gerrit-Comment-Date: Tue, 24 Oct 2017 00:11:44 +0000 Gerrit-HasComments: Yes