ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From yzhda...@apache.org
Subject [58/61] [abbrv] incubator-ignite git commit: futures: api cleanup
Date Thu, 05 Mar 2015 10:49:29 GMT
futures: api cleanup


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

Branch: refs/heads/ignite-143
Commit: 10bb0da5bda6f5ef6dcd0a0f622e9c2a8af3d023
Parents: 6e52162
Author: Yakov Zhdanov <yzhdanov@gridgain.com>
Authored: Thu Mar 5 12:00:04 2015 +0300
Committer: Yakov Zhdanov <yzhdanov@gridgain.com>
Committed: Thu Mar 5 12:00:04 2015 +0300

----------------------------------------------------------------------
 .../managers/communication/GridIoManager.java      | 17 +++++++++--------
 .../processors/cache/GridCacheMultiTxFuture.java   | 11 +++++------
 .../internal/util/future/GridFutureAdapter.java    |  4 ++--
 3 files changed, 16 insertions(+), 16 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/10bb0da5/modules/core/src/main/java/org/apache/ignite/internal/managers/communication/GridIoManager.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/managers/communication/GridIoManager.java
b/modules/core/src/main/java/org/apache/ignite/internal/managers/communication/GridIoManager.java
index 968e93a..67ae808 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/managers/communication/GridIoManager.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/managers/communication/GridIoManager.java
@@ -560,8 +560,8 @@ public class GridIoManager extends GridManagerAdapter<CommunicationSpi<Serializa
     ) {
         workersCnt.increment();
 
-        Runnable c = new GridWorker(ctx.gridName(), "msg-worker", log) {
-            @Override protected void body() {
+        Runnable c = new Runnable() {
+            @Override public void run() {
                 try {
                     threadProcessingMessage(true);
 
@@ -612,8 +612,8 @@ public class GridIoManager extends GridManagerAdapter<CommunicationSpi<Serializa
     ) {
         workersCnt.increment();
 
-        Runnable c = new GridWorker(ctx.gridName(), "msg-worker", log) {
-            @Override protected void body() {
+        Runnable c = new Runnable() {
+            @Override public void run() {
                 try {
                     threadProcessingMessage(true);
 
@@ -811,8 +811,8 @@ public class GridIoManager extends GridManagerAdapter<CommunicationSpi<Serializa
 
         final GridCommunicationMessageSet msgSet0 = set;
 
-        Runnable c = new GridWorker(ctx.gridName(), "msg-worker", log) {
-            @Override protected void body() {
+        Runnable c = new Runnable() {
+            @Override public void run() {
                 try {
                     threadProcessingMessage(true);
 
@@ -1329,8 +1329,9 @@ public class GridIoManager extends GridManagerAdapter<CommunicationSpi<Serializa
 
                     workersCnt.increment();
 
-                    pool(msgSet.policy()).execute(new GridWorker(ctx.gridName(), "msg-worker",
log) {
-                        @Override protected void body() {
+                    pool(msgSet.policy()).execute(
+                        new Runnable() {
+                            @Override public void run() {
                             try {
                                 unwindMessageSet(msgSet, lsnrs0);
                             }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/10bb0da5/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMultiTxFuture.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMultiTxFuture.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMultiTxFuture.java
index 71ba123..7df184e 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMultiTxFuture.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMultiTxFuture.java
@@ -35,19 +35,18 @@ public final class GridCacheMultiTxFuture<K, V> extends GridFutureAdapter<Boolea
     /** Logger reference. */
     private static final AtomicReference<IgniteLogger> logRef = new AtomicReference<>();
 
+    /** Logger. */
+    private static IgniteLogger log;
+
     /** */
     private Set<IgniteInternalTx<K, V>> remainingTxs;
 
-    /** Logger. */
-    private IgniteLogger log;
-
     /**
      * @param cctx Cache context.
      */
     public GridCacheMultiTxFuture(GridCacheContext<K, V> cctx) {
-        super();
-
-        log = U.logger(cctx.kernalContext(),  logRef, GridCacheMultiTxFuture.class);
+        if (log == null)
+            log = U.logger(cctx.kernalContext(), logRef, GridCacheMultiTxFuture.class);
     }
 
     /**

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/10bb0da5/modules/core/src/main/java/org/apache/ignite/internal/util/future/GridFutureAdapter.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/util/future/GridFutureAdapter.java
b/modules/core/src/main/java/org/apache/ignite/internal/util/future/GridFutureAdapter.java
index b35d18a..21ad1ab 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/util/future/GridFutureAdapter.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/util/future/GridFutureAdapter.java
@@ -204,9 +204,9 @@ public class GridFutureAdapter<R> extends AbstractQueuedSynchronizer
implements
             lsnr = null;
         }
 
-        assert lsnr == null;
+        assert lsnrs0 == null;
 
-        notifyListener(lsnr);
+        notifyListener(lsnrs0);
     }
 
     /**


Mime
View raw message