Jean-Daniel Cryans has submitted this change and it was merged.

Change subject: Send back an error when UpdateConsensus cannot prepare a single 
transaction
......................................................................


Send back an error when UpdateConsensus cannot prepare a single transaction

If for any reason an UpdateConsensus() call fails to prepare a single op,
it will still return OK. The leader doesn't detect that no progress
was made, so it sends a new batch right away... and it's the same one.

This patch makes it so that we detect this situation and so that we
go into the error-handling path on response. It also adds a test
where we manufacture the same conditions.

Change-Id: I546fd3069af974383c23acb7406ea621e6962bb3
Reviewed-on: http://gerrit.cloudera.org:8080/1785
Reviewed-by: Mike Percy <[email protected]>
Tested-by: Internal Jenkins
---
M src/kudu/consensus/consensus.proto
M src/kudu/consensus/consensus_peers.cc
M src/kudu/consensus/raft_consensus.cc
M src/kudu/integration-tests/raft_consensus-itest.cc
4 files changed, 76 insertions(+), 2 deletions(-)

Approvals:
  Mike Percy: Looks good to me, approved
  Internal Jenkins: Verified



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

Gerrit-MessageType: merged
Gerrit-Change-Id: I546fd3069af974383c23acb7406ea621e6962bb3
Gerrit-PatchSet: 6
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Jean-Daniel Cryans
Gerrit-Reviewer: David Ribeiro Alves <[email protected]>
Gerrit-Reviewer: Internal Jenkins
Gerrit-Reviewer: Jean-Daniel Cryans
Gerrit-Reviewer: Mike Percy <[email protected]>
Gerrit-Reviewer: Todd Lipcon <[email protected]>

Reply via email to