ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sevdoki...@apache.org
Subject [01/51] [abbrv] incubator-ignite git commit: futures: api cleanup
Date Tue, 10 Mar 2015 09:48:08 GMT
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-47 d41ceef50 -> 292825fbf


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/local/GridLocalLockFuture.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/local/GridLocalLockFuture.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/local/GridLocalLockFuture.java
index 2048e5d..320a443 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/local/GridLocalLockFuture.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/local/GridLocalLockFuture.java
@@ -30,7 +30,6 @@ import org.apache.ignite.lang.*;
 import org.jetbrains.annotations.*;
 
 import javax.cache.*;
-import java.io.*;
 import java.util.*;
 import java.util.concurrent.atomic.*;
 
@@ -39,12 +38,12 @@ import java.util.concurrent.atomic.*;
  */
 public final class GridLocalLockFuture<K, V> extends GridFutureAdapter<Boolean>
     implements GridCacheMvccFuture<K, V, Boolean> {
-    /** */
-    private static final long serialVersionUID = 0L;
-
     /** Logger reference. */
     private static final AtomicReference<IgniteLogger> logRef = new AtomicReference<>();
 
+    /** Logger. */
+    private static IgniteLogger log;
+
     /** Cache registry. */
     @GridToStringExclude
     private GridCacheContext<K, V> cctx;
@@ -77,10 +76,6 @@ public final class GridLocalLockFuture<K, V> extends GridFutureAdapter<Boolean>
     /** Lock timeout. */
     private long timeout;
 
-    /** Logger. */
-    @GridToStringExclude
-    private IgniteLogger log;
-
     /** Filter. */
     private IgnitePredicate<Cache.Entry<K, V>>[] filter;
 
@@ -91,13 +86,6 @@ public final class GridLocalLockFuture<K, V> extends GridFutureAdapter<Boolean>
     private boolean trackable = true;
 
     /**
-     * Empty constructor required by {@link Externalizable}.
-     */
-    public GridLocalLockFuture() {
-        // No-op.
-    }
-
-    /**
      * @param cctx Registry.
      * @param keys Keys to lock.
      * @param tx Transaction.
@@ -112,8 +100,6 @@ public final class GridLocalLockFuture<K, V> extends GridFutureAdapter<Boolean>
         GridLocalCache<K, V> cache,
         long timeout,
         IgnitePredicate<Cache.Entry<K, V>>[] filter) {
-        super();
-
         assert keys != null;
         assert cache != null;
 
@@ -131,7 +117,8 @@ public final class GridLocalLockFuture<K, V> extends GridFutureAdapter<Boolean>
 
         entries = new ArrayList<>(keys.size());
 
-        log = U.logger(cctx.kernalContext(), logRef, GridLocalLockFuture.class);
+        if (log == null)
+            log = U.logger(cctx.kernalContext(), logRef, GridLocalLockFuture.class);
 
         if (timeout > 0) {
             timeoutObj = new LockTimeoutObject();

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/local/GridLocalTxFuture.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/local/GridLocalTxFuture.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/local/GridLocalTxFuture.java
index b9934fc..c80292c 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/local/GridLocalTxFuture.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/local/GridLocalTxFuture.java
@@ -28,7 +28,6 @@ import org.apache.ignite.internal.util.tostring.*;
 import org.apache.ignite.internal.util.typedef.internal.*;
 import org.apache.ignite.lang.*;
 
-import java.io.*;
 import java.util.*;
 import java.util.concurrent.atomic.*;
 
@@ -39,12 +38,12 @@ import static org.apache.ignite.transactions.TransactionState.*;
  */
 final class GridLocalTxFuture<K, V> extends GridFutureAdapter<IgniteInternalTx<K, V>>
     implements GridCacheMvccFuture<K, V, IgniteInternalTx<K, V>> {
-    /** */
-    private static final long serialVersionUID = 0L;
-
     /** Logger reference. */
     private static final AtomicReference<IgniteLogger> logRef = new AtomicReference<>();
 
+    /** Logger. */
+    private static IgniteLogger log;
+
     /** Future ID. */
     private IgniteUuid futId = IgniteUuid.randomUuid();
 
@@ -62,36 +61,24 @@ final class GridLocalTxFuture<K, V> extends GridFutureAdapter<IgniteInternalTx<K
     /** Commit flag. */
     private AtomicBoolean commit = new AtomicBoolean(false);
 
-    /** Logger. */
-    @GridToStringExclude
-    private IgniteLogger log;
-
     /** Trackable flag. */
     private boolean trackable = true;
 
     /**
-     * Empty constructor required by {@link Externalizable}.
-     */
-    public GridLocalTxFuture() {
-        // No-op.
-    }
-
-    /**
      * @param cctx Context.
      * @param tx Cache transaction.
      */
     GridLocalTxFuture(
         GridCacheSharedContext<K, V> cctx,
         GridLocalTx<K, V> tx) {
-        super();
-
         assert cctx != null;
         assert tx != null;
 
         this.cctx = cctx;
         this.tx = tx;
 
-        log = U.logger(cctx.kernalContext(), logRef,  GridLocalTxFuture.class);
+        if (log == null)
+            log = U.logger(cctx.kernalContext(), logRef,  GridLocalTxFuture.class);
     }
 
     /** {@inheritDoc} */
@@ -126,20 +113,6 @@ final class GridLocalTxFuture<K, V> extends GridFutureAdapter<IgniteInternalTx<K
     }
 
     /**
-     * @return Lock version.
-     */
-    GridLocalTx<K, V> tx() {
-        return tx;
-    }
-
-    /**
-     *
-     */
-    void complete() {
-        onComplete();
-    }
-
-    /**
      * @param e Error.
      */
     void onError(Throwable e) {
@@ -154,18 +127,6 @@ final class GridLocalTxFuture<K, V> extends GridFutureAdapter<IgniteInternalTx<K
      * @param e Error.
      */
     @SuppressWarnings({"TypeMayBeWeakened"})
-    void onError(IgniteTxOptimisticCheckedException e) {
-        if (err.compareAndSet(null, e)) {
-            tx.setRollbackOnly();
-
-            onComplete();
-        }
-    }
-
-    /**
-     * @param e Error.
-     */
-    @SuppressWarnings({"TypeMayBeWeakened"})
     void onError(IgniteTxRollbackCheckedException e) {
         if (err.compareAndSet(null, e)) {
             // Attempt rollback.
@@ -334,16 +295,6 @@ final class GridLocalTxFuture<K, V> extends GridFutureAdapter<IgniteInternalTx<K
             cctx.mvcc().removeFuture(this);
     }
 
-    /**
-     * Checks for errors.
-     *
-     * @throws IgniteCheckedException If execution failed.
-     */
-    private void checkError() throws IgniteCheckedException {
-        if (err.get() != null)
-            throw U.cast(err.get());
-    }
-
     /** {@inheritDoc} */
     @Override public String toString() {
         return GridToStringBuilder.toString(GridLocalTxFuture.class, this);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheDistributedFieldsQueryFuture.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheDistributedFieldsQueryFuture.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheDistributedFieldsQueryFuture.java
index 1093c4e..7ad8994 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheDistributedFieldsQueryFuture.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheDistributedFieldsQueryFuture.java
@@ -24,7 +24,6 @@ import org.apache.ignite.internal.processors.query.*;
 import org.apache.ignite.internal.util.future.*;
 import org.jetbrains.annotations.*;
 
-import java.io.*;
 import java.util.*;
 
 /**
@@ -40,13 +39,6 @@ public class GridCacheDistributedFieldsQueryFuture
     private final GridFutureAdapter<List<GridQueryFieldMetadata>> metaFut;
 
     /**
-     * Required by {@link Externalizable}.
-     */
-    public GridCacheDistributedFieldsQueryFuture() {
-        metaFut = null;
-    }
-
-    /**
      * @param ctx Cache context.
      * @param reqId Request ID.
      * @param qry Query.

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheDistributedQueryFuture.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheDistributedQueryFuture.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheDistributedQueryFuture.java
index bd8385b..b514ac0 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheDistributedQueryFuture.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheDistributedQueryFuture.java
@@ -24,7 +24,6 @@ import org.apache.ignite.internal.processors.cache.*;
 import org.apache.ignite.internal.util.typedef.*;
 import org.apache.ignite.internal.util.typedef.internal.*;
 
-import java.io.*;
 import java.util.*;
 import java.util.concurrent.*;
 
@@ -33,9 +32,6 @@ import java.util.concurrent.*;
  */
 public class GridCacheDistributedQueryFuture<K, V, R> extends GridCacheQueryFutureAdapter<K, V, R> {
     /** */
-    private static final long serialVersionUID = 0L;
-
-    /** */
     private long reqId;
 
     /** */
@@ -48,13 +44,6 @@ public class GridCacheDistributedQueryFuture<K, V, R> extends GridCacheQueryFutu
     private CountDownLatch firstPageLatch = new CountDownLatch(1);
 
     /**
-     * Required by {@link Externalizable}.
-     */
-    public GridCacheDistributedQueryFuture() {
-        // No-op.
-    }
-
-    /**
      * @param ctx Cache context.
      * @param reqId Request ID.
      * @param qry Query.

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheLocalFieldsQueryFuture.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheLocalFieldsQueryFuture.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheLocalFieldsQueryFuture.java
index 70d97fe..e6d545a 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheLocalFieldsQueryFuture.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheLocalFieldsQueryFuture.java
@@ -23,7 +23,6 @@ import org.apache.ignite.internal.processors.query.*;
 import org.apache.ignite.internal.util.future.*;
 import org.jetbrains.annotations.*;
 
-import java.io.*;
 import java.util.*;
 
 /**
@@ -39,13 +38,6 @@ public class GridCacheLocalFieldsQueryFuture
     private final GridFutureAdapter<List<GridQueryFieldMetadata>> metaFut;
 
     /**
-     * Required by {@link Externalizable}.
-     */
-    public GridCacheLocalFieldsQueryFuture() {
-        metaFut = null;
-    }
-
-    /**
      * @param ctx Cache context.
      * @param qry Query.
      */

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheLocalQueryFuture.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheLocalQueryFuture.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheLocalQueryFuture.java
index 8831b5d..3204653 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheLocalQueryFuture.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheLocalQueryFuture.java
@@ -26,7 +26,6 @@ import org.apache.ignite.lang.*;
 import org.apache.ignite.marshaller.*;
 
 import javax.cache.*;
-import java.io.*;
 import java.util.*;
 
 /**
@@ -43,13 +42,6 @@ public class GridCacheLocalQueryFuture<K, V, R> extends GridCacheQueryFutureAdap
     private IgniteInternalFuture<?> fut;
 
     /**
-     * Required by {@link Externalizable}.
-     */
-    public GridCacheLocalQueryFuture() {
-        // No-op.
-    }
-
-    /**
      * @param ctx Context.
      * @param qry Query.
      */

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryFutureAdapter.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryFutureAdapter.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryFutureAdapter.java
index 9e4e3d1..85f7326 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryFutureAdapter.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryFutureAdapter.java
@@ -39,21 +39,18 @@ import java.util.concurrent.atomic.*;
  */
 public abstract class GridCacheQueryFutureAdapter<K, V, R> extends GridFutureAdapter<Collection<R>>
     implements CacheQueryFuture<R>, GridTimeoutObject {
-    /** */
-    private static final long serialVersionUID = 0L;
-
     /** Logger reference. */
     private static final AtomicReference<IgniteLogger> logRef = new AtomicReference<>();
 
+    /** Logger. */
+    protected static IgniteLogger log;
+
     /** */
     private static final Object NULL = new Object();
 
     /** Cache context. */
     protected GridCacheContext<K, V> cctx;
 
-    /** Logger. */
-    protected IgniteLogger log;
-
     /** */
     protected final GridCacheQueryBean qry;
 
@@ -101,13 +98,12 @@ public abstract class GridCacheQueryFutureAdapter<K, V, R> extends GridFutureAda
      * @param loc Local query or not.
      */
     protected GridCacheQueryFutureAdapter(GridCacheContext<K, V> cctx, GridCacheQueryBean qry, boolean loc) {
-        super();
-
         this.cctx = cctx;
         this.qry = qry;
         this.loc = loc;
 
-        log = U.logger(cctx.kernalContext(), logRef, GridCacheQueryFutureAdapter.class);
+        if (log == null)
+            log = U.logger(cctx.kernalContext(), logRef, GridCacheQueryFutureAdapter.class);
 
         startTime = U.currentTimeMillis();
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxHandler.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxHandler.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxHandler.java
index 5115781..dd48ca2 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxHandler.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxHandler.java
@@ -458,7 +458,7 @@ public class IgniteTxHandler<K, V> {
             nearFinishFut = finishDhtLocal(nodeId, locTx, req);
 
         if (colocatedFinishFut != null && nearFinishFut != null) {
-            GridCompoundFuture<IgniteInternalTx, IgniteInternalTx> res = new GridCompoundFuture<>(ctx.kernalContext());
+            GridCompoundFuture<IgniteInternalTx, IgniteInternalTx> res = new GridCompoundFuture<>();
 
             res.add(colocatedFinishFut);
             res.add(nearFinishFut);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxManager.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxManager.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxManager.java
index af57ce4..a7de806 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxManager.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxManager.java
@@ -498,7 +498,7 @@ public class IgniteTxManager<K, V> extends GridCacheSharedManagerAdapter<K, V> {
      */
     public IgniteInternalFuture<Boolean> finishTxs(long topVer) {
         GridCompoundFuture<IgniteInternalTx, Boolean> res =
-            new GridCompoundFuture<>(context().kernalContext(),
+            new GridCompoundFuture<>(
                 new IgniteReducer<IgniteInternalTx, Boolean>() {
                     @Override public boolean collect(IgniteInternalTx e) {
                         return true;

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/processors/closure/GridClosureProcessor.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/closure/GridClosureProcessor.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/closure/GridClosureProcessor.java
index 28b07e5..c9d23c0 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/closure/GridClosureProcessor.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/closure/GridClosureProcessor.java
@@ -742,7 +742,7 @@ public class GridClosureProcessor extends GridProcessorAdapter {
 
             final ClassLoader ldr = Thread.currentThread().getContextClassLoader();
 
-            final GridWorkerFuture fut = new GridWorkerFuture(ctx);
+            final GridWorkerFuture fut = new GridWorkerFuture();
 
             workersCnt.increment();
 
@@ -879,7 +879,7 @@ public class GridClosureProcessor extends GridProcessorAdapter {
 
             final ClassLoader ldr = Thread.currentThread().getContextClassLoader();
 
-            final GridWorkerFuture<R> fut = new GridWorkerFuture<>(ctx);
+            final GridWorkerFuture<R> fut = new GridWorkerFuture<>();
 
             workersCnt.increment();
 
@@ -1653,7 +1653,7 @@ public class GridClosureProcessor extends GridProcessorAdapter {
          *
          */
         public C1MLA() {
-            super();
+            // No-op.
         }
 
         /**
@@ -1741,7 +1741,7 @@ public class GridClosureProcessor extends GridProcessorAdapter {
          *
          */
         public C2MLA() {
-            super();
+            // No-op.
         }
 
         /**
@@ -1824,7 +1824,7 @@ public class GridClosureProcessor extends GridProcessorAdapter {
          *
          */
         public C4MLA() {
-            super();
+            // No-op.
         }
 
         /**

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/processors/continuous/GridContinuousProcessor.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/continuous/GridContinuousProcessor.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/continuous/GridContinuousProcessor.java
index c09e51b..84b5e23 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/continuous/GridContinuousProcessor.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/continuous/GridContinuousProcessor.java
@@ -1698,9 +1698,6 @@ public class GridContinuousProcessor extends GridProcessorAdapter {
      * Future for stop routine.
      */
     private static class StopFuture extends GridFutureAdapter<Object> {
-        /** */
-        private static final long serialVersionUID = 0L;
-
         /** Timeout object. */
         private volatile GridTimeoutObject timeoutObj;
 
@@ -1711,7 +1708,6 @@ public class GridContinuousProcessor extends GridProcessorAdapter {
          * @param ctx Kernal context.
          */
         StopFuture(GridKernalContext ctx) {
-            super();
             this.ctx = ctx;
         }
 
@@ -1745,25 +1741,13 @@ public class GridContinuousProcessor extends GridProcessorAdapter {
      */
     private static class SyncMessageAckFuture extends GridFutureAdapter<Object> {
         /** */
-        private static final long serialVersionUID = 0L;
-
-        /** */
         private UUID nodeId;
 
         /**
-         * Required by {@link Externalizable}.
-         */
-        public SyncMessageAckFuture() {
-            // No-op.
-        }
-
-        /**
          * @param ctx Kernal context.
          * @param nodeId Master node ID.
          */
         SyncMessageAckFuture(GridKernalContext ctx, UUID nodeId) {
-            super();
-
             this.nodeId = nodeId;
         }
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/processors/dataload/GridDataLoaderFuture.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/dataload/GridDataLoaderFuture.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/dataload/GridDataLoaderFuture.java
index ae7052a..d4f57e3 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/dataload/GridDataLoaderFuture.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/dataload/GridDataLoaderFuture.java
@@ -23,33 +23,19 @@ import org.apache.ignite.internal.util.future.*;
 import org.apache.ignite.internal.util.tostring.*;
 import org.apache.ignite.internal.util.typedef.internal.*;
 
-import java.io.*;
-
 /**
  * Data loader future.
  */
 class GridDataLoaderFuture extends GridFutureAdapter<Object> {
-    /** */
-    private static final long serialVersionUID = 0L;
-
     /** Data loader. */
     @GridToStringExclude
     private IgniteDataLoaderImpl dataLdr;
 
     /**
-     * Default constructor for {@link Externalizable} support.
-     */
-    public GridDataLoaderFuture() {
-        // No-op.
-    }
-
-    /**
      * @param ctx Context.
      * @param dataLdr Data loader.
      */
     GridDataLoaderFuture(GridKernalContext ctx, IgniteDataLoaderImpl dataLdr) {
-        super();
-
         assert dataLdr != null;
 
         this.dataLdr = dataLdr;

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/processors/dataload/IgniteDataLoaderImpl.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/dataload/IgniteDataLoaderImpl.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/dataload/IgniteDataLoaderImpl.java
index 1e20486..81de12d 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/dataload/IgniteDataLoaderImpl.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/dataload/IgniteDataLoaderImpl.java
@@ -71,6 +71,9 @@ public class IgniteDataLoaderImpl<K, V> implements IgniteDataLoader<K, V>, Delay
     /** Log reference. */
     private static final AtomicReference<IgniteLogger> logRef = new AtomicReference<>();
 
+    /** Logger. */
+    private static IgniteLogger log;
+
     /** Cache name ({@code null} for default cache). */
     private final String cacheName;
 
@@ -97,9 +100,6 @@ public class IgniteDataLoaderImpl<K, V> implements IgniteDataLoader<K, V>, Delay
     @GridToStringInclude
     private ConcurrentMap<UUID, Buffer> bufMappings = new ConcurrentHashMap8<>();
 
-    /** Logger. */
-    private IgniteLogger log;
-
     /** Discovery listener. */
     private final GridLocalEventListener discoLsnr;
 
@@ -179,7 +179,8 @@ public class IgniteDataLoaderImpl<K, V> implements IgniteDataLoader<K, V>, Delay
         this.flushQ = flushQ;
         this.compact = compact;
 
-        log = U.logger(ctx, logRef, IgniteDataLoaderImpl.class);
+        if (log == null)
+            log = U.logger(ctx, logRef, IgniteDataLoaderImpl.class);
 
         ClusterNode node = F.first(ctx.grid().cluster().forCacheNodes(cacheName).nodes());
 
@@ -928,14 +929,14 @@ public class IgniteDataLoaderImpl<K, V> implements IgniteDataLoader<K, V>, Delay
 
             for (IgniteInternalFuture<Object> f : locFuts) {
                 if (res == null)
-                    res = new GridCompoundFuture<>(ctx);
+                    res = new GridCompoundFuture<>();
 
                 res.add(f);
             }
 
             for (IgniteInternalFuture<Object> f : reqs.values()) {
                 if (res == null)
-                    res = new GridCompoundFuture<>(ctx);
+                    res = new GridCompoundFuture<>();
 
                 res.add(f);
             }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/processors/igfs/IgfsDataManager.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/igfs/IgfsDataManager.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/igfs/IgfsDataManager.java
index ad044ae..f3b8773 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/igfs/IgfsDataManager.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/igfs/IgfsDataManager.java
@@ -491,7 +491,7 @@ public class IgfsDataManager extends IgfsManager {
      * @return Future that will be completed when all ack messages are received or when write failed.
      */
     public IgniteInternalFuture<Boolean> writeStart(IgfsFileInfo fileInfo) {
-        WriteCompletionFuture fut = new WriteCompletionFuture(igfsCtx.kernalContext(), fileInfo.id());
+        WriteCompletionFuture fut = new WriteCompletionFuture(fileInfo.id());
 
         WriteCompletionFuture oldFut = pendingWrites.putIfAbsent(fileInfo.id(), fut);
 
@@ -1772,9 +1772,6 @@ public class IgfsDataManager extends IgfsManager {
      * Future that is completed when all participating
      */
     private class WriteCompletionFuture extends GridFutureAdapter<Boolean> {
-        /** */
-        private static final long serialVersionUID = 0L;
-
         /** File id to remove future from map. */
         private IgniteUuid fileId;
 
@@ -1785,19 +1782,9 @@ public class IgfsDataManager extends IgfsManager {
         private volatile boolean awaitingLast;
 
         /**
-         * Empty constructor required by {@link Externalizable}.
-         */
-        public WriteCompletionFuture() {
-            // No-op.
-        }
-
-        /**
-         * @param ctx Kernal context.
          * @param fileId File id.
          */
-        private WriteCompletionFuture(GridKernalContext ctx, IgniteUuid fileId) {
-            super();
-
+        private WriteCompletionFuture(IgniteUuid fileId) {
             assert fileId != null;
 
             this.fileId = fileId;

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/processors/igfs/IgfsDeleteWorker.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/igfs/IgfsDeleteWorker.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/igfs/IgfsDeleteWorker.java
index dbe63a5..250b3a0 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/igfs/IgfsDeleteWorker.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/igfs/IgfsDeleteWorker.java
@@ -277,7 +277,7 @@ public class IgfsDeleteWorker extends IgfsThread {
                     }
                 }
 
-                GridCompoundFuture<Object, ?> fut = new GridCompoundFuture<>(igfsCtx.kernalContext());
+                GridCompoundFuture<Object, ?> fut = new GridCompoundFuture<>();
 
                 // Delegate to child folders.
                 for (IgfsListingEntry entry : delListing.values()) {

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/processors/igfs/IgfsImpl.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/igfs/IgfsImpl.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/igfs/IgfsImpl.java
index b87f6de..3c40cd1 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/igfs/IgfsImpl.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/igfs/IgfsImpl.java
@@ -1638,7 +1638,7 @@ public final class IgfsImpl implements IgfsEx {
             if (log.isDebugEnabled())
                 log.debug("Constructing delete future for trash entries: " + ids);
 
-            GridCompoundFuture<Object, Object> resFut = new GridCompoundFuture<>(igfsCtx.kernalContext());
+            GridCompoundFuture<Object, Object> resFut = new GridCompoundFuture<>();
 
             for (IgniteUuid id : ids) {
                 GridFutureAdapter<Object> fut = new GridFutureAdapter<>();

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/processors/query/GridQueryProcessor.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/query/GridQueryProcessor.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/query/GridQueryProcessor.java
index 92b39f1..0b29c33 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/query/GridQueryProcessor.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/query/GridQueryProcessor.java
@@ -236,7 +236,7 @@ public class GridQueryProcessor extends GridProcessorAdapter {
             throw new IllegalStateException("Failed to get space size (grid is stopping).");
 
         try {
-            GridCompoundFuture<?, ?> fut = new GridCompoundFuture<Object, Object>(ctx);
+            GridCompoundFuture<?, ?> fut = new GridCompoundFuture<Object, Object>();
 
             for (Map.Entry<TypeId, TypeDescriptor> e : types.entrySet())
                 fut.add((IgniteInternalFuture)rebuildIndexes(e.getKey().space, e.getValue()));

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/GridRestProcessor.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/GridRestProcessor.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/GridRestProcessor.java
index 6c1cedb..bb34e94 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/GridRestProcessor.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/GridRestProcessor.java
@@ -94,7 +94,7 @@ public class GridRestProcessor extends GridProcessorAdapter {
                 new IgniteCheckedException("Failed to handle request (received request while stopping grid)."));
 
         try {
-            final GridWorkerFuture<GridRestResponse> fut = new GridWorkerFuture<>(ctx);
+            final GridWorkerFuture<GridRestResponse> fut = new GridWorkerFuture<>();
 
             workersCnt.increment();
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/processors/service/GridServiceDeploymentFuture.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/service/GridServiceDeploymentFuture.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/service/GridServiceDeploymentFuture.java
index f05fdf6..7e374b6 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/service/GridServiceDeploymentFuture.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/service/GridServiceDeploymentFuture.java
@@ -17,7 +17,6 @@
 
 package org.apache.ignite.internal.processors.service;
 
-import org.apache.ignite.internal.*;
 import org.apache.ignite.internal.util.future.*;
 import org.apache.ignite.internal.util.typedef.internal.*;
 import org.apache.ignite.services.*;
@@ -27,18 +26,12 @@ import org.apache.ignite.services.*;
  */
 public class GridServiceDeploymentFuture extends GridFutureAdapter<Object> {
     /** */
-    private static final long serialVersionUID = 0L;
-
-    /** */
     private final ServiceConfiguration cfg;
 
     /**
-     * @param ctx Context.
      * @param cfg Configuration.
      */
-    public GridServiceDeploymentFuture(GridKernalContext ctx, ServiceConfiguration cfg) {
-        super();
-
+    public GridServiceDeploymentFuture(ServiceConfiguration cfg) {
         this.cfg = cfg;
     }
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/processors/service/GridServiceProcessor.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/service/GridServiceProcessor.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/service/GridServiceProcessor.java
index aac9d90..7e0f41e 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/service/GridServiceProcessor.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/service/GridServiceProcessor.java
@@ -309,7 +309,7 @@ public class GridServiceProcessor extends GridProcessorAdapter {
 
         validate(cfg);
 
-        GridServiceDeploymentFuture fut = new GridServiceDeploymentFuture(ctx, cfg);
+        GridServiceDeploymentFuture fut = new GridServiceDeploymentFuture(cfg);
 
         GridServiceDeploymentFuture old = depFuts.putIfAbsent(cfg.getName(), fut);
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/processors/streamer/GridStreamerStageExecutionFuture.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/streamer/GridStreamerStageExecutionFuture.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/streamer/GridStreamerStageExecutionFuture.java
index beb2820..1b3269a 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/streamer/GridStreamerStageExecutionFuture.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/streamer/GridStreamerStageExecutionFuture.java
@@ -29,7 +29,6 @@ import org.apache.ignite.lang.*;
 import org.apache.ignite.streamer.*;
 import org.jetbrains.annotations.*;
 
-import java.io.*;
 import java.util.*;
 import java.util.concurrent.*;
 
@@ -79,25 +78,10 @@ public class GridStreamerStageExecutionFuture extends GridFutureAdapter<Object>
     private StreamerMetricsHolder metricsHolder;
 
     /**
-     * Empty constructor required by {@link Externalizable}.
-     */
-    public GridStreamerStageExecutionFuture() {
-        assert false : "Streamer execution future should never be serialized.";
-
-        execId = null;
-        execStartTs = 0;
-        futId = null;
-        stageName = null;
-        evts = null;
-        streamer = null;
-        parentFutId = null;
-    }
-
-    /**
     * @param streamer Streamer extended context.
     * @param execId Execution ID. If parent future ID is {@code null} then this is a root future
-    * and execution ID must be {@code null}.
-     * @param failoverAttemptCnt Number of attempts this set of events was tried to failover.
+    *       and execution ID must be {@code null}.
+    * @param failoverAttemptCnt Number of attempts this set of events was tried to failover.
     * @param execStartTs Execution start timestamp.
     * @param parentFutId Parent future ID.
     * @param prevExecNodes Node IDs on which pipeline was already executed.

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/processors/streamer/IgniteStreamerImpl.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/streamer/IgniteStreamerImpl.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/streamer/IgniteStreamerImpl.java
index 10fd3d8..1a11123 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/streamer/IgniteStreamerImpl.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/streamer/IgniteStreamerImpl.java
@@ -1221,7 +1221,7 @@ public class IgniteStreamerImpl implements IgniteStreamerEx, Externalizable {
         private long schedTs;
 
         /** Stage completion future. */
-        private BatchExecutionFuture fut = new BatchExecutionFuture(ctx);
+        private BatchExecutionFuture fut = new BatchExecutionFuture();
 
         /**
          * Creates worker.
@@ -1351,20 +1351,6 @@ public class IgniteStreamerImpl implements IgniteStreamerEx, Externalizable {
         /** */
         private BatchWorker w;
 
-        /**
-         * Empty constructor required for {@link Externalizable}.
-         */
-        public BatchExecutionFuture() {
-            // No-op.
-        }
-
-        /**
-         * @param ctx Context.
-         */
-        private BatchExecutionFuture(GridKernalContext ctx) {
-            super(ctx);
-        }
-
         /** {@inheritDoc} */
         @Override public boolean cancel() throws IgniteCheckedException {
             assert w != null;

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/util/GridSerializableFuture.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/util/GridSerializableFuture.java b/modules/core/src/main/java/org/apache/ignite/internal/util/GridSerializableFuture.java
deleted file mode 100644
index 167cefd..0000000
--- a/modules/core/src/main/java/org/apache/ignite/internal/util/GridSerializableFuture.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.ignite.internal.util;
-
-import java.io.*;
-import java.util.concurrent.*;
-
-/**
- * Adds serialization to the {@link Future} interface.
- */
-public interface GridSerializableFuture<T> extends Future<T>, Serializable {
-    // No-op.
-}

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/util/future/GridCompoundFuture.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/util/future/GridCompoundFuture.java b/modules/core/src/main/java/org/apache/ignite/internal/util/future/GridCompoundFuture.java
index 7139564..0785aba 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/util/future/GridCompoundFuture.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/util/future/GridCompoundFuture.java
@@ -28,7 +28,6 @@ import org.apache.ignite.lang.*;
 import org.jdk8.backport.*;
 import org.jetbrains.annotations.*;
 
-import java.io.*;
 import java.util.*;
 import java.util.concurrent.atomic.*;
 
@@ -36,9 +35,6 @@ import java.util.concurrent.atomic.*;
  * Future composed of multiple inner futures.
  */
 public class GridCompoundFuture<T, R> extends GridFutureAdapter<R> {
-    /** */
-    private static final long serialVersionUID = 0L;
-
     /** Futures. */
     private final ConcurrentLinkedDeque8<IgniteInternalFuture<T>> futs = new ConcurrentLinkedDeque8<>();
 
@@ -68,26 +64,16 @@ public class GridCompoundFuture<T, R> extends GridFutureAdapter<R> {
     private AtomicReference<Throwable> err = new AtomicReference<>();
 
     /**
-     * Empty constructor required for {@link Externalizable}.
+     *
      */
     public GridCompoundFuture() {
         // No-op.
     }
 
     /**
-     * @param ctx Context.
-     */
-    public GridCompoundFuture(GridKernalContext ctx) {
-        super();
-    }
-
-    /**
-     * @param ctx Context.
      * @param rdc Reducer.
      */
-    public GridCompoundFuture(GridKernalContext ctx, @Nullable IgniteReducer<T, R> rdc) {
-        super();
-
+    public GridCompoundFuture(@Nullable IgniteReducer<T, R> rdc) {
         this.rdc = rdc;
     }
 
@@ -98,8 +84,6 @@ public class GridCompoundFuture<T, R> extends GridFutureAdapter<R> {
      */
     public GridCompoundFuture(GridKernalContext ctx, @Nullable IgniteReducer<T, R> rdc,
         @Nullable Iterable<IgniteInternalFuture<T>> futs) {
-        super();
-
         this.rdc = rdc;
 
         addAll(futs);
@@ -335,26 +319,17 @@ public class GridCompoundFuture<T, R> extends GridFutureAdapter<R> {
                 }
             }
             catch (IgniteTxOptimisticCheckedException e) {
-//                if (log.isDebugEnabled())
-//                    log.debug("Optimistic failure [fut=" + GridCompoundFuture.this + ", err=" + e + ']');
-
                 err.compareAndSet(null, e);
             }
             catch (ClusterTopologyCheckedException e) {
-//                if (log.isDebugEnabled())
-//                    log.debug("Topology exception [fut=" + GridCompoundFuture.this + ", err=" + e + ']');
-
                 err.compareAndSet(null, e);
             }
             catch (IgniteFutureCancelledCheckedException e) {
-//                if (log.isDebugEnabled())
-//                    log.debug("Failed to execute compound future reducer [lsnr=" + this + ", e=" + e + ']');
-
                 err.compareAndSet(null, e);
             }
             catch (IgniteCheckedException e) {
-//                if (!ignoreFailure(e))
-//                    U.error(log, "Failed to execute compound future reducer: " + this, e);
+                if (!ignoreFailure(e))
+                    U.error(null, "Failed to execute compound future reducer: " + this, e);
 
                 err.compareAndSet(null, e);
             }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/util/future/GridCompoundIdentityFuture.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/util/future/GridCompoundIdentityFuture.java b/modules/core/src/main/java/org/apache/ignite/internal/util/future/GridCompoundIdentityFuture.java
index 89d6920..e317905 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/util/future/GridCompoundIdentityFuture.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/util/future/GridCompoundIdentityFuture.java
@@ -22,25 +22,15 @@ import org.apache.ignite.internal.util.typedef.internal.*;
 import org.apache.ignite.lang.*;
 import org.jetbrains.annotations.*;
 
-import java.io.*;
-
 /**
  * Future composed of multiple inner futures.
  */
 public class GridCompoundIdentityFuture<T> extends GridCompoundFuture<T, T> {
-    /** */
-    private static final long serialVersionUID = 0L;
-
-    /** Empty constructor required for {@link Externalizable}. */
-    public GridCompoundIdentityFuture() {
-        // No-op.
-    }
-
     /**
-     * @param ctx Context.
+     *
      */
-    public GridCompoundIdentityFuture(GridKernalContext ctx) {
-        super(ctx);
+    public GridCompoundIdentityFuture() {
+        // No-op.
     }
 
     /**
@@ -48,7 +38,7 @@ public class GridCompoundIdentityFuture<T> extends GridCompoundFuture<T, T> {
      * @param rdc Reducer.
      */
     public GridCompoundIdentityFuture(GridKernalContext ctx, @Nullable IgniteReducer<T, T> rdc) {
-        super(ctx, rdc);
+        super(rdc);
     }
 
     /** {@inheritDoc} */

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/util/future/GridEmbeddedFuture.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/util/future/GridEmbeddedFuture.java b/modules/core/src/main/java/org/apache/ignite/internal/util/future/GridEmbeddedFuture.java
index b3ec22d..d982b78 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/util/future/GridEmbeddedFuture.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/util/future/GridEmbeddedFuture.java
@@ -23,8 +23,6 @@ import org.apache.ignite.internal.util.lang.*;
 import org.apache.ignite.internal.util.typedef.internal.*;
 import org.apache.ignite.lang.*;
 
-import java.io.*;
-
 /**
  * Future which waits for embedded future to complete and then asynchronously executes
  * provided closure with embedded future result.
@@ -38,13 +36,6 @@ public class GridEmbeddedFuture<A, B> extends GridFutureAdapter<A> {
     private IgniteInternalFuture<B> embedded;
 
     /**
-     * Empty constructor required by {@link Externalizable}.
-     */
-    public GridEmbeddedFuture() {
-        // No-op.
-    }
-
-    /**
      * @param embedded Embedded future.
      * @param c Closure to execute upon completion of embedded future.
      */
@@ -82,7 +73,9 @@ public class GridEmbeddedFuture<A, B> extends GridFutureAdapter<A> {
      * @param c Closure which runs upon completion of embedded closure and which returns another future.
      */
     public GridEmbeddedFuture(
-        IgniteInternalFuture<B> embedded, final IgniteBiClosure<B, Exception, IgniteInternalFuture<A>> c) {
+        IgniteInternalFuture<B> embedded,
+        final IgniteBiClosure<B, Exception, IgniteInternalFuture<A>> c
+    ) {
         assert embedded != null;
         assert c != null;
 
@@ -145,8 +138,8 @@ public class GridEmbeddedFuture<A, B> extends GridFutureAdapter<A> {
      * @param c2 Closure will runs upon completion of future returned by {@code c1} closure.
      */
     public GridEmbeddedFuture(
-        IgniteInternalFuture<B> embedded, final IgniteBiClosure<B, Exception,
-        IgniteInternalFuture<A>> c1,
+        IgniteInternalFuture<B> embedded,
+        final IgniteBiClosure<B, Exception, IgniteInternalFuture<A>> c1,
         final IgniteBiClosure<A, Exception, A> c2
     ) {
         assert embedded != null;

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/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 21ad1ab..30aa855 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
@@ -86,14 +86,14 @@ public class GridFutureAdapter<R> extends AbstractQueuedSynchronizer implements
      * @return Value of error.
      */
     protected Throwable error() {
-        return (resFlag == RES) ? null : (Throwable)res;
+        return (resFlag == ERR) ? (Throwable)res : null;
     }
 
     /**
      * @return Value of result.
      */
     protected R result() {
-        return (R)res;
+        return resFlag == RES ? (R)res : null;
     }
 
     /** {@inheritDoc} */
@@ -105,7 +105,9 @@ public class GridFutureAdapter<R> extends AbstractQueuedSynchronizer implements
             if (getState() == CANCELLED)
                 throw new IgniteFutureCancelledCheckedException("Future was cancelled: " + this);
 
-            if (resFlag != ERR)
+            assert resFlag != 0;
+
+            if (resFlag == ERR)
                 throw U.cast((Throwable)res);
 
             return (R)res;
@@ -152,7 +154,9 @@ public class GridFutureAdapter<R> extends AbstractQueuedSynchronizer implements
         if (getState() == CANCELLED)
             throw new IgniteFutureCancelledCheckedException("Future was cancelled: " + this);
 
-        if (resFlag != ERR)
+        assert resFlag != 0;
+
+        if (resFlag == ERR)
             throw U.cast((Throwable)res);
 
         return (R)res;
@@ -204,7 +208,7 @@ public class GridFutureAdapter<R> extends AbstractQueuedSynchronizer implements
             lsnr = null;
         }
 
-        assert lsnrs0 == null;
+        assert lsnrs0 != null;
 
         notifyListener(lsnrs0);
     }
@@ -416,9 +420,6 @@ public class GridFutureAdapter<R> extends AbstractQueuedSynchronizer implements
      */
     private static class ChainFuture<R, T> extends GridFutureAdapter<T> {
         /** */
-        private static final long serialVersionUID = 0L;
-
-        /** */
         private GridFutureAdapter<R> fut;
 
         /** */
@@ -439,8 +440,6 @@ public class GridFutureAdapter<R> extends AbstractQueuedSynchronizer implements
             GridFutureAdapter<R> fut,
             IgniteClosure<? super IgniteInternalFuture<R>, T> doneCb
         ) {
-            super();
-
             this.fut = fut;
             this.doneCb = doneCb;
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/util/io/GridFilenameUtils.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/util/io/GridFilenameUtils.java b/modules/core/src/main/java/org/apache/ignite/internal/util/io/GridFilenameUtils.java
index 9459c3c..ba793ac 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/util/io/GridFilenameUtils.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/util/io/GridFilenameUtils.java
@@ -122,7 +122,7 @@ public class GridFilenameUtils {
      * Instances should NOT be constructed in standard programming.
      */
     private GridFilenameUtils() {
-        super();
+        // No-op.
     }
 
     //-----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/util/lang/GridFunc.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/util/lang/GridFunc.java b/modules/core/src/main/java/org/apache/ignite/internal/util/lang/GridFunc.java
index 9ab10cf..5b86fc1 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/util/lang/GridFunc.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/util/lang/GridFunc.java
@@ -2709,88 +2709,6 @@ public class GridFunc {
     }
 
     /**
-     * Converts given object with interface {@link org.apache.ignite.internal.IgniteInternalFuture} into an object implementing {@link Future}.
-     *
-     * @param fut Future to convert.
-     * @param <T> Type of computation result.
-     * @return Instance implementing {@link Future}.
-     */
-    public static <T> Future<T> as(final IgniteInternalFuture<T> fut) {
-        A.notNull(fut, "fut");
-
-        return new GridSerializableFuture<T>() {
-            @Override public boolean cancel(boolean mayInterruptIfRunning) {
-                if (mayInterruptIfRunning) {
-                    try {
-                        return fut.cancel();
-                    }
-                    catch (IgniteCheckedException e) {
-                        throw new IgniteException(e);
-                    }
-                }
-                else
-                    return false;
-            }
-
-            @Override public boolean isCancelled() {
-                return fut.isCancelled();
-            }
-
-            @Override public boolean isDone() {
-                return fut.isDone();
-            }
-
-            @Override public T get() throws InterruptedException, ExecutionException {
-                try {
-                    return fut.get();
-                }
-                catch (IgniteFutureCancelledCheckedException ignore) {
-                    throw new CancellationException("The computation was cancelled.");
-                }
-                catch (IgniteInterruptedCheckedException ignore) {
-                    throw new InterruptedException("The computation was interrupted.");
-                }
-                catch (IgniteCheckedException e) {
-                    throw new ExecutionException("The computation failed.", e);
-                }
-            }
-
-            @Override public T get(long timeout, @NotNull TimeUnit unit) throws InterruptedException, ExecutionException,
-                TimeoutException {
-                try {
-                    return fut.get(timeout, unit);
-                }
-                catch (IgniteFutureCancelledCheckedException ignore) {
-                    throw new CancellationException("The computation was cancelled.");
-                }
-                catch (IgniteInterruptedCheckedException ignore) {
-                    throw new InterruptedException("The computation was interrupted.");
-                }
-                catch (IgniteFutureTimeoutCheckedException e) {
-                    throw new TimeoutException("The computation timed out: " + e.getMessage());
-                }
-                catch (IgniteCheckedException e) {
-                    throw new ExecutionException("The computation failed.", e);
-                }
-            }
-        };
-    }
-
-    /**
-     * Gets closure that converts {@link org.apache.ignite.internal.IgniteInternalFuture} to {@link Future}.
-     *
-     * @param <T> Type of future.
-     * @return Closure that converts {@link org.apache.ignite.internal.IgniteInternalFuture} to {@link Future}.
-     */
-    public static <T> IgniteClosure<IgniteInternalFuture<T>, Future<T>> future() {
-        return new C1<IgniteInternalFuture<T>, Future<T>>() {
-            @Override public Future<T> apply(IgniteInternalFuture<T> fut) {
-                return as(fut);
-            }
-        };
-    }
-
-    /**
      * Curries given closure.
      *
      * @param f Closure.

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/main/java/org/apache/ignite/internal/util/worker/GridWorkerFuture.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/util/worker/GridWorkerFuture.java b/modules/core/src/main/java/org/apache/ignite/internal/util/worker/GridWorkerFuture.java
index 672fe5e..e1d156a 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/util/worker/GridWorkerFuture.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/util/worker/GridWorkerFuture.java
@@ -18,11 +18,8 @@
 package org.apache.ignite.internal.util.worker;
 
 import org.apache.ignite.*;
-import org.apache.ignite.internal.*;
 import org.apache.ignite.internal.util.future.*;
 
-import java.io.*;
-
 /**
  * Future for locally executed closure that defines cancellation logic.
  */
@@ -33,20 +30,6 @@ public class GridWorkerFuture<T> extends GridFutureAdapter<T> {
     /** */
     private GridWorker w;
 
-    /**
-     * @param ctx Context.
-     */
-    public GridWorkerFuture(GridKernalContext ctx) {
-        super();
-    }
-
-    /**
-     * Empty constructor required for {@link Externalizable}.
-     */
-    public GridWorkerFuture() {
-        // No-op.
-    }
-
     /** {@inheritDoc} */
     @Override public boolean cancel() throws IgniteCheckedException {
         assert w != null;

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheAtomicUsersAffinityMapperSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheAtomicUsersAffinityMapperSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheAtomicUsersAffinityMapperSelfTest.java
index 8a80e35..577030f 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheAtomicUsersAffinityMapperSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheAtomicUsersAffinityMapperSelfTest.java
@@ -23,15 +23,10 @@ import org.apache.ignite.cache.*;
  * Test affinity mapper.
  */
 public class GridCacheAtomicUsersAffinityMapperSelfTest extends GridCacheAbstractUsersAffinityMapperSelfTest {
-    /** */
-    public GridCacheAtomicUsersAffinityMapperSelfTest() {
-        super();
-    }
-
     /** {@inheritDoc} */
     @Override protected CacheDistributionMode getDistributionMode() {
         return CacheDistributionMode.PARTITIONED_ONLY;
-    };
+    }
 
     /** {@inheritDoc} */
     @Override protected CacheAtomicityMode getAtomicMode() {

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCachePartitionedLocalStoreSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCachePartitionedLocalStoreSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCachePartitionedLocalStoreSelfTest.java
index 4217531..5e70745 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCachePartitionedLocalStoreSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCachePartitionedLocalStoreSelfTest.java
@@ -27,13 +27,6 @@ import static org.apache.ignite.cache.CacheMode.*;
  *
  */
 public class GridCachePartitionedLocalStoreSelfTest extends GridCacheAbstractLocalStoreSelfTest {
-    /**
-     *
-     */
-    public GridCachePartitionedLocalStoreSelfTest() {
-        super();
-    }
-
     /** {@inheritDoc} */
     @Override protected CacheDistributionMode getDistributionMode() {
         return PARTITIONED_ONLY;

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCachePartitionedOffHeapLocalStoreSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCachePartitionedOffHeapLocalStoreSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCachePartitionedOffHeapLocalStoreSelfTest.java
index e61b4f8..9f26371 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCachePartitionedOffHeapLocalStoreSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCachePartitionedOffHeapLocalStoreSelfTest.java
@@ -27,13 +27,6 @@ import static org.apache.ignite.cache.CacheMode.*;
  *
  */
 public class GridCachePartitionedOffHeapLocalStoreSelfTest extends GridCacheAbstractLocalStoreSelfTest {
-    /**
-     *
-     */
-    public GridCachePartitionedOffHeapLocalStoreSelfTest() {
-        super();
-    }
-
     /** {@inheritDoc} */
     @Override protected CacheDistributionMode getDistributionMode() {
         return PARTITIONED_ONLY;

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheReplicatedLocalStoreSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheReplicatedLocalStoreSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheReplicatedLocalStoreSelfTest.java
index 56f3f1a..f8fb5c5 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheReplicatedLocalStoreSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheReplicatedLocalStoreSelfTest.java
@@ -27,13 +27,6 @@ import static org.apache.ignite.cache.CacheMode.*;
  *
  */
 public class GridCacheReplicatedLocalStoreSelfTest extends GridCacheAbstractLocalStoreSelfTest {
-    /**
-     *
-     */
-    public GridCacheReplicatedLocalStoreSelfTest() {
-        super();
-    }
-
     /** {@inheritDoc} */
     @Override protected CacheDistributionMode getDistributionMode() {
         return PARTITIONED_ONLY;

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheReplicatedUsersAffinityMapperSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheReplicatedUsersAffinityMapperSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheReplicatedUsersAffinityMapperSelfTest.java
index 47e5dc7..a33c978 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheReplicatedUsersAffinityMapperSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheReplicatedUsersAffinityMapperSelfTest.java
@@ -23,15 +23,10 @@ import org.apache.ignite.cache.*;
  * Test affinity mapper.
  */
 public class GridCacheReplicatedUsersAffinityMapperSelfTest extends GridCacheAbstractUsersAffinityMapperSelfTest {
-    /** */
-    public GridCacheReplicatedUsersAffinityMapperSelfTest() {
-        super();
-    }
-
     /** {@inheritDoc} */
     @Override protected CacheDistributionMode getDistributionMode() {
         return CacheDistributionMode.PARTITIONED_ONLY;
-    };
+    }
 
     /** {@inheritDoc} */
     @Override protected CacheAtomicityMode getAtomicMode() {

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheTxPartitionedLocalStoreSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheTxPartitionedLocalStoreSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheTxPartitionedLocalStoreSelfTest.java
index 113bac3..589e1f0 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheTxPartitionedLocalStoreSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheTxPartitionedLocalStoreSelfTest.java
@@ -27,13 +27,6 @@ import static org.apache.ignite.cache.CacheMode.*;
  *
  */
 public class GridCacheTxPartitionedLocalStoreSelfTest extends GridCacheAbstractLocalStoreSelfTest {
-    /**
-     *
-     */
-    public GridCacheTxPartitionedLocalStoreSelfTest() {
-        super();
-    }
-
     /** {@inheritDoc} */
     @Override protected CacheDistributionMode getDistributionMode() {
         return PARTITIONED_ONLY;

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheTxUsersAffinityMapperSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheTxUsersAffinityMapperSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheTxUsersAffinityMapperSelfTest.java
index 61af04e..952312a 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheTxUsersAffinityMapperSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheTxUsersAffinityMapperSelfTest.java
@@ -23,15 +23,10 @@ import org.apache.ignite.cache.*;
  * Test affinity mapper.
  */
 public class GridCacheTxUsersAffinityMapperSelfTest extends GridCacheAbstractUsersAffinityMapperSelfTest {
-    /** */
-    public GridCacheTxUsersAffinityMapperSelfTest() {
-        super();
-    }
-
     /** {@inheritDoc} */
     @Override protected CacheDistributionMode getDistributionMode() {
         return CacheDistributionMode.PARTITIONED_ONLY;
-    };
+    }
 
     /** {@inheritDoc} */
     @Override protected CacheAtomicityMode getAtomicMode() {

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheEventAbstractTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheEventAbstractTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheEventAbstractTest.java
index 7cad61a..5806eeb 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheEventAbstractTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheEventAbstractTest.java
@@ -31,7 +31,6 @@ import org.apache.ignite.lang.*;
 import org.apache.ignite.transactions.*;
 
 import javax.cache.*;
-import java.io.*;
 import java.util.*;
 import java.util.concurrent.*;
 import java.util.concurrent.atomic.*;
@@ -832,7 +831,7 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe
                 return;
 
             // Create future that aggregates all required event types.
-            GridCompoundIdentityFuture<Object> cf = new GridCompoundIdentityFuture<>(ctx);
+            GridCompoundIdentityFuture<Object> cf = new GridCompoundIdentityFuture<>();
 
             for (IgniteBiTuple<Integer, Integer> t : evtCnts) {
                 Integer evtType = t.get1();
@@ -840,7 +839,7 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe
 
                 assert expCnt != null && expCnt > 0;
 
-                EventTypeFuture fut = new EventTypeFuture(ctx, evtType, expCnt, partitioned);
+                EventTypeFuture fut = new EventTypeFuture(evtType, expCnt, partitioned);
 
                 futs.add(fut);
 
@@ -881,21 +880,11 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe
         private boolean partitioned;
 
         /**
-         * For {@link Externalizable}.
-         */
-        public EventTypeFuture() {
-            // No-op.
-        }
-
-        /**
-         * @param ctx Kernal context.
          * @param evtType Event type.
          * @param expCnt Expected count.
          * @param partitioned Partitioned flag.
          */
-        EventTypeFuture(GridKernalContext ctx, int evtType, int expCnt, boolean partitioned) {
-            super();
-
+        EventTypeFuture(int evtType, int expCnt, boolean partitioned) {
             assert expCnt > 0;
 
             this.evtType = evtType;

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/test/java/org/apache/ignite/internal/util/future/GridCompoundFutureSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/util/future/GridCompoundFutureSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/util/future/GridCompoundFutureSelfTest.java
index 837d33d..6cf229f 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/util/future/GridCompoundFutureSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/util/future/GridCompoundFutureSelfTest.java
@@ -54,9 +54,7 @@ public class GridCompoundFutureSelfTest extends GridCommonAbstractTest {
      * @throws Exception If failed.
      */
     public void testCompleteOnReducer() throws Exception {
-        GridTestKernalContext ctx = new GridTestKernalContext(log);
-
-        GridCompoundFuture<Boolean, Boolean> fut = new GridCompoundFuture<>(ctx, CU.boolReducer());
+        GridCompoundFuture<Boolean, Boolean> fut = new GridCompoundFuture<>(CU.boolReducer());
 
         List<GridFutureAdapter<Boolean>> futs = new ArrayList<>(5);
 
@@ -88,9 +86,7 @@ public class GridCompoundFutureSelfTest extends GridCommonAbstractTest {
      * @throws Exception If failed.
      */
     public void testCompleteOnException() throws Exception {
-        GridTestKernalContext ctx = new GridTestKernalContext(log);
-
-        GridCompoundFuture<Boolean, Boolean> fut = new GridCompoundFuture<>(ctx, CU.boolReducer());
+        GridCompoundFuture<Boolean, Boolean> fut = new GridCompoundFuture<>(CU.boolReducer());
 
         List<GridFutureAdapter<Boolean>> futs = new ArrayList<>(5);
 
@@ -122,9 +118,7 @@ public class GridCompoundFutureSelfTest extends GridCommonAbstractTest {
      * @throws Exception If failed.
      */
     public void testConcurrentCompletion() throws Exception {
-        GridTestKernalContext ctx = new GridTestKernalContext(log);
-
-        GridCompoundFuture<Boolean, Boolean> fut = new GridCompoundFuture<>(ctx, CU.boolReducer());
+        GridCompoundFuture<Boolean, Boolean> fut = new GridCompoundFuture<>(CU.boolReducer());
 
         final ConcurrentLinkedDeque8<GridFutureAdapter<Boolean>> futs =
             new ConcurrentLinkedDeque8<>();
@@ -157,9 +151,7 @@ public class GridCompoundFutureSelfTest extends GridCommonAbstractTest {
      * @throws Exception If failed.
      */
     public void testConcurrentRandomCompletion() throws Exception {
-        GridTestKernalContext ctx = new GridTestKernalContext(log);
-
-        GridCompoundFuture<Boolean, Boolean> fut = new GridCompoundFuture<>(ctx, CU.boolReducer());
+        GridCompoundFuture<Boolean, Boolean> fut = new GridCompoundFuture<>(CU.boolReducer());
 
         final ConcurrentLinkedDeque8<GridFutureAdapter<Boolean>> futs =
             new ConcurrentLinkedDeque8<>();

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/core/src/test/java/org/apache/ignite/internal/util/future/GridFutureAdapterSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/util/future/GridFutureAdapterSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/util/future/GridFutureAdapterSelfTest.java
index 6ef5549..0ed370c 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/util/future/GridFutureAdapterSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/util/future/GridFutureAdapterSelfTest.java
@@ -21,13 +21,11 @@ import org.apache.ignite.*;
 import org.apache.ignite.internal.*;
 import org.apache.ignite.internal.cluster.*;
 import org.apache.ignite.internal.processors.closure.*;
-import org.apache.ignite.internal.util.io.*;
 import org.apache.ignite.internal.util.typedef.*;
 import org.apache.ignite.testframework.*;
 import org.apache.ignite.testframework.junits.*;
 import org.apache.ignite.testframework.junits.common.*;
 
-import java.io.*;
 import java.util.concurrent.*;
 import java.util.concurrent.atomic.*;
 
@@ -364,78 +362,4 @@ public class GridFutureAdapterSelfTest extends GridCommonAbstractTest {
         }
 
     }
-
-    /**
-     * @throws Exception If failed.
-     */
-    public void testSerialization() throws Exception {
-        GridFutureAdapter<Object> unfinished = new GridFutureAdapter<>();
-        GridFutureAdapter<Object> finished = new GridFutureAdapter<>();
-        GridFutureAdapter<Object> cancelled = new GridFutureAdapter<>();
-
-        finished.onDone("Finished");
-
-        cancelled.onCancelled();
-
-        GridByteArrayOutputStream baos = new GridByteArrayOutputStream();
-
-        ObjectOutputStream out = new ObjectOutputStream(baos);
-
-        out.writeObject(unfinished);
-        out.writeObject(finished);
-        out.writeObject(cancelled);
-
-        out.close();
-
-        ObjectInputStream in = new ObjectInputStream(new GridByteArrayInputStream(baos.internalArray(),
-            0, baos.size()));
-
-        unfinished = (GridFutureAdapter<Object>)in.readObject();
-        finished = (GridFutureAdapter<Object>)in.readObject();
-        cancelled = (GridFutureAdapter<Object>)in.readObject();
-
-        try {
-            unfinished.get();
-
-            assert false;
-        }
-        catch (IllegalStateException e) {
-            info("Caught expected exception: " + e);
-        }
-
-        try {
-            unfinished.get(1000);
-
-            assert false;
-        }
-        catch (IllegalStateException e) {
-            info("Caught expected exception: " + e);
-        }
-
-        Object o = finished.get();
-
-        assertEquals("Finished", o);
-
-        o = finished.get(1000);
-
-        assertEquals("Finished", o);
-
-        try {
-            cancelled.get();
-
-            assert false;
-        }
-        catch (IgniteFutureCancelledCheckedException e) {
-            info("Caught expected exception: " + e);
-        }
-
-        try {
-            cancelled.get(1000);
-
-            assert false;
-        }
-        catch (IgniteFutureCancelledCheckedException e) {
-            info("Caught expected exception: " + e);
-        }
-    }
 }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/jta/src/main/java/org/apache/ignite/internal/processors/cache/jta/GridCacheXAResource.java
----------------------------------------------------------------------
diff --git a/modules/jta/src/main/java/org/apache/ignite/internal/processors/cache/jta/GridCacheXAResource.java b/modules/jta/src/main/java/org/apache/ignite/internal/processors/cache/jta/GridCacheXAResource.java
index 690b251..505f558 100644
--- a/modules/jta/src/main/java/org/apache/ignite/internal/processors/cache/jta/GridCacheXAResource.java
+++ b/modules/jta/src/main/java/org/apache/ignite/internal/processors/cache/jta/GridCacheXAResource.java
@@ -36,6 +36,9 @@ public final class GridCacheXAResource implements XAResource {
     private static final AtomicReference<IgniteLogger> logRef = new AtomicReference<>();
 
     /** */
+    private static IgniteLogger log;
+
+    /** */
     private static final Xid[] NO_XID = new Xid[] {};
 
     /** Context. */
@@ -45,9 +48,6 @@ public final class GridCacheXAResource implements XAResource {
     private IgniteInternalTx cacheTx;
 
     /** */
-    private IgniteLogger log;
-
-    /** */
     private Xid xid;
 
     /**
@@ -61,7 +61,8 @@ public final class GridCacheXAResource implements XAResource {
         this.cctx = cctx;
         this.cacheTx = cacheTx;
 
-        log = U.logger(cctx.kernalContext(), logRef, GridCacheXAResource.class);
+        if (log == null)
+            log = U.logger(cctx.kernalContext(), logRef, GridCacheXAResource.class);
     }
 
     /** {@inheritDoc} */

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65e6ad60/modules/schedule/src/main/java/org/apache/ignite/internal/processors/schedule/ScheduleFutureImpl.java
----------------------------------------------------------------------
diff --git a/modules/schedule/src/main/java/org/apache/ignite/internal/processors/schedule/ScheduleFutureImpl.java b/modules/schedule/src/main/java/org/apache/ignite/internal/processors/schedule/ScheduleFutureImpl.java
index b677770..5f21297 100644
--- a/modules/schedule/src/main/java/org/apache/ignite/internal/processors/schedule/ScheduleFutureImpl.java
+++ b/modules/schedule/src/main/java/org/apache/ignite/internal/processors/schedule/ScheduleFutureImpl.java
@@ -30,7 +30,6 @@ import org.apache.ignite.lang.*;
 import org.apache.ignite.scheduler.*;
 import org.jetbrains.annotations.*;
 
-import java.io.*;
 import java.util.*;
 import java.util.concurrent.*;
 import java.util.concurrent.atomic.*;
@@ -168,13 +167,6 @@ class ScheduleFutureImpl<R> implements SchedulerFuture<R> {
     };
 
     /**
-     * Empty constructor required by {@link Externalizable}.
-     */
-    public ScheduleFutureImpl() {
-        // No-op.
-    }
-
-    /**
      * Creates descriptor for task scheduling. To start scheduling call {@link #schedule(Callable)}.
      *
      * @param sched Cron scheduler.


Mime
View raw message