cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From zzn...@apache.org
Subject [09/50] [abbrv] cassandra git commit: Fix nodetool repair exits with 0 for some errors
Date Tue, 20 Sep 2016 02:32:15 GMT
Fix nodetool repair exits with 0 for some errors

patch by Blake Eggleston; reviewed by yukim for CASSANDRA-12508


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

Branch: refs/heads/cassandra-3.9
Commit: f092f7be2f315b9804d7160cb7f5a40f1df38155
Parents: 0fd07e8
Author: Blake Eggleston <bdeggleston@gmail.com>
Authored: Mon Aug 15 08:38:01 2016 -0700
Committer: Yuki Morishita <yukim@apache.org>
Committed: Fri Aug 26 08:26:21 2016 -0500

----------------------------------------------------------------------
 CHANGES.txt                                           | 1 +
 src/java/org/apache/cassandra/tools/RepairRunner.java | 4 ++++
 2 files changed, 5 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/f092f7be/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index d6f2a9d..59c8a4b 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -1,4 +1,5 @@
 3.0.9
+ * Fix nodetool repair exits with 0 for some errors (CASSANDRA-12508)
  * Do not shut down BatchlogManager twice during drain (CASSANDRA-12504)
  * Disk failure policy should not be invoked on out of space (CASSANDRA-12385)
  * Calculate last compacted key on startup (CASSANDRA-6216)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/f092f7be/src/java/org/apache/cassandra/tools/RepairRunner.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/tools/RepairRunner.java b/src/java/org/apache/cassandra/tools/RepairRunner.java
index 0813775..12ae5b8 100644
--- a/src/java/org/apache/cassandra/tools/RepairRunner.java
+++ b/src/java/org/apache/cassandra/tools/RepairRunner.java
@@ -110,6 +110,10 @@ public class RepairRunner extends JMXNotificationProgressListener
             message = message + " (progress: " + (int)event.getProgressPercentage() + "%)";
         }
         out.println(message);
+        if (type == ProgressEventType.ERROR)
+        {
+            error = new RuntimeException("Repair job has failed with the error message: "
+ message);
+        }
         if (type == ProgressEventType.COMPLETE)
         {
             condition.signalAll();


Mime
View raw message