[jbosscache-commits] JBoss Cache SVN: r5634 - core/trunk/src/main/java/org/jboss/cache/commands/remote.

jbosscache-commits at lists.jboss.org jbosscache-commits at lists.jboss.org
Tue Apr 22 20:06:30 EDT 2008


Author: manik.surtani at jboss.com
Date: 2008-04-22 20:06:30 -0400 (Tue, 22 Apr 2008)
New Revision: 5634

Modified:
   core/trunk/src/main/java/org/jboss/cache/commands/remote/ReplicateCommand.java
Log:
Fixed replication queue handling

Modified: core/trunk/src/main/java/org/jboss/cache/commands/remote/ReplicateCommand.java
===================================================================
--- core/trunk/src/main/java/org/jboss/cache/commands/remote/ReplicateCommand.java	2008-04-22 23:56:54 UTC (rev 5633)
+++ core/trunk/src/main/java/org/jboss/cache/commands/remote/ReplicateCommand.java	2008-04-23 00:06:30 UTC (rev 5634)
@@ -80,15 +80,22 @@
       {
          if (trace) log.trace("Invoking command " + cacheCommand + ", with originLocal flag set to false.");
 
-         Object retVal = invoker.invokeRemote(cacheCommand);
-         // we only need to return values for a set of remote calls; not every call.
-         if (returnValueForRemoteCall(cacheCommand))
+         if (cacheCommand instanceof DirectCommand)
          {
-            result = retVal;
+            result = ((DirectCommand) cacheCommand).performDirectly();
          }
          else
          {
-            result = null;
+            Object retVal = invoker.invokeRemote(cacheCommand);
+            // we only need to return values for a set of remote calls; not every call.
+            if (returnValueForRemoteCall(cacheCommand))
+            {
+               result = retVal;
+            }
+            else
+            {
+               result = null;
+            }
          }
       }
       catch (Throwable ex)




More information about the jbosscache-commits mailing list