ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From voze...@apache.org
Subject [5/6] incubator-ignite git commit: # IGNITE-465: Test fixes.
Date Thu, 12 Mar 2015 14:29:54 GMT
# IGNITE-465: Test fixes.


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

Branch: refs/heads/ignite-465
Commit: 0f85dc97fb38c3d6e647877910a62263735e45b0
Parents: 04d7797
Author: vozerov-gridgain <vozerov@gridgain.com>
Authored: Thu Mar 12 17:24:13 2015 +0300
Committer: vozerov-gridgain <vozerov@gridgain.com>
Committed: Thu Mar 12 17:24:13 2015 +0300

----------------------------------------------------------------------
 .../visor/node/VisorIgfsConfiguration.java      |  5 ++-
 .../processors/igfs/IgfsAbstractSelfTest.java   | 24 +++++++----
 ...sCachePerBlockLruEvictionPolicySelfTest.java | 12 ++++--
 .../processors/igfs/IgfsMetricsSelfTest.java    | 12 ++++--
 .../processors/igfs/IgfsModesSelfTest.java      |  9 ++--
 ...IpcEndpointRegistrationAbstractSelfTest.java | 21 +++++-----
 ...dpointRegistrationOnLinuxAndMacSelfTest.java |  7 ++--
 ...pcEndpointRegistrationOnWindowsSelfTest.java |  5 ++-
 .../ipc/shmem/IpcSharedMemoryNodeStartup.java   |  9 ++--
 .../ignite/testsuites/IgniteIgfsTestSuite.java  |  2 -
 .../hadoop/igfs/HadoopIgfsEndpoint.java         |  5 +--
 .../HadoopIgfs20FileSystemAbstractSelfTest.java |  4 +-
 ...Igfs20FileSystemLoopbackPrimarySelfTest.java | 14 ++++---
 ...oopIgfs20FileSystemShmemPrimarySelfTest.java | 14 ++++---
 .../igfs/HadoopIgfsDualAbstractSelfTest.java    | 25 ++++++-----
 ...oopSecondaryFileSystemConfigurationTest.java | 25 ++++++-----
 .../apache/ignite/igfs/IgfsEventsTestSuite.java | 44 ++++++++++++--------
 .../igfs/IgfsNearOnlyMultiNodeSelfTest.java     | 10 +++--
 .../IgniteHadoopFileSystemAbstractSelfTest.java | 16 ++++---
 .../IgniteHadoopFileSystemClientSelfTest.java   | 11 +++--
 ...IgniteHadoopFileSystemHandshakeSelfTest.java | 14 ++++---
 .../IgniteHadoopFileSystemIpcCacheSelfTest.java | 10 +++--
 ...niteHadoopFileSystemLoggerStateSelfTest.java | 12 +++---
 ...adoopFileSystemLoopbackAbstractSelfTest.java | 12 +++---
 ...teHadoopFileSystemSecondaryModeSelfTest.java | 23 ++++++----
 ...teHadoopFileSystemShmemAbstractSelfTest.java | 12 +++---
 .../hadoop/HadoopPopularWordsTest.java          |  4 +-
 27 files changed, 211 insertions(+), 150 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/core/src/main/java/org/apache/ignite/internal/visor/node/VisorIgfsConfiguration.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/visor/node/VisorIgfsConfiguration.java b/modules/core/src/main/java/org/apache/ignite/internal/visor/node/VisorIgfsConfiguration.java
