kudu-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mpe...@apache.org
Subject kudu git commit: consensus: Revert terminal state enforcement of FAILED_UNRECOVERABLE
Date Sat, 24 Mar 2018 02:26:40 GMT
Repository: kudu
Updated Branches:
  refs/heads/master 7b88a4233 -> b531da26a


consensus: Revert terminal state enforcement of FAILED_UNRECOVERABLE

In patch 7b88a42332540ace18ea033439ceac0e7cb68411 FAILED_UNRECOVERABLE
was noted as a terminal state. Todd pointed out that there are certain
corner cases where that may not be the case, such as a replica that
started up on a temporarily-failed or read-only disk, and then was
restarted. In such a case, if the leader was previously unable to evict
that node because of a lack of a majority, the affected replica may
revert to a HEALTHY state.

Change-Id: I2f858af8c578340f7a32b95702b5da7bbe81a675
Reviewed-on: http://gerrit.cloudera.org:8080/9794
Reviewed-by: Alexey Serbin <aserbin@cloudera.com>
Tested-by: Kudu Jenkins


Project: http://git-wip-us.apache.org/repos/asf/kudu/repo
Commit: http://git-wip-us.apache.org/repos/asf/kudu/commit/b531da26
Tree: http://git-wip-us.apache.org/repos/asf/kudu/tree/b531da26
Diff: http://git-wip-us.apache.org/repos/asf/kudu/diff/b531da26

Branch: refs/heads/master
Commit: b531da26acf23d6f2969c66d458d598d56d37bd5
Parents: 7b88a42
Author: Mike Percy <mpercy@apache.org>
Authored: Fri Mar 23 16:10:57 2018 -0700
Committer: Mike Percy <mpercy@apache.org>
Committed: Sat Mar 24 02:26:24 2018 +0000

----------------------------------------------------------------------
 src/kudu/consensus/consensus_queue.cc | 8 --------
 src/kudu/consensus/metadata.proto     | 8 ++------
 2 files changed, 2 insertions(+), 14 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/kudu/blob/b531da26/src/kudu/consensus/consensus_queue.cc
----------------------------------------------------------------------
diff --git a/src/kudu/consensus/consensus_queue.cc b/src/kudu/consensus/consensus_queue.cc
index 9fd91da..8b6f397 100644
--- a/src/kudu/consensus/consensus_queue.cc
+++ b/src/kudu/consensus/consensus_queue.cc
@@ -531,14 +531,6 @@ void PeerMessageQueue::UpdatePeerHealthUnlocked(TrackedPeer* peer) {
   }
 
   bool changed = overall_health_status != peer->last_overall_health_status;
-  if (changed) {
-    // FAILED_UNRECOVERABLE is a terminal state; it's illegal to transition out of it.
-    DCHECK_NE(HealthReportPB::FAILED_UNRECOVERABLE, peer->last_overall_health_status)
-        << "Transitioning out of FAILED_UNRECOVERABLE health status should not be possible.
"
-        << "old health status: "
-        << HealthReportPB::HealthStatus_Name(peer->last_overall_health_status) <<
", "
-        << "new health status: " << HealthReportPB::HealthStatus_Name(overall_health_status);
-  }
   peer->last_overall_health_status = overall_health_status;
 
   if (FLAGS_raft_prepare_replacement_before_eviction) {

http://git-wip-us.apache.org/repos/asf/kudu/blob/b531da26/src/kudu/consensus/metadata.proto
----------------------------------------------------------------------
diff --git a/src/kudu/consensus/metadata.proto b/src/kudu/consensus/metadata.proto
index 9c8eb70..045b20e 100644
--- a/src/kudu/consensus/metadata.proto
+++ b/src/kudu/consensus/metadata.proto
@@ -39,12 +39,8 @@ message RaftPeerAttrsPB {
 
 // Report on a replica's (peer's) health.
 message HealthReportPB {
-  // HealthStatus respresents a state machine with the following transitions
-  // allowed:
-  //   HEALTHY -> UNKNOWN, FAILED, or FAILED_UNRECOVERABLE.
-  //   UNKNOWN -> FAILED, HEALTHY, or FAILED_UNRECOVERABLE.
-  //   FAILED -> UNKNOWN, HEALTHY, or FAILED_UNRECOVERABLE.
-  //   FAILED_UNRECOVERABLE is a terminal state.
+  // HealthStatus respresents a fully-connected state machine, where
+  // transitions between any of the states are allowed.
   enum HealthStatus {
     // No information on the health status.
     UNKNOWN = 999;


Mime
View raw message