cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jasobr...@apache.org
Subject git commit: skip blocking on streaming during drain patch by jasobrown; reviewed by yukim for CASSANDRA-6603
Date Fri, 17 Jan 2014 23:10:54 GMT
Updated Branches:
  refs/heads/cassandra-1.2 b78617b22 -> 3de845426


skip blocking on streaming during drain
patch by jasobrown; reviewed by yukim for CASSANDRA-6603


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

Branch: refs/heads/cassandra-1.2
Commit: 3de845426aebaba733d616f7e6426b2a6c410a3e
Parents: b78617b
Author: Jason Brown <jasedbrown@gmail.com>
Authored: Fri Jan 17 13:33:08 2014 -0800
Committer: Jason Brown <jasedbrown@gmail.com>
Committed: Fri Jan 17 15:10:26 2014 -0800

----------------------------------------------------------------------
 CHANGES.txt                                           |  1 +
 .../org/apache/cassandra/net/MessagingService.java    | 14 --------------
 .../org/apache/cassandra/service/StorageService.java  |  2 --
 3 files changed, 1 insertion(+), 16 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/3de84542/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index f550863..0b49665 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -12,6 +12,7 @@
  * Avoid StackOverflow when using large IN queries (CASSANDRA-6567)
  * Nodetool upgradesstables includes secondary indexes (CASSANDRA-6589)
  * Paginate batchlog replay (CASSANDRA-6569)
+ * skip blocking on streaming during drain (CASSANDRA-6603)
 
 
 1.2.13

http://git-wip-us.apache.org/repos/asf/cassandra/blob/3de84542/src/java/org/apache/cassandra/net/MessagingService.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/net/MessagingService.java b/src/java/org/apache/cassandra/net/MessagingService.java
index 7e420cf..3ec3267 100644
--- a/src/java/org/apache/cassandra/net/MessagingService.java
+++ b/src/java/org/apache/cassandra/net/MessagingService.java
@@ -672,20 +672,6 @@ public final class MessagingService implements MessagingServiceMBean
         callbacks.reset();
     }
 
-    public void waitForStreaming() throws InterruptedException
-    {
-        // this does not prevent new streams from beginning after a drain begins, but since
streams are only
-        // started in response to explicit operator action (bootstrap/move/repair/etc) that
feels like a feature.
-        for (DebuggableThreadPoolExecutor e : streamExecutors.values())
-            e.shutdown();
-
-        for (DebuggableThreadPoolExecutor e : streamExecutors.values())
-        {
-            if (!e.awaitTermination(24, TimeUnit.HOURS))
-                logger.error("Stream took more than 24H to complete; skipping");
-        }
-    }
-
     /**
      * Wait for callbacks and don't allow any more to be created (since they could require
writing hints)
      */

http://git-wip-us.apache.org/repos/asf/cassandra/blob/3de84542/src/java/org/apache/cassandra/service/StorageService.java
----------------------------------------------------------------------
diff --git a/src/java/org/apache/cassandra/service/StorageService.java b/src/java/org/apache/cassandra/service/StorageService.java
index 90089ab..8491cb0 100644
--- a/src/java/org/apache/cassandra/service/StorageService.java
+++ b/src/java/org/apache/cassandra/service/StorageService.java
@@ -3403,8 +3403,6 @@ public class StorageService extends NotificationBroadcasterSupport implements
IE
 
         setMode(Mode.DRAINING, "shutting down MessageService", false);
         MessagingService.instance().shutdown();
-        setMode(Mode.DRAINING, "waiting for streaming", false);
-        MessagingService.instance().waitForStreaming();
 
         setMode(Mode.DRAINING, "clearing mutation stage", false);
         mutationStage.shutdown();


Mime
View raw message