index d589138..a1e3c52 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/visor/node/VisorIgfsConfiguration.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/visor/node/VisorIgfsConfiguration.java
@@ -154,7 +154,8 @@ public class VisorIgfsConfiguration implements Serializable {
         cfg.fragmentizerThrottlingBlockLen = igfs.getFragmentizerThrottlingBlockLength();
         cfg.fragmentizerThrottlingDelay = igfs.getFragmentizerThrottlingDelay();
 
-        Map<String, String> endpointCfg = igfs.getIpcEndpointConfiguration();
+        IgfsIpcEndpointConfiguration  endpointCfg = igfs.getIpcEndpointConfiguration();
+
         cfg.ipcEndpointCfg = endpointCfg != null ? endpointCfg.toString() : null;
 
         cfg.ipcEndpointEnabled = igfs.isIpcEndpointEnabled();
@@ -332,7 +333,7 @@ public class VisorIgfsConfiguration implements Serializable {
     }
 
     /**
-     * @return IPC endpoint config (in JSON format) to publish IGFS over.
+     * @return IPC endpoint config to publish IGFS over.
      */
     @Nullable public String ipcEndpointConfiguration() {
         return ipcEndpointCfg;

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsAbstractSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsAbstractSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsAbstractSelfTest.java
index 9dde005..016807e 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsAbstractSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsAbstractSelfTest.java
@@ -68,16 +68,10 @@ public abstract class IgfsAbstractSelfTest extends IgfsCommonAbstractTest {
     protected static final int SEQ_READS_BEFORE_PREFETCH = 2;
 
     /** Primary file system REST endpoint configuration map. */
-    protected static final Map<String, String> PRIMARY_REST_CFG = new HashMap<String, String>() {{
-        put("type", "tcp");
-        put("port", "10500");
-    }};
+    protected static final IgfsIpcEndpointConfiguration PRIMARY_REST_CFG;
 
     /** Secondary file system REST endpoint configuration map. */
-    protected static final Map<String, String> SECONDARY_REST_CFG = new HashMap<String, String>() {{
-        put("type", "tcp");
-        put("port", "11500");
-    }};
+    protected static final IgfsIpcEndpointConfiguration SECONDARY_REST_CFG;
 
     /** Directory. */
     protected static final IgfsPath DIR = new IgfsPath("/dir");
@@ -127,6 +121,18 @@ public abstract class IgfsAbstractSelfTest extends IgfsCommonAbstractTest {
     /** Memory mode. */
     protected final CacheMemoryMode memoryMode;
 
+    static {
+        PRIMARY_REST_CFG = new IgfsIpcEndpointConfiguration();
+
+        PRIMARY_REST_CFG.setType(IgfsIpcEndpointType.TCP);
+        PRIMARY_REST_CFG.setPort(10500);
+
+        SECONDARY_REST_CFG = new IgfsIpcEndpointConfiguration();
+
+        SECONDARY_REST_CFG.setType(IgfsIpcEndpointType.TCP);
+        SECONDARY_REST_CFG.setPort(11500);
+    }
+
     /**
      * Constructor.
      *
@@ -183,7 +189,7 @@ public abstract class IgfsAbstractSelfTest extends IgfsCommonAbstractTest {
      * @throws Exception If failed.
      */
     protected Ignite startGridWithIgfs(String gridName, String igfsName, IgfsMode mode,
-        @Nullable IgfsSecondaryFileSystem secondaryFs, @Nullable Map<String, String> restCfg) throws Exception {
+        @Nullable IgfsSecondaryFileSystem secondaryFs, @Nullable IgfsIpcEndpointConfiguration restCfg) throws Exception {
         FileSystemConfiguration igfsCfg = new FileSystemConfiguration();
 
         igfsCfg.setDataCacheName("dataCache");

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsCachePerBlockLruEvictionPolicySelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsCachePerBlockLruEvictionPolicySelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsCachePerBlockLruEvictionPolicySelfTest.java
index fd590f5..f9c83d5 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsCachePerBlockLruEvictionPolicySelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsCachePerBlockLruEvictionPolicySelfTest.java
@@ -50,10 +50,7 @@ public class IgfsCachePerBlockLruEvictionPolicySelfTest extends IgfsCommonAbstra
     private static final String IGFS_SECONDARY = "igfs-secondary";
 
     /** Secondary file system REST endpoint configuration map. */
-    private static final Map<String, String> SECONDARY_REST_CFG = new HashMap<String, String>() {{
-        put("type", "tcp");
-        put("port", "11500");
-    }};
+    private static final IgfsIpcEndpointConfiguration SECONDARY_REST_CFG;
 
     /** File working in PRIMARY mode. */
     public static final IgfsPath FILE = new IgfsPath("/file");
@@ -73,6 +70,13 @@ public class IgfsCachePerBlockLruEvictionPolicySelfTest extends IgfsCommonAbstra
     /** Eviction policy */
     private static CacheIgfsPerBlockLruEvictionPolicy evictPlc;
 
+    static {
+        SECONDARY_REST_CFG = new IgfsIpcEndpointConfiguration();
+
+        SECONDARY_REST_CFG.setType(IgfsIpcEndpointType.TCP);
+        SECONDARY_REST_CFG.setPort(11500);
+    }
+
     /**
      * Start a grid with the primary file system.
      *

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsMetricsSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsMetricsSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsMetricsSelfTest.java
index 0af1dea..65098e5 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsMetricsSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsMetricsSelfTest.java
@@ -44,10 +44,7 @@ public class IgfsMetricsSelfTest extends IgfsCommonAbstractTest {
     private static final String IGFS_SECONDARY = "igfs-secondary";
 
     /** Secondary file system REST endpoint configuration map. */
-    private static final Map<String, String> SECONDARY_REST_CFG = new HashMap<String, String>(){{
-        put("type", "tcp");
-        put("port", "11500");
-    }};
+    private static final IgfsIpcEndpointConfiguration SECONDARY_REST_CFG;
 
     /** Test nodes count. */
     private static final int NODES_CNT = 3;
@@ -67,6 +64,13 @@ public class IgfsMetricsSelfTest extends IgfsCommonAbstractTest {
     /** Secondary file system block size. */
     public static final int SECONDARY_BLOCK_SIZE = 512;
 
+    static {
+        SECONDARY_REST_CFG = new IgfsIpcEndpointConfiguration();
+
+        SECONDARY_REST_CFG.setType(IgfsIpcEndpointType.TCP);
+        SECONDARY_REST_CFG.setPort(11500);
+    }
+
     /** {@inheritDoc} */
     @Override protected void beforeTestsStarted() throws Exception {
         startSecondary();

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsModesSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsModesSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsModesSelfTest.java
index 4a58285..c084046 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsModesSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsModesSelfTest.java
@@ -151,10 +151,11 @@ public class IgfsModesSelfTest extends IgfsCommonAbstractTest {
         igfsCfg.setName("igfs-secondary");
         igfsCfg.setBlockSize(512 * 1024);
         igfsCfg.setDefaultMode(PRIMARY);
-        igfsCfg.setIpcEndpointConfiguration(new HashMap<String, String>() {{
-            put("type", "tcp");
-            put("port", "11500");
-        }});
+
+        IgfsIpcEndpointConfiguration endpointCfg = new IgfsIpcEndpointConfiguration();
+
+        endpointCfg.setType(IgfsIpcEndpointType.TCP);
+        endpointCfg.setPort(11500);
 
         CacheConfiguration cacheCfg = defaultCacheConfiguration();
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsServerManagerIpcEndpointRegistrationAbstractSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsServerManagerIpcEndpointRegistrationAbstractSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsServerManagerIpcEndpointRegistrationAbstractSelfTest.java
index 694d5c3..431baba 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsServerManagerIpcEndpointRegistrationAbstractSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsServerManagerIpcEndpointRegistrationAbstractSelfTest.java
@@ -59,7 +59,7 @@ public abstract class IgfsServerManagerIpcEndpointRegistrationAbstractSelfTest e
         IgniteConfiguration cfg = gridConfiguration();
 
         cfg.setFileSystemConfiguration(
-            igfsConfiguration("tcp", DFLT_IPC_PORT, null)
+            igfsConfiguration(IgfsIpcEndpointType.TCP, IgfsIpcEndpointConfiguration.DFLT_PORT, null)
         );
 
         G.start(cfg);
@@ -78,8 +78,9 @@ public abstract class IgfsServerManagerIpcEndpointRegistrationAbstractSelfTest e
         IgniteConfiguration cfg = gridConfiguration();
 
         cfg.setFileSystemConfiguration(
-            igfsConfiguration("tcp", DFLT_IPC_PORT, "127.0.0.1"),
-            igfsConfiguration("tcp", DFLT_IPC_PORT + 1, U.getLocalHost().getHostName()));
+            igfsConfiguration(IgfsIpcEndpointType.TCP, IgfsIpcEndpointConfiguration.DFLT_PORT, "127.0.0.1"),
+            igfsConfiguration(IgfsIpcEndpointType.TCP, IgfsIpcEndpointConfiguration.DFLT_PORT + 1,
+                U.getLocalHost().getHostName()));
 
         G.start(cfg);
 
@@ -154,20 +155,20 @@ public abstract class IgfsServerManagerIpcEndpointRegistrationAbstractSelfTest e
      * @param endPntHost End point host.
      * @return test-purposed IgfsConfiguration.
      */
-    protected FileSystemConfiguration igfsConfiguration(@Nullable String endPntType, @Nullable Integer endPntPort,
-        @Nullable String endPntHost) throws IgniteCheckedException {
-        HashMap<String, String> endPntCfg = null;
+    protected FileSystemConfiguration igfsConfiguration(@Nullable IgfsIpcEndpointType endPntType,
+        @Nullable Integer endPntPort, @Nullable String endPntHost) throws IgniteCheckedException {
+        IgfsIpcEndpointConfiguration endPntCfg = null;
 
         if (endPntType != null) {
-            endPntCfg = new HashMap<>();
+            endPntCfg = new IgfsIpcEndpointConfiguration();
 
-            endPntCfg.put("type", endPntType);
+            endPntCfg.setType(endPntType);
 
             if (endPntPort != null)
-                endPntCfg.put("port", String.valueOf(endPntPort));
+                endPntCfg.setPort(endPntPort);
 
             if (endPntHost != null)
-                endPntCfg.put("host", endPntHost);
+                endPntCfg.setHost(endPntHost);
         }
 
         FileSystemConfiguration igfsConfiguration = new FileSystemConfiguration();

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsServerManagerIpcEndpointRegistrationOnLinuxAndMacSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsServerManagerIpcEndpointRegistrationOnLinuxAndMacSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsServerManagerIpcEndpointRegistrationOnLinuxAndMacSelfTest.java
index 57f10d9..a0f24fb 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsServerManagerIpcEndpointRegistrationOnLinuxAndMacSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsServerManagerIpcEndpointRegistrationOnLinuxAndMacSelfTest.java
@@ -18,10 +18,9 @@
 package org.apache.ignite.internal.processors.igfs;
 
 import org.apache.ignite.configuration.*;
+import org.apache.ignite.igfs.*;
 import org.apache.ignite.internal.util.typedef.*;
 
-import static org.apache.ignite.configuration.FileSystemConfiguration.*;
-
 /**
  * Tests for {@link IgfsServer} that checks all IPC endpoint registration types
  * permitted for Linux and Mac OS.
@@ -36,8 +35,8 @@ public class IgfsServerManagerIpcEndpointRegistrationOnLinuxAndMacSelfTest
 
         cfg.setFileSystemConfiguration(
             igfsConfiguration(null, null, null), // Check null IPC endpoint config won't bring any hassles.
-            igfsConfiguration("tcp", DFLT_IPC_PORT + 1, null),
-            igfsConfiguration("shmem", DFLT_IPC_PORT + 2, null));
+            igfsConfiguration(IgfsIpcEndpointType.TCP, IgfsIpcEndpointConfiguration.DFLT_PORT + 1, null),
+            igfsConfiguration(IgfsIpcEndpointType.SHMEM, IgfsIpcEndpointConfiguration.DFLT_PORT + 2, null));
 
         G.start(cfg);
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsServerManagerIpcEndpointRegistrationOnWindowsSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsServerManagerIpcEndpointRegistrationOnWindowsSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsServerManagerIpcEndpointRegistrationOnWindowsSelfTest.java
index 4f18aff..c9c03ce 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsServerManagerIpcEndpointRegistrationOnWindowsSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/igfs/IgfsServerManagerIpcEndpointRegistrationOnWindowsSelfTest.java
@@ -19,6 +19,7 @@ package org.apache.ignite.internal.processors.igfs;
 
 import org.apache.ignite.*;
 import org.apache.ignite.configuration.*;
+import org.apache.ignite.igfs.*;
 import org.apache.ignite.internal.util.ipc.loopback.*;
 import org.apache.ignite.internal.util.ipc.shmem.*;
 import org.apache.ignite.internal.util.typedef.*;
@@ -40,8 +41,8 @@ public class IgfsServerManagerIpcEndpointRegistrationOnWindowsSelfTest
             @Override public Object call() throws Exception {
                 IgniteConfiguration cfg = gridConfiguration();
 
-                cfg.setFileSystemConfiguration(igfsConfiguration("shmem", IpcSharedMemoryServerEndpoint.DFLT_IPC_PORT,
-                    null));
+                cfg.setFileSystemConfiguration(igfsConfiguration(IgfsIpcEndpointType.SHMEM,
+                    IpcSharedMemoryServerEndpoint.DFLT_IPC_PORT, null));
 
                 return G.start(cfg);
             }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/core/src/test/java/org/apache/ignite/internal/util/ipc/shmem/IpcSharedMemoryNodeStartup.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/util/ipc/shmem/IpcSharedMemoryNodeStartup.java b/modules/core/src/test/java/org/apache/ignite/internal/util/ipc/shmem/IpcSharedMemoryNodeStartup.java
index 8051a3e..6bbee42 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/util/ipc/shmem/IpcSharedMemoryNodeStartup.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/util/ipc/shmem/IpcSharedMemoryNodeStartup.java
@@ -19,12 +19,11 @@ package org.apache.ignite.internal.util.ipc.shmem;
 
 import org.apache.ignite.*;
 import org.apache.ignite.configuration.*;
+import org.apache.ignite.igfs.*;
 import org.apache.ignite.internal.util.typedef.*;
 import org.apache.ignite.spi.discovery.tcp.*;
 import org.apache.ignite.spi.discovery.tcp.ipfinder.vm.*;
 
-import java.util.*;
-
 import static org.apache.ignite.cache.CacheDistributionMode.*;
 import static org.apache.ignite.cache.CacheMode.*;
 import static org.apache.ignite.cache.CacheWriteSynchronizationMode.*;
@@ -49,10 +48,10 @@ public class IpcSharedMemoryNodeStartup {
 
         cfg.setDiscoverySpi(discoSpi);
 
-        Map<String, String> endpointCfg = new HashMap<>();
+        IgfsIpcEndpointConfiguration endpointCfg = new IgfsIpcEndpointConfiguration();
 
-        endpointCfg.put("type", "shmem");
-        endpointCfg.put("port", "10500");
+        endpointCfg.setType(IgfsIpcEndpointType.SHMEM);
+        endpointCfg.setPort(10500);
 
         igfsCfg.setIpcEndpointConfiguration(endpointCfg);
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteIgfsTestSuite.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteIgfsTestSuite.java b/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteIgfsTestSuite.java
index e67e661..c0893cc 100644
--- a/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteIgfsTestSuite.java
+++ b/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteIgfsTestSuite.java
@@ -21,7 +21,6 @@ import junit.framework.*;
 import org.apache.ignite.igfs.*;
 import org.apache.ignite.internal.processors.igfs.*;
 import org.apache.ignite.internal.processors.igfs.split.*;
-import org.apache.ignite.internal.util.ipc.*;
 import org.apache.ignite.internal.util.typedef.internal.*;
 
 /**
@@ -52,7 +51,6 @@ public class IgniteIgfsTestSuite extends TestSuite {
 
         suite.addTest(new TestSuite(IgfsStreamsSelfTest.class));
         suite.addTest(new TestSuite(IgfsModesSelfTest.class));
-        suite.addTest(new TestSuite(IpcServerEndpointDeserializerSelfTest.class));
         suite.addTest(new TestSuite(IgfsMetricsSelfTest.class));
 
         suite.addTest(new TestSuite(IgfsPrimarySelfTest.class));

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/hadoop/src/main/java/org/apache/ignite/internal/processors/hadoop/igfs/HadoopIgfsEndpoint.java
----------------------------------------------------------------------
diff --git a/modules/hadoop/src/main/java/org/apache/ignite/internal/processors/hadoop/igfs/HadoopIgfsEndpoint.java b/modules/hadoop/src/main/java/org/apache/ignite/internal/processors/hadoop/igfs/HadoopIgfsEndpoint.java
index 7502f57..26d1940 100644
--- a/modules/hadoop/src/main/java/org/apache/ignite/internal/processors/hadoop/igfs/HadoopIgfsEndpoint.java
+++ b/modules/hadoop/src/main/java/org/apache/ignite/internal/processors/hadoop/igfs/HadoopIgfsEndpoint.java
@@ -18,6 +18,7 @@
 package org.apache.ignite.internal.processors.hadoop.igfs;
 
 import org.apache.ignite.*;
+import org.apache.ignite.igfs.*;
 import org.apache.ignite.internal.util.typedef.*;
 import org.apache.ignite.internal.util.typedef.internal.*;
 import org.apache.ignite.lang.*;
@@ -26,8 +27,6 @@ import org.jetbrains.annotations.*;
 import java.io.*;
 import java.net.*;
 
-import static org.apache.ignite.configuration.FileSystemConfiguration.*;
-
 /**
  * IGFS endpoint abstraction.
  */
@@ -148,7 +147,7 @@ public class HadoopIgfsEndpoint {
         int port;
 
         if (tokens.length == 1)
-            port = DFLT_IPC_PORT;
+            port = IgfsIpcEndpointConfiguration.DFLT_PORT;
         else if (tokens.length == 2) {
             String portStr = tokens[1];
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopIgfs20FileSystemAbstractSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopIgfs20FileSystemAbstractSelfTest.java b/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopIgfs20FileSystemAbstractSelfTest.java
index d907a6c..361d2ff 100644
--- a/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopIgfs20FileSystemAbstractSelfTest.java
+++ b/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopIgfs20FileSystemAbstractSelfTest.java
@@ -107,7 +107,7 @@ public abstract class HadoopIgfs20FileSystemAbstractSelfTest extends IgfsCommonA
      * @param gridName Grid name.
      * @return IPC primary endpoint configuration.
      */
-    protected abstract Map<String, String>  primaryIpcEndpointConfiguration(String gridName);
+    protected abstract IgfsIpcEndpointConfiguration primaryIpcEndpointConfiguration(String gridName);
 
     /**
      * Gets secondary file system URI path.
@@ -128,7 +128,7 @@ public abstract class HadoopIgfs20FileSystemAbstractSelfTest extends IgfsCommonA
      *
      * @return Secondary IPC endpoint configuration.
      */
-    protected abstract Map<String, String>  secondaryIpcEndpointConfiguration();
+    protected abstract IgfsIpcEndpointConfiguration secondaryIpcEndpointConfiguration();
 
     /** {@inheritDoc} */
     @Override protected void beforeTestsStarted() throws Exception {

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopIgfs20FileSystemLoopbackPrimarySelfTest.java
----------------------------------------------------------------------
diff --git a/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopIgfs20FileSystemLoopbackPrimarySelfTest.java b/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopIgfs20FileSystemLoopbackPrimarySelfTest.java
index 2be65fd..8a5b12f 100644
--- a/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopIgfs20FileSystemLoopbackPrimarySelfTest.java
+++ b/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopIgfs20FileSystemLoopbackPrimarySelfTest.java
@@ -44,11 +44,13 @@ public class HadoopIgfs20FileSystemLoopbackPrimarySelfTest extends HadoopIgfs20F
     }
 
     /** {@inheritDoc} */
-    @Override protected Map<String, String> primaryIpcEndpointConfiguration(final String gridName) {
-        return new HashMap<String, String>() {{
-            put("type", "tcp");
-            put("port", String.valueOf(DFLT_IPC_PORT + getTestGridIndex(gridName)));
-        }};
+    @Override protected IgfsIpcEndpointConfiguration primaryIpcEndpointConfiguration(final String gridName) {
+        IgfsIpcEndpointConfiguration cfg = new IgfsIpcEndpointConfiguration();
+
+        cfg.setType(IgfsIpcEndpointType.TCP);
+        cfg.setPort(DFLT_IPC_PORT + getTestGridIndex(gridName));
+
+        return cfg;
     }
 
     /** {@inheritDoc} */
@@ -66,7 +68,7 @@ public class HadoopIgfs20FileSystemLoopbackPrimarySelfTest extends HadoopIgfs20F
     }
 
     /** {@inheritDoc} */
-    @Override protected Map<String, String> secondaryIpcEndpointConfiguration() {
+    @Override protected IgfsIpcEndpointConfiguration secondaryIpcEndpointConfiguration() {
         assert false;
 
         return null;

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopIgfs20FileSystemShmemPrimarySelfTest.java
----------------------------------------------------------------------
diff --git a/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopIgfs20FileSystemShmemPrimarySelfTest.java b/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopIgfs20FileSystemShmemPrimarySelfTest.java
index 93f2d4a..d38c23d 100644
--- a/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopIgfs20FileSystemShmemPrimarySelfTest.java
+++ b/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopIgfs20FileSystemShmemPrimarySelfTest.java
@@ -44,11 +44,13 @@ public class HadoopIgfs20FileSystemShmemPrimarySelfTest extends HadoopIgfs20File
     }
 
     /** {@inheritDoc} */
-    @Override protected Map<String, String> primaryIpcEndpointConfiguration(final String gridName) {
-        return new HashMap<String, String>() {{
-            put("type", "shmem");
-            put("port", String.valueOf(DFLT_IPC_PORT + getTestGridIndex(gridName)));
-        }};
+    @Override protected IgfsIpcEndpointConfiguration primaryIpcEndpointConfiguration(final String gridName) {
+        IgfsIpcEndpointConfiguration cfg = new IgfsIpcEndpointConfiguration();
+
+        cfg.setType(IgfsIpcEndpointType.SHMEM);
+        cfg.setPort(DFLT_IPC_PORT + getTestGridIndex(gridName));
+
+        return cfg;
     }
 
     /** {@inheritDoc} */
@@ -66,7 +68,7 @@ public class HadoopIgfs20FileSystemShmemPrimarySelfTest extends HadoopIgfs20File
     }
 
     /** {@inheritDoc} */
-    @Override protected Map<String, String> secondaryIpcEndpointConfiguration() {
+    @Override protected IgfsIpcEndpointConfiguration secondaryIpcEndpointConfiguration() {
         assert false;
 
         return null;

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopIgfsDualAbstractSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopIgfsDualAbstractSelfTest.java b/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopIgfsDualAbstractSelfTest.java
index e89d015..b3912e5 100644
--- a/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopIgfsDualAbstractSelfTest.java
+++ b/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopIgfsDualAbstractSelfTest.java
@@ -35,7 +35,6 @@ import org.jetbrains.annotations.*;
 
 import java.io.*;
 import java.net.*;
-import java.util.*;
 import java.util.concurrent.*;
 
 import static org.apache.ignite.cache.CacheAtomicityMode.*;
@@ -70,16 +69,10 @@ public abstract class HadoopIgfsDualAbstractSelfTest extends IgfsCommonAbstractT
     protected static final String PRIMARY_CFG = "modules/core/src/test/config/hadoop/core-site-loopback.xml";
 
     /** Primary file system REST endpoint configuration map. */
-    protected static final Map<String, String> PRIMARY_REST_CFG = new HashMap<String, String>() {{
-        put("type", "tcp");
-        put("port", "10500");
-    }};
+    protected static final IgfsIpcEndpointConfiguration PRIMARY_REST_CFG;
 
     /** Secondary file system REST endpoint configuration map. */
-    protected static final Map<String, String> SECONDARY_REST_CFG = new HashMap<String, String>() {{
-        put("type", "tcp");
-        put("port", "11500");
-    }};
+    protected static final IgfsIpcEndpointConfiguration SECONDARY_REST_CFG;
 
     /** Directory. */
     protected static final IgfsPath DIR = new IgfsPath("/dir");
@@ -102,6 +95,18 @@ public abstract class HadoopIgfsDualAbstractSelfTest extends IgfsCommonAbstractT
     /** IGFS mode. */
     protected final IgfsMode mode;
 
+    static {
+        PRIMARY_REST_CFG = new IgfsIpcEndpointConfiguration();
+
+        PRIMARY_REST_CFG.setType(IgfsIpcEndpointType.TCP);
+        PRIMARY_REST_CFG.setPort(10500);
+
+        SECONDARY_REST_CFG = new IgfsIpcEndpointConfiguration();
+
+        SECONDARY_REST_CFG.setType(IgfsIpcEndpointType.TCP);
+        SECONDARY_REST_CFG.setPort(11500);
+    }
+
     /**
      * Constructor.
      *
@@ -124,7 +129,7 @@ public abstract class HadoopIgfsDualAbstractSelfTest extends IgfsCommonAbstractT
      * @throws Exception If failed.
      */
     protected Ignite startGridWithIgfs(String gridName, String igfsName, IgfsMode mode,
-        @Nullable IgfsSecondaryFileSystem secondaryFs, @Nullable Map<String, String> restCfg) throws Exception {
+        @Nullable IgfsSecondaryFileSystem secondaryFs, @Nullable IgfsIpcEndpointConfiguration restCfg) throws Exception {
         FileSystemConfiguration igfsCfg = new FileSystemConfiguration();
 
         igfsCfg.setDataCacheName("dataCache");

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopSecondaryFileSystemConfigurationTest.java
----------------------------------------------------------------------
diff --git a/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopSecondaryFileSystemConfigurationTest.java b/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopSecondaryFileSystemConfigurationTest.java
index 11279ca..dbe2449 100644
--- a/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopSecondaryFileSystemConfigurationTest.java
+++ b/modules/hadoop/src/test/java/org/apache/ignite/igfs/HadoopSecondaryFileSystemConfigurationTest.java
@@ -40,7 +40,6 @@ import org.apache.ignite.testframework.*;
 
 import java.io.*;
 import java.net.*;
-import java.util.*;
 import java.util.concurrent.*;
 
 import static org.apache.ignite.cache.CacheAtomicityMode.*;
@@ -69,10 +68,7 @@ public class HadoopSecondaryFileSystemConfigurationTest extends IgfsCommonAbstra
     private static final String SECONDARY_CFG_PATH = "/work/core-site-test.xml";
 
     /** Secondary endpoint configuration. */
-    protected static final Map<String, String> SECONDARY_ENDPOINT_CFG = new HashMap<String, String>() {{
-        put("type", "tcp");
-        put("port", "11500");
-    }};
+    protected static final IgfsIpcEndpointConfiguration SECONDARY_ENDPOINT_CFG;
 
     /** Group size. */
     public static final int GRP_SIZE = 128;
@@ -125,6 +121,13 @@ public class HadoopSecondaryFileSystemConfigurationTest extends IgfsCommonAbstra
     /** Skip local shmem flag. */
     private final boolean skipLocShmem;
 
+    static {
+        SECONDARY_ENDPOINT_CFG = new IgfsIpcEndpointConfiguration();
+
+        SECONDARY_ENDPOINT_CFG.setType(IgfsIpcEndpointType.TCP);
+        SECONDARY_ENDPOINT_CFG.setPort(11500);
+    }
+
     /**
      * Constructor.
      *
@@ -291,11 +294,13 @@ public class HadoopSecondaryFileSystemConfigurationTest extends IgfsCommonAbstra
      * @param gridName Grid name.
      * @return IPC primary endpoint configuration.
      */
-    protected Map<String, String> primaryIpcEndpointConfiguration(final String gridName) {
-        return new HashMap<String, String>() {{
-            put("type", "tcp");
-            put("port", String.valueOf(DFLT_IPC_PORT + getTestGridIndex(gridName)));
-        }};
+    protected IgfsIpcEndpointConfiguration primaryIpcEndpointConfiguration(final String gridName) {
+        IgfsIpcEndpointConfiguration cfg = new IgfsIpcEndpointConfiguration();
+
+        cfg.setType(IgfsIpcEndpointType.TCP);
+        cfg.setPort(DFLT_IPC_PORT + getTestGridIndex(gridName));
+
+        return cfg;
     }
 
     /** {@inheritDoc} */

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgfsEventsTestSuite.java
----------------------------------------------------------------------
diff --git a/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgfsEventsTestSuite.java b/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgfsEventsTestSuite.java
index f6f5bae..c082fe0 100644
--- a/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgfsEventsTestSuite.java
+++ b/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgfsEventsTestSuite.java
@@ -26,8 +26,6 @@ import org.apache.ignite.internal.util.ipc.shmem.*;
 import org.apache.ignite.internal.util.typedef.*;
 import org.jetbrains.annotations.*;
 
-import java.util.*;
-
 import static org.apache.ignite.igfs.IgfsMode.*;
 
 /**
@@ -79,10 +77,12 @@ public class IgfsEventsTestSuite extends TestSuite {
         @Override protected FileSystemConfiguration getIgfsConfiguration() throws IgniteCheckedException {
             FileSystemConfiguration igfsCfg = super.getIgfsConfiguration();
 
-            igfsCfg.setIpcEndpointConfiguration(new HashMap<String, String>() {{
-                put("type", "shmem");
-                put("port", String.valueOf(IpcSharedMemoryServerEndpoint.DFLT_IPC_PORT + 1));
-            }});
+            IgfsIpcEndpointConfiguration endpointCfg = new IgfsIpcEndpointConfiguration();
+
+            endpointCfg.setType(IgfsIpcEndpointType.SHMEM);
+            endpointCfg.setPort(IpcSharedMemoryServerEndpoint.DFLT_IPC_PORT + 1);
+
+            igfsCfg.setIpcEndpointConfiguration(endpointCfg);
 
             return igfsCfg;
         }
@@ -96,10 +96,12 @@ public class IgfsEventsTestSuite extends TestSuite {
         @Override protected FileSystemConfiguration getIgfsConfiguration() throws IgniteCheckedException {
             FileSystemConfiguration igfsCfg = super.getIgfsConfiguration();
 
-            igfsCfg.setIpcEndpointConfiguration(new HashMap<String, String>() {{
-                put("type", "tcp");
-                put("port", String.valueOf(IpcSharedMemoryServerEndpoint.DFLT_IPC_PORT + 1));
-            }});
+            IgfsIpcEndpointConfiguration endpointCfg = new IgfsIpcEndpointConfiguration();
+
+            endpointCfg.setType(IgfsIpcEndpointType.TCP);
+            endpointCfg.setPort(IpcSharedMemoryServerEndpoint.DFLT_IPC_PORT + 1);
+
+            igfsCfg.setIpcEndpointConfiguration(endpointCfg);
 
             return igfsCfg;
         }
@@ -131,10 +133,13 @@ public class IgfsEventsTestSuite extends TestSuite {
 
             igfsCfg.setName("igfs-secondary");
             igfsCfg.setDefaultMode(PRIMARY);
-            igfsCfg.setIpcEndpointConfiguration(new HashMap<String, String>(){{
-                put("type", "tcp");
-                put("port", "11500");
-            }});
+
+            IgfsIpcEndpointConfiguration endpointCfg = new IgfsIpcEndpointConfiguration();
+
+            endpointCfg.setType(IgfsIpcEndpointType.TCP);
+            endpointCfg.setPort(11500);
+
+            igfsCfg.setIpcEndpointConfiguration(endpointCfg);
 
             return igfsCfg;
         }
@@ -228,10 +233,13 @@ public class IgfsEventsTestSuite extends TestSuite {
 
             igfsCfg.setName("igfs-secondary");
             igfsCfg.setDefaultMode(PRIMARY);
-            igfsCfg.setIpcEndpointConfiguration(new HashMap<String, String>() {{
-                put("type", "tcp");
-                put("port", "11500");
-            }});
+
+            IgfsIpcEndpointConfiguration endpointCfg = new IgfsIpcEndpointConfiguration();
+
+            endpointCfg.setType(IgfsIpcEndpointType.TCP);
+            endpointCfg.setPort(11500);
+
+            igfsCfg.setIpcEndpointConfiguration(endpointCfg);
 
             return igfsCfg;
         }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgfsNearOnlyMultiNodeSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgfsNearOnlyMultiNodeSelfTest.java b/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgfsNearOnlyMultiNodeSelfTest.java
index d128731..eece455 100644
--- a/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgfsNearOnlyMultiNodeSelfTest.java
+++ b/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgfsNearOnlyMultiNodeSelfTest.java
@@ -81,10 +81,12 @@ public class IgfsNearOnlyMultiNodeSelfTest extends GridCommonAbstractTest {
         igfsCfg.setMetaCacheName("partitioned");
         igfsCfg.setName("igfs");
 
-        igfsCfg.setIpcEndpointConfiguration(new HashMap<String, String>() {{
-            put("type", "shmem");
-            put("port", String.valueOf(IpcSharedMemoryServerEndpoint.DFLT_IPC_PORT + cnt));
-        }});
+        IgfsIpcEndpointConfiguration endpointCfg = new IgfsIpcEndpointConfiguration();
+
+        endpointCfg.setType(IgfsIpcEndpointType.SHMEM);
+        endpointCfg.setPort(IpcSharedMemoryServerEndpoint.DFLT_IPC_PORT + cnt);
+
+        igfsCfg.setIpcEndpointConfiguration(endpointCfg);
 
         igfsCfg.setBlockSize(512 * 1024); // Together with group blocks mapper will yield 64M per node groups.
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemAbstractSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemAbstractSelfTest.java b/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemAbstractSelfTest.java
index be25c61..4c59b05 100644
--- a/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemAbstractSelfTest.java
+++ b/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemAbstractSelfTest.java
@@ -25,7 +25,7 @@ import org.apache.ignite.*;
 import org.apache.ignite.cache.*;
 import org.apache.ignite.configuration.*;
 import org.apache.ignite.hadoop.fs.*;
-import org.apache.ignite.hadoop.fs.v1.IgniteHadoopFileSystem;
+import org.apache.ignite.hadoop.fs.v1.*;
 import org.apache.ignite.internal.processors.hadoop.igfs.*;
 import org.apache.ignite.internal.processors.igfs.*;
 import org.apache.ignite.internal.util.*;
@@ -75,10 +75,7 @@ public abstract class IgniteHadoopFileSystemAbstractSelfTest extends IgfsCommonA
     private static final String SECONDARY_CFG_PATH = "/work/core-site-test.xml";
 
     /** Secondary endpoint configuration. */
-    protected static final Map<String, String> SECONDARY_ENDPOINT_CFG = new HashMap<String, String>() {{
-        put("type", "tcp");
-        put("port", "11500");
-    }};
+    protected static final IgfsIpcEndpointConfiguration SECONDARY_ENDPOINT_CFG;
 
     /** Group size. */
     public static final int GRP_SIZE = 128;
@@ -116,6 +113,13 @@ public abstract class IgniteHadoopFileSystemAbstractSelfTest extends IgfsCommonA
     /** Primary file system configuration. */
     protected Configuration primaryFsCfg;
 
+    static {
+        SECONDARY_ENDPOINT_CFG = new IgfsIpcEndpointConfiguration();
+
+        SECONDARY_ENDPOINT_CFG.setType(IgfsIpcEndpointType.TCP);
+        SECONDARY_ENDPOINT_CFG.setPort(11500);
+    }
+
     /** File statuses comparator. */
     private static final Comparator<FileStatus> STATUS_COMPARATOR = new Comparator<FileStatus>() {
         @SuppressWarnings("deprecation")
@@ -260,7 +264,7 @@ public abstract class IgniteHadoopFileSystemAbstractSelfTest extends IgfsCommonA
      * @param gridName Grid name.
      * @return IPC primary endpoint configuration.
      */
-    protected abstract Map<String, String> primaryIpcEndpointConfiguration(String gridName);
+    protected abstract IgfsIpcEndpointConfiguration primaryIpcEndpointConfiguration(String gridName);
 
     /** {@inheritDoc} */
     @Override public String getTestGridName() {

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemClientSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemClientSelfTest.java b/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemClientSelfTest.java
index 29dd996..15a3706 100644
--- a/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemClientSelfTest.java
+++ b/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemClientSelfTest.java
@@ -72,10 +72,13 @@ public class IgniteHadoopFileSystemClientSelfTest extends IgfsCommonAbstractTest
         igfsCfg.setMetaCacheName("replicated");
         igfsCfg.setName("igfs");
         igfsCfg.setBlockSize(512 * 1024);
-        igfsCfg.setIpcEndpointConfiguration(new HashMap<String, String>() {{
-            put("type", "tcp");
-            put("port", String.valueOf(DFLT_IPC_PORT));
-        }});
+
+        IgfsIpcEndpointConfiguration endpointCfg = new IgfsIpcEndpointConfiguration();
+
+        endpointCfg.setType(IgfsIpcEndpointType.TCP);
+        endpointCfg.setPort(DFLT_IPC_PORT);
+
+        igfsCfg.setIpcEndpointConfiguration(endpointCfg);
 
         cfg.setCacheConfiguration(cacheConfiguration());
         cfg.setFileSystemConfiguration(igfsCfg);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemHandshakeSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemHandshakeSelfTest.java b/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemHandshakeSelfTest.java
index 3b4c5c2..6502c93 100644
--- a/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemHandshakeSelfTest.java
+++ b/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemHandshakeSelfTest.java
@@ -22,7 +22,7 @@ import org.apache.hadoop.fs.FileSystem;
 import org.apache.hadoop.fs.*;
 import org.apache.ignite.*;
 import org.apache.ignite.configuration.*;
-import org.apache.ignite.hadoop.fs.v2.IgniteHadoopFileSystem;
+import org.apache.ignite.hadoop.fs.v2.*;
 import org.apache.ignite.internal.processors.igfs.*;
 import org.apache.ignite.internal.util.typedef.*;
 import org.apache.ignite.spi.communication.tcp.*;
@@ -33,7 +33,6 @@ import org.apache.ignite.testframework.*;
 
 import java.io.*;
 import java.net.*;
-import java.util.*;
 import java.util.concurrent.*;
 
 import static org.apache.ignite.cache.CacheAtomicityMode.*;
@@ -234,10 +233,13 @@ public class IgniteHadoopFileSystemHandshakeSelfTest extends IgfsCommonAbstractT
         igfsCfg.setName(dfltIgfsName ? null : IGFS_NAME);
         igfsCfg.setPrefetchBlocks(1);
         igfsCfg.setDefaultMode(PRIMARY);
-        igfsCfg.setIpcEndpointConfiguration(new HashMap<String, String>() {{
-            put("type", "tcp");
-            put("port", String.valueOf(DFLT_IPC_PORT));
-        }});
+
+        IgfsIpcEndpointConfiguration endpointCfg = new IgfsIpcEndpointConfiguration();
+
+        endpointCfg.setType(IgfsIpcEndpointType.TCP);
+        endpointCfg.setPort(DFLT_IPC_PORT);
+
+        igfsCfg.setIpcEndpointConfiguration(endpointCfg);
 
         igfsCfg.setManagementPort(-1);
         igfsCfg.setBlockSize(512 * 1024);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemIpcCacheSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemIpcCacheSelfTest.java b/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemIpcCacheSelfTest.java
index 135a488..aa1b083 100644
--- a/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemIpcCacheSelfTest.java
+++ b/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemIpcCacheSelfTest.java
@@ -72,10 +72,12 @@ public class IgniteHadoopFileSystemIpcCacheSelfTest extends IgfsCommonAbstractTe
         igfsCfg.setName("igfs");
         igfsCfg.setManagementPort(FileSystemConfiguration.DFLT_MGMT_PORT + cnt);
 
-        igfsCfg.setIpcEndpointConfiguration(new HashMap<String, String>() {{
-            put("type", "shmem");
-            put("port", String.valueOf(IpcSharedMemoryServerEndpoint.DFLT_IPC_PORT + cnt));
-        }});
+        IgfsIpcEndpointConfiguration endpointCfg = new IgfsIpcEndpointConfiguration();
+
+        endpointCfg.setType(IgfsIpcEndpointType.SHMEM);
+        endpointCfg.setPort(IpcSharedMemoryServerEndpoint.DFLT_IPC_PORT + cnt);
+
+        igfsCfg.setIpcEndpointConfiguration(endpointCfg);
 
         igfsCfg.setBlockSize(512 * 1024); // Together with group blocks mapper will yield 64M per node groups.
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemLoggerStateSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemLoggerStateSelfTest.java b/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemLoggerStateSelfTest.java
index 1f6a204..c671a40 100644
--- a/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemLoggerStateSelfTest.java
+++ b/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemLoggerStateSelfTest.java
@@ -33,7 +33,6 @@ import org.apache.ignite.spi.discovery.tcp.ipfinder.vm.*;
 import java.lang.reflect.*;
 import java.net.*;
 import java.nio.file.*;
-import java.util.*;
 
 import static org.apache.ignite.cache.CacheAtomicityMode.*;
 import static org.apache.ignite.cache.CacheMode.*;
@@ -82,10 +81,13 @@ public class IgniteHadoopFileSystemLoggerStateSelfTest extends IgfsCommonAbstrac
         igfsCfg.setName("igfs");
         igfsCfg.setBlockSize(512 * 1024);
         igfsCfg.setDefaultMode(PRIMARY);
-        igfsCfg.setIpcEndpointConfiguration(new HashMap<String, String>() {{
-            put("type", "tcp");
-            put("port", "10500");
-        }});
+
+        IgfsIpcEndpointConfiguration endpointCfg = new IgfsIpcEndpointConfiguration();
+
+        endpointCfg.setType(IgfsIpcEndpointType.TCP);
+        endpointCfg.setPort(10500);
+
+        igfsCfg.setIpcEndpointConfiguration(endpointCfg);
 
         CacheConfiguration cacheCfg = defaultCacheConfiguration();
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemLoopbackAbstractSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemLoopbackAbstractSelfTest.java b/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemLoopbackAbstractSelfTest.java
index e33cde7..0b27960 100644
--- a/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemLoopbackAbstractSelfTest.java
+++ b/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemLoopbackAbstractSelfTest.java
@@ -37,10 +37,12 @@ public abstract class IgniteHadoopFileSystemLoopbackAbstractSelfTest extends
     }
 
     /** {@inheritDoc} */
-    @Override protected Map<String, String> primaryIpcEndpointConfiguration(final String gridName) {
-        return new HashMap<String, String>() {{
-            put("type", "tcp");
-            put("port", String.valueOf(DFLT_IPC_PORT + getTestGridIndex(gridName)));
-        }};
+    @Override protected IgfsIpcEndpointConfiguration primaryIpcEndpointConfiguration(final String gridName) {
+        IgfsIpcEndpointConfiguration endpointCfg = new IgfsIpcEndpointConfiguration();
+
+        endpointCfg.setType(IgfsIpcEndpointType.TCP);
+        endpointCfg.setPort(DFLT_IPC_PORT + getTestGridIndex(gridName));
+
+        return endpointCfg;
     }
 }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemSecondaryModeSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemSecondaryModeSelfTest.java b/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemSecondaryModeSelfTest.java
index 3f20070..aef904e 100644
--- a/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemSecondaryModeSelfTest.java
+++ b/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemSecondaryModeSelfTest.java
@@ -24,6 +24,7 @@ import org.apache.ignite.configuration.*;
 import org.apache.ignite.hadoop.fs.*;
 import org.apache.ignite.hadoop.fs.v1.*;
 import org.apache.ignite.internal.processors.igfs.*;
+import org.apache.ignite.internal.util.ipc.shmem.*;
 import org.apache.ignite.internal.util.typedef.*;
 import org.apache.ignite.internal.util.typedef.internal.*;
 import org.apache.ignite.lang.*;
@@ -91,10 +92,13 @@ public class IgniteHadoopFileSystemSecondaryModeSelfTest extends IgfsCommonAbstr
         igfsCfg.setBlockSize(512 * 1024);
         igfsCfg.setDefaultMode(mode);
         igfsCfg.setPathModes(pathModes);
-        igfsCfg.setIpcEndpointConfiguration(new HashMap<String, String>() {{
-            put("type", "tcp");
-            put("port", "10500");
-        }});
+
+        IgfsIpcEndpointConfiguration endpointCfg = new IgfsIpcEndpointConfiguration();
+
+        endpointCfg.setType(IgfsIpcEndpointType.TCP);
+        endpointCfg.setPort(10500);
+
+        igfsCfg.setIpcEndpointConfiguration(endpointCfg);
 
         igfsCfg.setManagementPort(-1);
         igfsCfg.setSecondaryFileSystem(new IgniteHadoopIgfsSecondaryFileSystem(
@@ -158,10 +162,13 @@ public class IgniteHadoopFileSystemSecondaryModeSelfTest extends IgfsCommonAbstr
         igfsCfg.setName("igfs-secondary");
         igfsCfg.setBlockSize(512 * 1024);
         igfsCfg.setDefaultMode(PRIMARY);
-        igfsCfg.setIpcEndpointConfiguration(new HashMap<String, String>() {{
-            put("type", "tcp");
-            put("port", "11500");
-        }});
+
+        IgfsIpcEndpointConfiguration endpointCfg = new IgfsIpcEndpointConfiguration();
+
+        endpointCfg.setType(IgfsIpcEndpointType.TCP);
+        endpointCfg.setPort(11500);
+
+        igfsCfg.setIpcEndpointConfiguration(endpointCfg);
 
         CacheConfiguration cacheCfg = defaultCacheConfiguration();
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemShmemAbstractSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemShmemAbstractSelfTest.java b/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemShmemAbstractSelfTest.java
index 991045b..8ade0b1 100644
--- a/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemShmemAbstractSelfTest.java
+++ b/modules/hadoop/src/test/java/org/apache/ignite/igfs/IgniteHadoopFileSystemShmemAbstractSelfTest.java
@@ -42,11 +42,13 @@ public abstract class IgniteHadoopFileSystemShmemAbstractSelfTest extends Ignite
     }
 
     /** {@inheritDoc} */
-    @Override protected Map<String, String> primaryIpcEndpointConfiguration(final String gridName) {
-        return new HashMap<String, String>() {{
-            put("type", "shmem");
-            put("port", String.valueOf(DFLT_IPC_PORT + getTestGridIndex(gridName)));
-        }};
+    @Override protected IgfsIpcEndpointConfiguration primaryIpcEndpointConfiguration(final String gridName) {
+        IgfsIpcEndpointConfiguration endpointCfg = new IgfsIpcEndpointConfiguration();
+
+        endpointCfg.setType(IgfsIpcEndpointType.SHMEM);
+        endpointCfg.setPort(DFLT_IPC_PORT + getTestGridIndex(gridName));
+
+        return endpointCfg;
     }
 
     /**

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0f85dc97/modules/hadoop/src/test/java/org/apache/ignite/internal/processors/hadoop/HadoopPopularWordsTest.java
----------------------------------------------------------------------
diff --git a/modules/hadoop/src/test/java/org/apache/ignite/internal/processors/hadoop/HadoopPopularWordsTest.java b/modules/hadoop/src/test/java/org/apache/ignite/internal/processors/hadoop/HadoopPopularWordsTest.java
index a2f2ac3..4809254 100644
--- a/modules/hadoop/src/test/java/org/apache/ignite/internal/processors/hadoop/HadoopPopularWordsTest.java
+++ b/modules/hadoop/src/test/java/org/apache/ignite/internal/processors/hadoop/HadoopPopularWordsTest.java
@@ -173,14 +173,14 @@ public class HadoopPopularWordsTest {
      * @return Instance of the Hadoop MapRed job.
      * @throws IOException If failed.
      */
+    @SuppressWarnings("deprecation")
     private Job createConfigBasedHadoopJob() throws IOException {
         Job jobCfg = new Job();
 
         Configuration cfg = jobCfg.getConfiguration();
 
         // Use explicit configuration of distributed file system, if provided.
-        if (DFS_CFG != null)
-            cfg.addResource(U.resolveIgniteUrl(DFS_CFG));
+        cfg.addResource(U.resolveIgniteUrl(DFS_CFG));
 
         jobCfg.setJobName("HadoopPopularWordExample");
         jobCfg.setJarByClass(HadoopPopularWordsTest.class);


Mime
View raw message