cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jbel...@apache.org
Subject svn commit: r1029541 - /cassandra/branches/cassandra-0.6/src/java/org/apache/cassandra/net/MessageDeliveryTask.java
Date Mon, 01 Nov 2010 03:46:39 GMT
Author: jbellis
Date: Mon Nov  1 03:46:39 2010
New Revision: 1029541

URL: http://svn.apache.org/viewvc?rev=1029541&view=rev
Log:
Avoid dropping messages off the client request path
patch by jbellis; reviewed by Stu Hood for CASSANDRA-1676

Modified:
    cassandra/branches/cassandra-0.6/src/java/org/apache/cassandra/net/MessageDeliveryTask.java

Modified: cassandra/branches/cassandra-0.6/src/java/org/apache/cassandra/net/MessageDeliveryTask.java
URL: http://svn.apache.org/viewvc/cassandra/branches/cassandra-0.6/src/java/org/apache/cassandra/net/MessageDeliveryTask.java?rev=1029541&r1=1029540&r2=1029541&view=diff
==============================================================================
--- cassandra/branches/cassandra-0.6/src/java/org/apache/cassandra/net/MessageDeliveryTask.java
(original)
+++ cassandra/branches/cassandra-0.6/src/java/org/apache/cassandra/net/MessageDeliveryTask.java
Mon Nov  1 03:46:39 2010
@@ -36,13 +36,23 @@ public class MessageDeliveryTask impleme
     }
     
     public void run()
-    { 
+    {
         StorageService.Verb verb = message_.getVerb();
-
-        if (System.currentTimeMillis() >  constructionTime_ + DatabaseDescriptor.getRpcTimeout())
+        switch (verb)
         {
-            MessagingService.incrementDroppedMessages(verb);
-            return;
+            case BINARY:
+            case MUTATION:
+            case READ:
+            case RANGE_SLICE:
+            case READ_REPAIR:
+                if (System.currentTimeMillis() > constructionTime_ + DatabaseDescriptor.getRpcTimeout())
+                {
+                    MessagingService.incrementDroppedMessages(verb);
+                    return;
+                }
+                break;
+            default:
+                break;
         }
 
         IVerbHandler verbHandler = MessagingService.instance.getVerbHandler(verb);



Mime
View raw message