You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@kudu.apache.org by "Grant Henke (Code Review)" <ge...@cloudera.org> on 2018/05/21 15:27:18 UTC

[kudu-CR](branch-1.7.x) [consensus] KUDU-2443 fix replica replacement of RF=1

Grant Henke has uploaded this change for review. ( http://gerrit.cloudera.org:8080/10464


Change subject: [consensus] KUDU-2443 fix replica replacement of RF=1
......................................................................

[consensus] KUDU-2443 fix replica replacement of RF=1

Fixed bug in the consensus::ShouldEvictReplica() function for the case
when the leader replica of a tablet with replication factor of 1
is marked with the REPLACE attribute and there is an extra voter
replica in the tablet's Raft config.

Prior to this fix, the master would evict the extra voter from the
configuration and then it would add a new non-voter because of the
consensus::ShouldAddReplica() method's behavior.  After the newly
added non-voter replica catches up and becomes a voter, that would
happen again and again, until the REPLACE attribute is removed.

This changelist also includes regression tests to cover the
corresponding functionality.  Also, additional test scenarios added
to extend the coverage for the single-replica edge case.

Change-Id: I9da9fe6788f28b40f7adc53e23540bcdf103c1ea
Reviewed-on: http://gerrit.cloudera.org:8080/10438
Tested-by: Kudu Jenkins
Reviewed-by: Mike Percy <mp...@apache.org>
(cherry picked from commit cb203729255dba06120d2a2f8702032a2ffd9694)
---
M src/kudu/consensus/quorum_util-test.cc
M src/kudu/consensus/quorum_util.cc
2 files changed, 86 insertions(+), 1 deletion(-)



  git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/64/10464/1
-- 
To view, visit http://gerrit.cloudera.org:8080/10464
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: kudu
Gerrit-Branch: branch-1.7.x
Gerrit-MessageType: newchange
Gerrit-Change-Id: I9da9fe6788f28b40f7adc53e23540bcdf103c1ea
Gerrit-Change-Number: 10464
Gerrit-PatchSet: 1
Gerrit-Owner: Grant Henke <gr...@apache.org>
Gerrit-Reviewer: Alexey Serbin <as...@cloudera.com>

[kudu-CR](branch-1.7.x) [consensus] KUDU-2443 fix replica replacement of RF=1

Posted by "Alexey Serbin (Code Review)" <ge...@cloudera.org>.
Alexey Serbin has posted comments on this change. ( http://gerrit.cloudera.org:8080/10464 )

Change subject: [consensus] KUDU-2443 fix replica replacement of RF=1
......................................................................


Patch Set 1: Code-Review+2


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

Gerrit-Project: kudu
Gerrit-Branch: branch-1.7.x
Gerrit-MessageType: comment
Gerrit-Change-Id: I9da9fe6788f28b40f7adc53e23540bcdf103c1ea
Gerrit-Change-Number: 10464
Gerrit-PatchSet: 1
Gerrit-Owner: Grant Henke <gr...@apache.org>
Gerrit-Reviewer: Alexey Serbin <as...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Comment-Date: Mon, 21 May 2018 15:33:11 +0000
Gerrit-HasComments: No

[kudu-CR](branch-1.7.x) [consensus] KUDU-2443 fix replica replacement of RF=1

Posted by "Grant Henke (Code Review)" <ge...@cloudera.org>.
Grant Henke has submitted this change and it was merged. ( http://gerrit.cloudera.org:8080/10464 )

Change subject: [consensus] KUDU-2443 fix replica replacement of RF=1
......................................................................

[consensus] KUDU-2443 fix replica replacement of RF=1

Fixed bug in the consensus::ShouldEvictReplica() function for the case
when the leader replica of a tablet with replication factor of 1
is marked with the REPLACE attribute and there is an extra voter
replica in the tablet's Raft config.

Prior to this fix, the master would evict the extra voter from the
configuration and then it would add a new non-voter because of the
consensus::ShouldAddReplica() method's behavior.  After the newly
added non-voter replica catches up and becomes a voter, that would
happen again and again, until the REPLACE attribute is removed.

This changelist also includes regression tests to cover the
corresponding functionality.  Also, additional test scenarios added
to extend the coverage for the single-replica edge case.

Change-Id: I9da9fe6788f28b40f7adc53e23540bcdf103c1ea
Reviewed-on: http://gerrit.cloudera.org:8080/10438
Tested-by: Kudu Jenkins
Reviewed-by: Mike Percy <mp...@apache.org>
(cherry picked from commit cb203729255dba06120d2a2f8702032a2ffd9694)
Reviewed-on: http://gerrit.cloudera.org:8080/10464
Reviewed-by: Alexey Serbin <as...@cloudera.com>
---
M src/kudu/consensus/quorum_util-test.cc
M src/kudu/consensus/quorum_util.cc
2 files changed, 86 insertions(+), 1 deletion(-)

Approvals:
  Alexey Serbin: Looks good to me, approved
  Kudu Jenkins: Verified

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

Gerrit-Project: kudu
Gerrit-Branch: branch-1.7.x
Gerrit-MessageType: merged
Gerrit-Change-Id: I9da9fe6788f28b40f7adc53e23540bcdf103c1ea
Gerrit-Change-Number: 10464
Gerrit-PatchSet: 2
Gerrit-Owner: Grant Henke <gr...@apache.org>
Gerrit-Reviewer: Alexey Serbin <as...@cloudera.com>
Gerrit-Reviewer: Grant Henke <gr...@apache.org>
Gerrit-Reviewer: Kudu Jenkins