Todd Lipcon has submitted this change and it was merged.

Change subject: KUDU-1135 (part 1): avoid flushing cmeta to disk twice when 
voting
......................................................................


KUDU-1135 (part 1): avoid flushing cmeta to disk twice when voting

This adds a flag to the term advancement calls which prevents it from
flushing to disk. We use this flag during voting when we know we are
about to flush our vote to disk immediately following the term
advancement.

This is part 1: another patch will do the same optimization for the case
of starting an election.

Change-Id: Iecc55bc9e96dcdc918ede1190b7cbac719f95506
Reviewed-on: http://gerrit.cloudera.org:8080/4333
Reviewed-by: Mike Percy <mpe...@apache.org>
Reviewed-by: David Ribeiro Alves <dral...@apache.org>
Tested-by: David Ribeiro Alves <dral...@apache.org>
---
M src/kudu/consensus/consensus_meta.cc
M src/kudu/consensus/consensus_meta.h
M src/kudu/consensus/raft_consensus.cc
M src/kudu/consensus/raft_consensus.h
M src/kudu/consensus/raft_consensus_quorum-test.cc
M src/kudu/consensus/raft_consensus_state.cc
M src/kudu/consensus/raft_consensus_state.h
7 files changed, 80 insertions(+), 14 deletions(-)

Approvals:
  David Ribeiro Alves: Looks good to me, approved; Verified
  Mike Percy: Looks good to me, but someone else must approve



-- 
To view, visit http://gerrit.cloudera.org:8080/4333
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Iecc55bc9e96dcdc918ede1190b7cbac719f95506
Gerrit-PatchSet: 2
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Todd Lipcon <t...@apache.org>
Gerrit-Reviewer: David Ribeiro Alves <dral...@apache.org>
Gerrit-Reviewer: Mike Percy <mpe...@apache.org>
Gerrit-Reviewer: Todd Lipcon <t...@apache.org>

Reply via email to