cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jbel...@apache.org
Subject svn commit: r904677 - /incubator/cassandra/branches/cassandra-0.5/src/java/org/apache/cassandra/io/Streaming.java
Date Fri, 29 Jan 2010 23:47:15 GMT
Author: jbellis
Date: Fri Jan 29 23:47:14 2010
New Revision: 904677

URL: http://svn.apache.org/viewvc?rev=904677&view=rev
Log:
avoid setting up completion handler for no-op stream in non-bootstrap mode.  patch by jbellis;
reviewed by gdusbabek for CASSANDRA-750

Modified:
    incubator/cassandra/branches/cassandra-0.5/src/java/org/apache/cassandra/io/Streaming.java

Modified: incubator/cassandra/branches/cassandra-0.5/src/java/org/apache/cassandra/io/Streaming.java
URL: http://svn.apache.org/viewvc/incubator/cassandra/branches/cassandra-0.5/src/java/org/apache/cassandra/io/Streaming.java?rev=904677&r1=904676&r2=904677&view=diff
==============================================================================
--- incubator/cassandra/branches/cassandra-0.5/src/java/org/apache/cassandra/io/Streaming.java
(original)
+++ incubator/cassandra/branches/cassandra-0.5/src/java/org/apache/cassandra/io/Streaming.java
Fri Jan 29 23:47:14 2010
@@ -173,11 +173,12 @@
                 StreamInitiateMessage biMsg = StreamInitiateMessage.serializer().deserialize(bufIn);
                 StreamContextManager.StreamContext[] streamContexts = biMsg.getStreamContext();
 
-                if (streamContexts.length == 0 && StorageService.instance().isBootstrapMode())
+                if (streamContexts.length == 0)
                 {
                     if (logger.isDebugEnabled())
                         logger.debug("no data needed from " + message.getFrom());
-                    StorageService.instance().removeBootstrapSource(message.getFrom(), new
String(message.getHeader(Streaming.TABLE_NAME)));
+                    if (StorageService.instance().isBootstrapMode())
+                        StorageService.instance().removeBootstrapSource(message.getFrom(),
new String(message.getHeader(Streaming.TABLE_NAME)));
                     return;
                 }
 



Mime
View raw message