usergrid-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sfeld...@apache.org
Subject incubator-usergrid git commit: resolve futures via done method
Date Wed, 11 Mar 2015 22:26:12 GMT
Repository: incubator-usergrid
Updated Branches:
  refs/heads/USERGRID-466 9630fcf2a -> ad33ecfd1


resolve futures via done method


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

Branch: refs/heads/USERGRID-466
Commit: ad33ecfd1146a98009c141f1ea6948b9d280f7d7
Parents: 9630fcf
Author: Shawn Feldman <sfeldman@apache.org>
Authored: Wed Mar 11 16:26:05 2015 -0600
Committer: Shawn Feldman <sfeldman@apache.org>
Committed: Wed Mar 11 16:26:05 2015 -0600

----------------------------------------------------------------------
 .../apache/usergrid/persistence/index/IndexOperationMessage.java | 4 ++++
 .../usergrid/persistence/index/impl/BufferQueueInMemoryImpl.java | 1 +
 .../usergrid/persistence/index/impl/BufferQueueSQSImpl.java      | 2 +-
 3 files changed, 6 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/ad33ecfd/stack/corepersistence/queryindex/src/main/java/org/apache/usergrid/persistence/index/IndexOperationMessage.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/queryindex/src/main/java/org/apache/usergrid/persistence/index/IndexOperationMessage.java
b/stack/corepersistence/queryindex/src/main/java/org/apache/usergrid/persistence/index/IndexOperationMessage.java
index a7388d6..33b68cd 100644
--- a/stack/corepersistence/queryindex/src/main/java/org/apache/usergrid/persistence/index/IndexOperationMessage.java
+++ b/stack/corepersistence/queryindex/src/main/java/org/apache/usergrid/persistence/index/IndexOperationMessage.java
@@ -126,4 +126,8 @@ public class IndexOperationMessage implements Serializable {
         result = 31 * result + deIndexRequests.hashCode();
         return result;
     }
+
+    public void done() {
+        getFuture().done();
+    }
 }

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/ad33ecfd/stack/corepersistence/queryindex/src/main/java/org/apache/usergrid/persistence/index/impl/BufferQueueInMemoryImpl.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/queryindex/src/main/java/org/apache/usergrid/persistence/index/impl/BufferQueueInMemoryImpl.java
b/stack/corepersistence/queryindex/src/main/java/org/apache/usergrid/persistence/index/impl/BufferQueueInMemoryImpl.java
index 1973e5d..6716fd1 100644
--- a/stack/corepersistence/queryindex/src/main/java/org/apache/usergrid/persistence/index/impl/BufferQueueInMemoryImpl.java
+++ b/stack/corepersistence/queryindex/src/main/java/org/apache/usergrid/persistence/index/impl/BufferQueueInMemoryImpl.java
@@ -47,6 +47,7 @@ public class BufferQueueInMemoryImpl implements BufferQueue {
     @Override
     public void offer( final IndexOperationMessage operation ) {
         messages.offer( operation );
+        operation.done();
     }
 
 

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/ad33ecfd/stack/corepersistence/queryindex/src/main/java/org/apache/usergrid/persistence/index/impl/BufferQueueSQSImpl.java
----------------------------------------------------------------------
diff --git a/stack/corepersistence/queryindex/src/main/java/org/apache/usergrid/persistence/index/impl/BufferQueueSQSImpl.java
b/stack/corepersistence/queryindex/src/main/java/org/apache/usergrid/persistence/index/impl/BufferQueueSQSImpl.java
index 25c2ba6..1b0529f 100644
--- a/stack/corepersistence/queryindex/src/main/java/org/apache/usergrid/persistence/index/impl/BufferQueueSQSImpl.java
+++ b/stack/corepersistence/queryindex/src/main/java/org/apache/usergrid/persistence/index/impl/BufferQueueSQSImpl.java
@@ -141,7 +141,7 @@ public class BufferQueueSQSImpl implements BufferQueue {
 
             //signal to SQS
             this.queue.sendMessage( identifier );
-            operation.getFuture().run();
+            operation.done();
         }
         catch ( IOException e ) {
             throw new RuntimeException( "Unable to queue message", e );


Mime
View raw message