You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ignite.apache.org by vo...@apache.org on 2015/06/16 10:21:11 UTC

[01/50] incubator-ignite git commit: ignite-389 Partition scan fallback test fixed

Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-gg-10411 3f20d124d -> 207e2c7b4


ignite-389 Partition scan fallback test fixed


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

Branch: refs/heads/ignite-gg-10411
Commit: 9fca6b5005a6f5ddd16af936c6445748b398ed39
Parents: 7e8f648
Author: agura <ag...@gridgain.com>
Authored: Tue Jun 9 14:42:49 2015 +0300
Committer: agura <ag...@gridgain.com>
Committed: Tue Jun 9 14:42:49 2015 +0300

----------------------------------------------------------------------
 ...CacheScanPartitionQueryFallbackSelfTest.java | 20 ++++++++++++++++----
 1 file changed, 16 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/9fca6b50/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/CacheScanPartitionQueryFallbackSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/CacheScanPartitionQueryFallbackSelfTest.java b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/CacheScanPartitionQueryFallbackSelfTest.java
index dfa7296..b7f5fa8 100644
--- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/CacheScanPartitionQueryFallbackSelfTest.java
+++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/CacheScanPartitionQueryFallbackSelfTest.java
@@ -31,6 +31,8 @@ import org.apache.ignite.lang.*;
 import org.apache.ignite.plugin.extensions.communication.*;
 import org.apache.ignite.spi.*;
 import org.apache.ignite.spi.communication.tcp.*;
+import org.apache.ignite.spi.discovery.tcp.*;
+import org.apache.ignite.spi.discovery.tcp.ipfinder.vm.*;
 import org.apache.ignite.testframework.junits.common.*;
 
 import java.util.*;
@@ -47,6 +49,9 @@ public class CacheScanPartitionQueryFallbackSelfTest extends GridCommonAbstractT
     /** Keys count. */
     private static final int KEYS_CNT = 5000;
 
+    /** Ip finder. */
+    private static final TcpDiscoveryVmIpFinder IP_FINDER = new TcpDiscoveryVmIpFinder(true);
+
     /** Backups. */
     private int backups;
 
@@ -75,6 +80,13 @@ public class CacheScanPartitionQueryFallbackSelfTest extends GridCommonAbstractT
     @Override protected IgniteConfiguration getConfiguration(String gridName) throws Exception {
         IgniteConfiguration cfg = super.getConfiguration(gridName);
 
+        cfg.setClientMode(clientMode);
+
+        TcpDiscoverySpi discoSpi = new TcpDiscoverySpi();
+        discoSpi.setIpFinder(IP_FINDER);
+        discoSpi.setForceServerMode(true);
+        cfg.setDiscoverySpi(discoSpi);
+
         cfg.setCommunicationSpi(commSpiFactory.create());
 
         CacheConfiguration ccfg = defaultCacheConfiguration();
@@ -85,8 +97,6 @@ public class CacheScanPartitionQueryFallbackSelfTest extends GridCommonAbstractT
 
         cfg.setCacheConfiguration(ccfg);
 
-        cfg.setClientMode(clientMode);
-
         return cfg;
     }
 
@@ -183,6 +193,7 @@ public class CacheScanPartitionQueryFallbackSelfTest extends GridCommonAbstractT
 
                 if (!test.get()) {
                     candidates.addAll(localPartitions(ignite1));
+
                     candidates.retainAll(localPartitions(ignite2));
                 }
 
@@ -195,8 +206,9 @@ public class CacheScanPartitionQueryFallbackSelfTest extends GridCommonAbstractT
                             awaitPartitionMapExchange();
 
                             if (!test.get()) {
-                                Set<Integer> parts = localPartitions(ignite1);
-                                candidates.removeAll(parts);
+                                candidates.removeAll(localPartitions(ignite1));
+
+                                F.retain(candidates, false, localPartitions(ignite2));
                             }
 
                             latch.countDown();


[14/50] incubator-ignite git commit: Merge remote-tracking branch 'remotes/origin/ignite-sprint-5' into ignite-998

Posted by vo...@apache.org.
Merge remote-tracking branch 'remotes/origin/ignite-sprint-5' into ignite-998


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

Branch: refs/heads/ignite-gg-10411
Commit: 4ab301d2f0505ee3a67978392827dcccea60a58b
Parents: 46e6c48 89a4f7c
Author: sboikov <sb...@gridgain.com>
Authored: Thu Jun 11 10:19:02 2015 +0300
Committer: sboikov <sb...@gridgain.com>
Committed: Thu Jun 11 10:19:02 2015 +0300

----------------------------------------------------------------------
 DEVNOTES.txt                                    |   6 +
 assembly/dependencies-fabric.xml                |   1 +
 examples/pom.xml                                |  34 ++
 .../client/memcache/MemcacheRestExample.java    |  32 +-
 modules/core/pom.xml                            |   1 -
 .../java/org/apache/ignite/IgniteCache.java     |  25 +-
 .../apache/ignite/IgniteSystemProperties.java   |   3 +
 .../apache/ignite/cache/query/ScanQuery.java    |  45 +-
 .../configuration/CacheConfiguration.java       |   1 -
 .../affinity/GridAffinityAssignmentCache.java   |   8 +-
 .../processors/cache/GridCacheAdapter.java      |  15 +-
 .../GridCachePartitionExchangeManager.java      |   2 +-
 .../processors/cache/GridCacheProcessor.java    |  30 +-
 .../processors/cache/GridCacheSwapManager.java  |  55 ++-
 .../processors/cache/IgniteCacheProxy.java      |  11 +-
 .../processors/cache/IgniteInternalCache.java   |  27 +-
 .../processors/cache/QueryCursorImpl.java       |  23 +-
 .../distributed/dht/GridDhtLocalPartition.java  |   7 +
 .../processors/cache/query/CacheQuery.java      |   2 +-
 .../query/GridCacheDistributedQueryManager.java |   3 +
 .../cache/query/GridCacheQueryAdapter.java      | 147 ++++++-
 .../cache/query/GridCacheQueryManager.java      | 209 ++++++----
 .../cache/query/GridCacheQueryRequest.java      |  47 ++-
 .../processors/cache/query/QueryCursorEx.java   |   8 +
 .../datastructures/GridCacheSetImpl.java        |   4 +-
 .../processors/query/GridQueryIndexing.java     |   4 +-
 .../processors/query/GridQueryProcessor.java    |  18 +-
 .../service/GridServiceProcessor.java           |   2 +-
 .../ignite/internal/util/GridJavaProcess.java   |   2 +-
 .../ignite/internal/util/IgniteUtils.java       |   4 +-
 .../shmem/IpcSharedMemoryClientEndpoint.java    |   2 +-
 .../ipc/shmem/IpcSharedMemoryNativeLoader.java  | 151 ++++++-
 .../shmem/IpcSharedMemoryServerEndpoint.java    |   2 +-
 .../util/nio/GridShmemCommunicationClient.java  | 146 +++++++
 .../communication/tcp/TcpCommunicationSpi.java  | 415 ++++++++++++++++++-
 .../tcp/TcpCommunicationSpiMBean.java           |   8 +
 .../spi/discovery/tcp/TcpDiscoverySpi.java      |   2 +-
 .../RoundRobinGlobalLoadBalancer.java           |   2 +-
 .../cache/GridCacheAbstractFullApiSelfTest.java |  15 +
 .../cache/IgniteDynamicCacheStartSelfTest.java  |  19 +
 .../distributed/IgniteCacheManyClientsTest.java | 169 ++++++++
 .../IgniteCacheMessageRecoveryAbstractTest.java |   1 +
 ...achePartitionedPreloadLifecycleSelfTest.java |   2 +-
 ...CacheReplicatedPreloadLifecycleSelfTest.java |   6 +-
 .../GridCacheSwapScanQueryAbstractSelfTest.java | 112 +++--
 .../ipc/shmem/IgfsSharedMemoryTestServer.java   |   2 +
 .../IpcSharedMemoryCrashDetectionSelfTest.java  |   2 +-
 .../ipc/shmem/IpcSharedMemorySpaceSelfTest.java |   2 +-
 .../ipc/shmem/IpcSharedMemoryUtilsSelfTest.java |   2 +-
 .../LoadWithCorruptedLibFileTestRunner.java     |   2 +-
 .../IpcSharedMemoryBenchmarkReader.java         |   2 +-
 .../IpcSharedMemoryBenchmarkWriter.java         |   2 +-
 .../communication/GridIoManagerBenchmark0.java  |   1 +
 .../spi/GridTcpSpiForwardingSelfTest.java       |   1 +
 .../GridTcpCommunicationSpiAbstractTest.java    |  13 +
 ...mmunicationSpiConcurrentConnectSelfTest.java |   4 +-
 ...cpCommunicationSpiMultithreadedSelfTest.java |  21 +-
 ...pCommunicationSpiMultithreadedShmemTest.java |  28 ++
 ...dTcpCommunicationSpiRecoveryAckSelfTest.java |   1 +
 ...GridTcpCommunicationSpiRecoverySelfTest.java |   1 +
 .../GridTcpCommunicationSpiShmemSelfTest.java   |  38 ++
 .../tcp/GridTcpCommunicationSpiTcpSelfTest.java |   7 +
 .../ignite/testframework/GridTestUtils.java     |   2 +-
 .../testsuites/IgniteCacheTestSuite4.java       |   2 +
 .../IgniteSpiCommunicationSelfTestSuite.java    |   2 +
 modules/hadoop/pom.xml                          |   1 +
 .../HadoopIgfs20FileSystemAbstractSelfTest.java |  13 +
 ...oopSecondaryFileSystemConfigurationTest.java |  14 +
 ...IgniteHadoopFileSystemHandshakeSelfTest.java |   7 +
 .../IgniteHadoopFileSystemIpcCacheSelfTest.java |   7 +
 .../hadoop/HadoopAbstractSelfTest.java          |   7 +
 .../processors/query/h2/IgniteH2Indexing.java   |  44 +-
 .../h2/twostep/GridReduceQueryExecutor.java     |   8 +-
 ...CacheScanPartitionQueryFallbackSelfTest.java | 408 ++++++++++++++++++
 .../cache/GridCacheCrossCacheQuerySelfTest.java |  12 +-
 .../cache/IgniteCacheAbstractQuerySelfTest.java |  77 +++-
 .../IgniteCacheQuerySelfTestSuite.java          |   2 +
 modules/scalar-2.10/README.txt                  |   4 +
 modules/scalar-2.10/licenses/apache-2.0.txt     | 202 +++++++++
 .../scalar-2.10/licenses/scala-bsd-license.txt  |  18 +
 modules/scalar-2.10/pom.xml                     | 197 +++++++++
 modules/spark-2.10/README.txt                   |   4 +
 modules/spark-2.10/licenses/apache-2.0.txt      | 202 +++++++++
 .../spark-2.10/licenses/scala-bsd-license.txt   |  18 +
 modules/spark-2.10/pom.xml                      | 120 ++++++
 modules/spark/README.txt                        |   8 +
 modules/spark/licenses/apache-2.0.txt           | 202 +++++++++
 modules/spark/licenses/scala-bsd-license.txt    |  18 +
 modules/spark/pom.xml                           | 114 +++++
 .../org/apache/ignite/spark/IgniteContext.scala | 119 ++++++
 .../org/apache/ignite/spark/IgniteRDD.scala     | 244 +++++++++++
 .../apache/ignite/spark/JavaIgniteContext.scala |  63 +++
 .../org/apache/ignite/spark/JavaIgniteRDD.scala |  99 +++++
 .../ignite/spark/impl/IgniteAbstractRDD.scala   |  39 ++
 .../ignite/spark/impl/IgnitePartition.scala     |  24 ++
 .../ignite/spark/impl/IgniteQueryIterator.scala |  27 ++
 .../apache/ignite/spark/impl/IgniteSqlRDD.scala |  41 ++
 .../spark/impl/JavaIgniteAbstractRDD.scala      |  34 ++
 .../ignite/spark/JavaIgniteRDDSelfTest.java     | 298 +++++++++++++
 .../scala/org/apache/ignite/spark/Entity.scala  |  28 ++
 .../org/apache/ignite/spark/IgniteRddSpec.scala | 231 +++++++++++
 modules/visor-console-2.10/README.txt           |   4 +
 modules/visor-console-2.10/pom.xml              | 174 ++++++++
 parent/pom.xml                                  |   4 +
 pom.xml                                         |  20 +-
 105 files changed, 4827 insertions(+), 292 deletions(-)
----------------------------------------------------------------------



[12/50] incubator-ignite git commit: #IGNITE-389 - Minor

Posted by vo...@apache.org.
#IGNITE-389 - Minor


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

Branch: refs/heads/ignite-gg-10411
Commit: f149c8205191a5437bf6532807c2a1b275b67b88
Parents: 9926fb8
Author: Alexey Goncharuk <ag...@gridgain.com>
Authored: Wed Jun 10 15:58:58 2015 -0700
Committer: Alexey Goncharuk <ag...@gridgain.com>
Committed: Wed Jun 10 15:58:58 2015 -0700

----------------------------------------------------------------------
 .../internal/util/ipc/shmem/IpcSharedMemoryNativeLoader.java      | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/f149c820/modules/core/src/main/java/org/apache/ignite/internal/util/ipc/shmem/IpcSharedMemoryNativeLoader.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/util/ipc/shmem/IpcSharedMemoryNativeLoader.java b/modules/core/src/main/java/org/apache/ignite/internal/util/ipc/shmem/IpcSharedMemoryNativeLoader.java
index 8c345f8..5b3274d 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/util/ipc/shmem/IpcSharedMemoryNativeLoader.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/util/ipc/shmem/IpcSharedMemoryNativeLoader.java
@@ -142,7 +142,8 @@ public class IpcSharedMemoryNativeLoader {
                 return;
 
             try {
-                U.quietAndWarn(log, "Failed to load 'igniteshmem' library from classpath. Will try to load it from IGNITE_HOME.");
+                if (log != null)
+                    LT.warn(log, null, "Failed to load 'igniteshmem' library from classpath. Will try to load it from IGNITE_HOME.");
 
                 String igniteHome = X.resolveIgniteHome();
 


[50/50] incubator-ignite git commit: Merge remote-tracking branch 'remotes/origin/ignite-sprint-6' into ignite-gg-10411

Posted by vo...@apache.org.
Merge remote-tracking branch 'remotes/origin/ignite-sprint-6' into ignite-gg-10411


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

Branch: refs/heads/ignite-gg-10411
Commit: 207e2c7b4044e50716af84a2291a4a2d65cfe4f2
Parents: 3f20d12 f4b1123
Author: ptupitsyn <pt...@gridgain.com>
Authored: Tue Jun 16 11:11:36 2015 +0300
Committer: ptupitsyn <pt...@gridgain.com>
Committed: Tue Jun 16 11:11:36 2015 +0300

----------------------------------------------------------------------
 RELEASE_NOTES.txt                               |  12 +
 .../apache/ignite/cache/query/ScanQuery.java    |  23 +-
 .../ignite/internal/GridKernalContextImpl.java  |   5 +-
 .../apache/ignite/internal/IgniteKernal.java    |  22 +-
 .../internal/MarshallerContextAdapter.java      |  18 +-
 .../ignite/internal/MarshallerContextImpl.java  |  14 +-
 .../GridClientOptimizedMarshaller.java          |   5 +
 .../discovery/GridDiscoveryManager.java         |   9 +-
 .../processors/cache/GridCacheProcessor.java    |  11 +-
 .../dht/preloader/GridDhtPreloader.java         |   2 +-
 .../transactions/IgniteTxLocalAdapter.java      |   6 +-
 .../datastructures/DataStructuresProcessor.java |  67 ++-
 .../plugin/IgnitePluginProcessor.java           |  16 +-
 .../rest/client/message/GridRouterRequest.java  |  18 +
 .../rest/client/message/GridRouterResponse.java |  18 +
 .../org/apache/ignite/spi/IgniteSpiAdapter.java |  28 +-
 .../communication/tcp/TcpCommunicationSpi.java  |   2 +-
 .../ignite/spi/discovery/tcp/ClientImpl.java    | 439 ++++++++++++-------
 .../ignite/spi/discovery/tcp/ServerImpl.java    | 221 ++++++----
 .../spi/discovery/tcp/TcpDiscoveryImpl.java     |  66 +++
 .../ipfinder/TcpDiscoveryIpFinderAdapter.java   |  34 +-
 .../TcpDiscoveryMulticastIpFinder.java          |  19 +-
 .../messages/TcpDiscoveryAbstractMessage.java   |  10 +-
 .../cache/CacheClientStoreSelfTest.java         | 228 ++++++++++
 ...acheReadOnlyTransactionalClientSelfTest.java | 327 --------------
 .../cache/GridCachePutAllFailoverSelfTest.java  |   5 -
 .../IgniteCacheP2pUnmarshallingTxErrorTest.java |  14 +-
 .../distributed/IgniteCacheManyClientsTest.java | 142 +++++-
 .../dht/GridCacheColocatedFailoverSelfTest.java |   5 -
 .../GridCachePartitionedFailoverSelfTest.java   |   5 -
 .../GridCacheReplicatedFailoverSelfTest.java    |   5 -
 ...CacheClientWriteBehindStoreAbstractTest.java | 104 +++++
 ...teCacheClientWriteBehindStoreAtomicTest.java |  38 ++
 .../IgnteCacheClientWriteBehindStoreTxTest.java |  32 ++
 .../DataStreamProcessorSelfTest.java            |   3 +-
 .../marshaller/MarshallerContextTestImpl.java   |  18 +
 .../tcp/TcpClientDiscoverySpiSelfTest.java      |  73 ++-
 .../junits/GridTestKernalContext.java           |   1 +
 .../testsuites/IgniteCacheTestSuite4.java       |   6 +-
 .../IgniteCacheWriteBehindTestSuite.java        |   2 +
 .../testsuites/IgniteKernalSelfTestSuite.java   |   2 +-
 .../ignite/tools/classgen/ClassesGenerator.java |  30 +-
 42 files changed, 1405 insertions(+), 700 deletions(-)
----------------------------------------------------------------------



[48/50] incubator-ignite git commit: Merge remote-tracking branch 'remotes/origin/ignite-1009-v4' into ignite-sprint-6

Posted by vo...@apache.org.
Merge remote-tracking branch 'remotes/origin/ignite-1009-v4' into ignite-sprint-6


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

Branch: refs/heads/ignite-gg-10411
Commit: d28fea0b9f30bf09c37b09218fa41fe819b85c13
Parents: 5d8a5e6 7c51a14
Author: sboikov <sb...@gridgain.com>
Authored: Tue Jun 16 09:56:47 2015 +0300
Committer: sboikov <sb...@gridgain.com>
Committed: Tue Jun 16 09:56:47 2015 +0300

----------------------------------------------------------------------
 .../processors/cache/GridCacheProcessor.java    |  11 +-
 .../transactions/IgniteTxLocalAdapter.java      |   6 +-
 .../cache/CacheClientStoreSelfTest.java         | 228 +++++++++++++
 ...acheReadOnlyTransactionalClientSelfTest.java | 327 -------------------
 ...CacheClientWriteBehindStoreAbstractTest.java | 104 ++++++
 ...teCacheClientWriteBehindStoreAtomicTest.java |  38 +++
 .../IgnteCacheClientWriteBehindStoreTxTest.java |  32 ++
 .../testsuites/IgniteCacheTestSuite4.java       |   2 +-
 .../IgniteCacheWriteBehindTestSuite.java        |   2 +
 9 files changed, 411 insertions(+), 339 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/d28fea0b/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
----------------------------------------------------------------------
diff --cc modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
index fed5efe,83a30bd..d155330
--- a/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
+++ b/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
@@@ -134,8 -134,10 +134,8 @@@ public class IgniteCacheTestSuite4 exte
  
          suite.addTestSuite(CacheJdbcStoreSessionListenerSelfTest.class);
  
-         suite.addTestSuite(CacheReadOnlyTransactionalClientSelfTest.class);
+         suite.addTestSuite(CacheClientStoreSelfTest.class);
  
 -        suite.addTestSuite(IgniteCacheManyClientsTest.class);
 -
          suite.addTestSuite(IgniteStartCacheInTransactionSelfTest.class);
          suite.addTestSuite(IgniteStartCacheInTransactionAtomicSelfTest.class);
  


[41/50] incubator-ignite git commit: Merge remote-tracking branch 'remotes/origin/ignite-sprint-6' into ignite-883-1

Posted by vo...@apache.org.
Merge remote-tracking branch 'remotes/origin/ignite-sprint-6' into ignite-883-1


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

Branch: refs/heads/ignite-gg-10411
Commit: ca7032ea72410d14f6d376abca1a801495207b14
Parents: f115c04 2707194
Author: sboikov <sb...@gridgain.com>
Authored: Fri Jun 12 18:47:29 2015 +0300
Committer: sboikov <sb...@gridgain.com>
Committed: Fri Jun 12 18:47:29 2015 +0300

----------------------------------------------------------------------
 RELEASE_NOTES.txt | 2 ++
 1 file changed, 2 insertions(+)
----------------------------------------------------------------------



[07/50] incubator-ignite git commit: ignite-998

Posted by vo...@apache.org.
ignite-998


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

Branch: refs/heads/ignite-gg-10411
Commit: 46e6c48ee59a3837c06564d2431caabc55cf9a63
Parents: c47438e
Author: sboikov <sb...@gridgain.com>
Authored: Wed Jun 10 15:33:01 2015 +0300
Committer: sboikov <sb...@gridgain.com>
Committed: Wed Jun 10 15:33:01 2015 +0300

----------------------------------------------------------------------
 .../discovery/tcp/TcpClientDiscoverySpiSelfTest.java    | 12 ++++++++++++
 1 file changed, 12 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/46e6c48e/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpiSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpiSelfTest.java
index ece898d..55a14e4 100644
--- a/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpiSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpiSelfTest.java
@@ -1136,6 +1136,8 @@ public class TcpClientDiscoverySpiSelfTest extends GridCommonAbstractTest {
      * @param clientCnt Number of client nodes.
      */
     private void checkNodes(int srvCnt, int clientCnt) {
+        long topVer = -1;
+
         for (int i = 0; i < srvCnt; i++) {
             Ignite g = G.ignite("server-" + i);
 
@@ -1144,6 +1146,11 @@ public class TcpClientDiscoverySpiSelfTest extends GridCommonAbstractTest {
             assertFalse(g.cluster().localNode().isClient());
 
             checkRemoteNodes(g, srvCnt + clientCnt - 1);
+
+            if (topVer < 0)
+                topVer = g.cluster().topologyVersion();
+            else
+                assertEquals(topVer, g.cluster().topologyVersion());
         }
 
         for (int i = 0; i < clientCnt; i++) {
@@ -1156,6 +1163,11 @@ public class TcpClientDiscoverySpiSelfTest extends GridCommonAbstractTest {
             assertTrue(g.cluster().localNode().isClient());
 
             checkRemoteNodes(g, srvCnt + clientCnt - 1);
+
+            if (topVer < 0)
+                topVer = g.cluster().topologyVersion();
+            else
+                assertEquals(topVer, g.cluster().topologyVersion());
         }
     }
 


[20/50] incubator-ignite git commit: Merge remote-tracking branch 'remotes/origin/ignite-sprint-5' into ignite-883

Posted by vo...@apache.org.
Merge remote-tracking branch 'remotes/origin/ignite-sprint-5' into ignite-883


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

Branch: refs/heads/ignite-gg-10411
Commit: 58fe3edfdb68fea7b045b3158dbfab9f9228cae7
Parents: de0d61f 4375529
Author: sboikov <sb...@gridgain.com>
Authored: Thu Jun 11 17:42:00 2015 +0300
Committer: sboikov <sb...@gridgain.com>
Committed: Thu Jun 11 17:42:00 2015 +0300

----------------------------------------------------------------------
 idea/ignite_codeStyle.xml                       | 147 +++++++++++++++++++
 .../apache/ignite/cache/query/ScanQuery.java    |   5 +-
 .../ignite/spi/discovery/tcp/ServerImpl.java    |  38 +----
 .../tcp/TcpClientDiscoverySpiSelfTest.java      | 114 +++++++++++++-
 parent/pom.xml                                  |   1 +
 5 files changed, 267 insertions(+), 38 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/58fe3edf/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java
----------------------------------------------------------------------


[28/50] incubator-ignite git commit: Fixed test. Cache doesn't start in transaction.

Posted by vo...@apache.org.
Fixed test. Cache doesn't start in transaction.


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

Branch: refs/heads/ignite-gg-10411
Commit: e158c90fe58082e00d97f26c5bb3ae450906fc6a
Parents: fe1750d
Author: nikolay_tikhonov <nt...@gridgain.com>
Authored: Fri Jun 12 17:11:27 2015 +0300
Committer: nikolay_tikhonov <nt...@gridgain.com>
Committed: Fri Jun 12 17:11:27 2015 +0300

----------------------------------------------------------------------
 .../cache/IgniteCacheP2pUnmarshallingTxErrorTest.java | 14 ++++++++++----
 1 file changed, 10 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/e158c90f/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheP2pUnmarshallingTxErrorTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheP2pUnmarshallingTxErrorTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheP2pUnmarshallingTxErrorTest.java
index a4e2753..017f7db 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheP2pUnmarshallingTxErrorTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheP2pUnmarshallingTxErrorTest.java
@@ -50,9 +50,12 @@ public class IgniteCacheP2pUnmarshallingTxErrorTest extends IgniteCacheP2pUnmars
      * Sends put with optimistic lock and handles fail.
      */
     protected void failOptimistic() {
-        try (Transaction tx = grid(0).transactions().txStart(TransactionConcurrency.OPTIMISTIC, TransactionIsolation.REPEATABLE_READ)) {
+        IgniteCache<Object, Object> cache = jcache(0);
 
-            jcache(0).put(new TestKey(String.valueOf(++key)), "");
+        try (Transaction tx = grid(0).transactions().txStart(TransactionConcurrency.OPTIMISTIC,
+            TransactionIsolation.REPEATABLE_READ)) {
+
+            cache.put(new TestKey(String.valueOf(++key)), "");
 
             tx.commit();
 
@@ -69,9 +72,12 @@ public class IgniteCacheP2pUnmarshallingTxErrorTest extends IgniteCacheP2pUnmars
      * Sends put with pessimistic lock and handles fail.
      */
     protected void failPessimictic() {
-        try (Transaction tx = grid(0).transactions().txStart(TransactionConcurrency.PESSIMISTIC, TransactionIsolation.REPEATABLE_READ)) {
+        IgniteCache<Object, Object> cache = jcache(0);
+
+        try (Transaction tx = grid(0).transactions().txStart(TransactionConcurrency.PESSIMISTIC,
+            TransactionIsolation.REPEATABLE_READ)) {
 
-            jcache(0).put(new TestKey(String.valueOf(++key)), "");
+            cache.put(new TestKey(String.valueOf(++key)), "");
 
             assert false : "p2p marshalling failed, but error response was not sent";
         }


[39/50] incubator-ignite git commit: ignite-1007 Race in data structures processor

Posted by vo...@apache.org.
ignite-1007 Race in data structures processor


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

Branch: refs/heads/ignite-gg-10411
Commit: 811872ce692666fe8c77235f175b7ec15f717d30
Parents: 5160088
Author: agura <ag...@gridgain.com>
Authored: Fri Jun 12 18:36:58 2015 +0300
Committer: agura <ag...@gridgain.com>
Committed: Fri Jun 12 18:36:58 2015 +0300

----------------------------------------------------------------------
 .../datastructures/DataStructuresProcessor.java | 67 +++++++++++++++++++-
 1 file changed, 64 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/811872ce/modules/core/src/main/java/org/apache/ignite/internal/processors/datastructures/DataStructuresProcessor.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/datastructures/DataStructuresProcessor.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/datastructures/DataStructuresProcessor.java
index aa3bfe2..473a2ac 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/datastructures/DataStructuresProcessor.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/datastructures/DataStructuresProcessor.java
@@ -67,6 +67,12 @@ public final class DataStructuresProcessor extends GridProcessorAdapter {
     /** */
     private static final long RETRY_DELAY = 1;
 
+    /** Initialization latch. */
+    private final CountDownLatch initLatch = new CountDownLatch(1);
+
+    /** Initialization failed flag. */
+    private boolean initFailed;
+
     /** Cache contains only {@code GridCacheInternal,GridCacheInternal}. */
     private IgniteInternalCache<GridCacheInternal, GridCacheInternal> dsView;
 
@@ -145,6 +151,8 @@ public final class DataStructuresProcessor extends GridProcessorAdapter {
 
             dsCacheCtx = atomicsCache.context();
         }
+
+        initLatch.countDown();
     }
 
     /**
@@ -167,6 +175,12 @@ public final class DataStructuresProcessor extends GridProcessorAdapter {
     @Override public void onKernalStop(boolean cancel) {
         super.onKernalStop(cancel);
 
+        if (initLatch.getCount() > 0) {
+            initFailed = true;
+            
+            initLatch.countDown();
+        }
+
         if (qryId != null)
             dsCacheCtx.continuousQueries().cancelInternalQuery(qryId);
     }
@@ -187,6 +201,8 @@ public final class DataStructuresProcessor extends GridProcessorAdapter {
     {
         A.notNull(name, "name");
 
+        awaitInitialization();
+
         checkAtomicsConfiguration();
 
         startQuery();
@@ -277,6 +293,8 @@ public final class DataStructuresProcessor extends GridProcessorAdapter {
     public final void removeSequence(final String name) throws IgniteCheckedException {
         assert name != null;
 
+        awaitInitialization();
+
         checkAtomicsConfiguration();
 
         removeDataStructure(new IgniteCallable<Void>() {
@@ -315,6 +333,8 @@ public final class DataStructuresProcessor extends GridProcessorAdapter {
         final boolean create) throws IgniteCheckedException {
         A.notNull(name, "name");
 
+        awaitInitialization();
+
         checkAtomicsConfiguration();
 
         startQuery();
@@ -431,6 +451,8 @@ public final class DataStructuresProcessor extends GridProcessorAdapter {
         assert name != null;
         assert dsCacheCtx != null;
 
+        awaitInitialization();
+
         removeDataStructure(new IgniteCallable<Void>() {
             @Override public Void call() throws Exception {
                 dsCacheCtx.gate().enter();
@@ -520,6 +542,8 @@ public final class DataStructuresProcessor extends GridProcessorAdapter {
     {
         A.notNull(name, "name");
 
+        awaitInitialization();
+
         checkAtomicsConfiguration();
 
         startQuery();
@@ -585,6 +609,8 @@ public final class DataStructuresProcessor extends GridProcessorAdapter {
         assert name != null;
         assert dsCacheCtx != null;
 
+        awaitInitialization();
+
         removeDataStructure(new IgniteCallable<Void>() {
             @Override public Void call() throws Exception {
                 dsCacheCtx.gate().enter();
@@ -623,6 +649,8 @@ public final class DataStructuresProcessor extends GridProcessorAdapter {
         final S initStamp, final boolean create) throws IgniteCheckedException {
         A.notNull(name, "name");
 
+        awaitInitialization();
+
         checkAtomicsConfiguration();
 
         startQuery();
@@ -688,6 +716,8 @@ public final class DataStructuresProcessor extends GridProcessorAdapter {
         assert name != null;
         assert dsCacheCtx != null;
 
+        awaitInitialization();
+
         removeDataStructure(new IgniteCallable<Void>() {
             @Override public Void call() throws Exception {
                 dsCacheCtx.gate().enter();
@@ -725,6 +755,8 @@ public final class DataStructuresProcessor extends GridProcessorAdapter {
         throws IgniteCheckedException {
         A.notNull(name, "name");
 
+        awaitInitialization();
+
         String cacheName = null;
 
         if (cfg != null) {
@@ -801,6 +833,8 @@ public final class DataStructuresProcessor extends GridProcessorAdapter {
         assert name != null;
         assert cctx != null;
 
+        awaitInitialization();
+
         IgniteCallable<GridCacheQueueHeader> rmv = new IgniteCallable<GridCacheQueueHeader>() {
             @Override public GridCacheQueueHeader call() throws Exception {
                 return (GridCacheQueueHeader)retryRemove(cctx.cache(), new GridCacheQueueHeaderKey(name));
@@ -837,6 +871,8 @@ public final class DataStructuresProcessor extends GridProcessorAdapter {
         boolean create)
         throws IgniteCheckedException
     {
+        awaitInitialization();
+
         Map<String, DataStructureInfo> dsMap = utilityCache.get(DATA_STRUCTURES_KEY);
 
         if (!create && (dsMap == null || !dsMap.containsKey(dsInfo.name)))
@@ -887,6 +923,24 @@ public final class DataStructuresProcessor extends GridProcessorAdapter {
     }
 
     /**
+     * Awaits for processor initialization.
+     */
+    private void awaitInitialization() {
+        if (initLatch.getCount() > 0) {
+            try {
+                U.await(initLatch);
+
+                if (initFailed)
+                    throw new IllegalStateException("Failed to initialize data structures processor.");
+            }
+            catch (IgniteInterruptedCheckedException e) {
+                throw new IllegalStateException("Failed to initialize data structures processor " +
+                    "(thread has been interrupted).", e);
+            }
+        }
+    }
+
+    /**
      * @param dsMap Map with data structure information.
      * @param info New data structure information.
      * @param create Create flag.
@@ -930,6 +984,8 @@ public final class DataStructuresProcessor extends GridProcessorAdapter {
     {
         A.notNull(name, "name");
 
+        awaitInitialization();
+
         if (create)
             A.ensure(cnt >= 0, "count can not be negative");
 
@@ -997,9 +1053,10 @@ public final class DataStructuresProcessor extends GridProcessorAdapter {
         assert name != null;
         assert dsCacheCtx != null;
 
+        awaitInitialization();
+
         removeDataStructure(new IgniteCallable<Void>() {
-            @Override
-            public Void call() throws Exception {
+            @Override public Void call() throws Exception {
                 GridCacheInternal key = new GridCacheInternalKeyImpl(name);
 
                 dsCacheCtx.gate().enter();
@@ -1169,6 +1226,8 @@ public final class DataStructuresProcessor extends GridProcessorAdapter {
         throws IgniteCheckedException {
         A.notNull(name, "name");
 
+        awaitInitialization();
+
         String cacheName = null;
 
         if (cfg != null)
@@ -1196,6 +1255,8 @@ public final class DataStructuresProcessor extends GridProcessorAdapter {
         assert name != null;
         assert cctx != null;
 
+        awaitInitialization();
+
         IgniteCallable<GridCacheSetHeader> rmv = new IgniteCallable<GridCacheSetHeader>() {
             @Override public GridCacheSetHeader call() throws Exception {
                 return (GridCacheSetHeader)retryRemove(cctx.cache(), new GridCacheSetHeaderKey(name));
@@ -1326,7 +1387,7 @@ public final class DataStructuresProcessor extends GridProcessorAdapter {
     /**
      *
      */
-    static enum DataStructureType {
+    enum DataStructureType {
         /** */
         ATOMIC_LONG(IgniteAtomicLong.class.getSimpleName()),
 


[34/50] incubator-ignite git commit: Merge remote-tracking branch 'remotes/origin/ignite-883' into ignite-883-1

Posted by vo...@apache.org.
Merge remote-tracking branch 'remotes/origin/ignite-883' into ignite-883-1

Conflicts:
	modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
	modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryManager.java
	modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java
	modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java
	modules/core/src/test/java/org/apache/ignite/internal/processors/cache/query/GridCacheSwapScanQueryAbstractSelfTest.java
	modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpiSelfTest.java
	modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
	modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheCrossCacheQuerySelfTest.java
	modules/scalar-2.10/pom.xml
	modules/spark-2.10/pom.xml
	modules/spark/pom.xml
	modules/visor-console-2.10/pom.xml


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

Branch: refs/heads/ignite-gg-10411
Commit: 65db72eb4a731e4b459ec0686f1741ef4ade13ab
Parents: 5160088 8870a17
Author: sboikov <sb...@gridgain.com>
Authored: Fri Jun 12 17:55:08 2015 +0300
Committer: sboikov <sb...@gridgain.com>
Committed: Fri Jun 12 17:55:08 2015 +0300

----------------------------------------------------------------------
 .../apache/ignite/cache/query/ScanQuery.java    |  23 +
 .../apache/ignite/internal/IgniteKernal.java    |   1 -
 .../discovery/GridDiscoveryManager.java         |   9 +-
 .../dht/preloader/GridDhtPreloader.java         |   2 +-
 .../org/apache/ignite/spi/IgniteSpiAdapter.java |  28 +-
 .../communication/tcp/TcpCommunicationSpi.java  |   2 +-
 .../ignite/spi/discovery/tcp/ClientImpl.java    | 439 ++++++++++++-------
 .../ignite/spi/discovery/tcp/ServerImpl.java    | 223 ++++++----
 .../spi/discovery/tcp/TcpDiscoveryImpl.java     |  66 +++
 .../ipfinder/TcpDiscoveryIpFinderAdapter.java   |  34 +-
 .../TcpDiscoveryMulticastIpFinder.java          |  19 +-
 .../messages/TcpDiscoveryAbstractMessage.java   |  10 +-
 .../distributed/IgniteCacheManyClientsTest.java | 138 +++++-
 .../tcp/TcpClientDiscoverySpiSelfTest.java      |  73 ++-
 .../testsuites/IgniteCacheTestSuite4.java       |   2 +
 15 files changed, 774 insertions(+), 295 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65db72eb/modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
----------------------------------------------------------------------
diff --cc modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
index e6b69bc,11a8c84..90000e8
--- a/modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
+++ b/modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
@@@ -99,23 -99,26 +99,46 @@@ public final class ScanQuery<K, V> exte
      /**
       * Gets partition number over which this query should iterate. Will return {@code null} if partition was not
       * set. In this case query will iterate over all partitions in the cache.
+      *
+      * @return Partition number or {@code null}.
+      */
+     @Nullable public Integer getPartition() {
+         return part;
+     }
+ 
+     /**
+      * Sets partition number over which this query should iterate. If {@code null}, query will iterate over
+      * all partitions in the cache. Must be in the range [0, N) where N is partition number in the cache.
+      *
+      * @param part Partition number over which this query should iterate.
+      * @return {@code this} for chaining.
+      */
+     public ScanQuery<K, V> setPartition(@Nullable Integer part) {
+         this.part = part;
+ 
+         return this;
+     }
+ 
++    /**
++     * Gets partition number over which this query should iterate. Will return {@code null} if partition was not
++     * set. In this case query will iterate over all partitions in the cache.
 +     *
 +     * @return Partition number or {@code null}.
 +     */
 +    @Nullable public Integer getPartition() {
 +        return part;
 +    }
 +
 +    /**
 +     * Sets partition number over which this query should iterate. If {@code null}, query will iterate over
 +     * all partitions in the cache. Must be in the range [0, N) where N is partition number in the cache.
 +     *
 +     * @param part Partition number over which this query should iterate.
 +     */
 +    public void setPartition(@Nullable Integer part) {
 +        this.part = part;
 +    }
 +
      /** {@inheritDoc} */
      @Override public ScanQuery<K, V> setPageSize(int pageSize) {
          return (ScanQuery<K, V>)super.setPageSize(pageSize);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65db72eb/modules/core/src/main/java/org/apache/ignite/internal/IgniteKernal.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65db72eb/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/65db72eb/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
----------------------------------------------------------------------
diff --cc modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
index c598e38,ed9fc9a..7fa038c
--- a/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
+++ b/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
@@@ -138,9 -140,6 +138,11 @@@ public class IgniteCacheTestSuite4 exte
  
          suite.addTestSuite(IgniteCacheManyClientsTest.class);
  
 +        suite.addTestSuite(IgniteStartCacheInTransactionSelfTest.class);
 +        suite.addTestSuite(IgniteStartCacheInTransactionAtomicSelfTest.class);
 +
++        suite.addTestSuite(IgniteCacheManyClientsTest.class);
++
          return suite;
      }
  }


[18/50] incubator-ignite git commit: Merge remote-tracking branch 'remotes/origin/ignite-998' into ignite-sprint-5

Posted by vo...@apache.org.
Merge remote-tracking branch 'remotes/origin/ignite-998' into ignite-sprint-5


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

Branch: refs/heads/ignite-gg-10411
Commit: 4375529fa929e650f7b68d750318d67a8609ee10
Parents: b52e47a 4ab301d
Author: sboikov <sb...@gridgain.com>
Authored: Thu Jun 11 16:06:03 2015 +0300
Committer: sboikov <sb...@gridgain.com>
Committed: Thu Jun 11 16:06:03 2015 +0300

----------------------------------------------------------------------
 .../ignite/spi/discovery/tcp/ServerImpl.java    |  38 +------
 .../tcp/TcpClientDiscoverySpiSelfTest.java      | 114 ++++++++++++++++++-
 2 files changed, 115 insertions(+), 37 deletions(-)
----------------------------------------------------------------------



[11/50] incubator-ignite git commit: #IGNITE-389 - Readme.

Posted by vo...@apache.org.
#IGNITE-389 - Readme.


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

Branch: refs/heads/ignite-gg-10411
Commit: 9926fb89001e9115c1ea5105c4733208d426b08d
Parents: 71f29e9
Author: Alexey Goncharuk <ag...@gridgain.com>
Authored: Wed Jun 10 15:56:26 2015 -0700
Committer: Alexey Goncharuk <ag...@gridgain.com>
Committed: Wed Jun 10 15:56:26 2015 -0700

----------------------------------------------------------------------
 modules/spark/README.txt | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/9926fb89/modules/spark/README.txt
----------------------------------------------------------------------
diff --git a/modules/spark/README.txt b/modules/spark/README.txt
index 5678441..589a050 100644
--- a/modules/spark/README.txt
+++ b/modules/spark/README.txt
@@ -1,4 +1,8 @@
 Apache Ignite Spark Module
 ---------------------------
 
-Apache Ignite Spark module.
+Apache Ignite provides an implementation of Spark RDD abstraction which enables easy access to Ignite caches.
+Ignite RDD does not keep it's state in the memory of the Spark application and provides a view of the corresponding
+Ignite cache. Depending on the chosen deployment mode this state may exist only during the lifespan of the Spark
+application (embedded mode) or may exist outside of the Spark application (standalone mode), allowing seamless
+sharing of the state between multiple Spark jobs.
\ No newline at end of file


[09/50] incubator-ignite git commit: Merge branch 'ignite-sprint-5' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-389

Posted by vo...@apache.org.
Merge branch 'ignite-sprint-5' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-389


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

Branch: refs/heads/ignite-gg-10411
Commit: 341721582e8788b78c6f84947b38fd5fa380e1e8
Parents: 980bf75 2454eb5
Author: Alexey Goncharuk <ag...@gridgain.com>
Authored: Wed Jun 10 13:20:27 2015 -0700
Committer: Alexey Goncharuk <ag...@gridgain.com>
Committed: Wed Jun 10 13:20:27 2015 -0700

----------------------------------------------------------------------
 .../client/memcache/MemcacheRestExample.java    |  32 ++--
 .../java/org/apache/ignite/IgniteCache.java     |  25 ++-
 .../apache/ignite/IgniteSystemProperties.java   |   3 +
 .../discovery/DiscoveryCustomMessage.java       |   6 +
 .../discovery/GridDiscoveryManager.java         |  32 ++++
 .../affinity/GridAffinityAssignmentCache.java   |   8 +-
 .../cache/DynamicCacheChangeBatch.java          |  19 ++-
 .../GridCachePartitionExchangeManager.java      |   2 +-
 .../processors/cache/IgniteInternalCache.java   |  27 +--
 .../continuous/AbstractContinuousMessage.java   |   9 +
 .../internal/visor/query/VisorQueryJob.java     |   2 +-
 .../internal/visor/util/VisorTaskUtils.java     |  16 +-
 .../ignite/spi/discovery/tcp/ServerImpl.java    |   6 +-
 .../spi/discovery/tcp/TcpDiscoverySpi.java      |   2 +-
 .../RoundRobinGlobalLoadBalancer.java           |   2 +-
 .../distributed/IgniteCacheManyClientsTest.java | 169 +++++++++++++++++++
 .../DataStreamerMultinodeCreateCacheTest.java   |   6 +-
 .../ignite/testframework/GridTestUtils.java     |   2 +-
 .../testsuites/IgniteCacheTestSuite4.java       |   2 +
 19 files changed, 305 insertions(+), 65 deletions(-)
----------------------------------------------------------------------



[05/50] incubator-ignite git commit: Merge branch 'ignite-sprint-5' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-389

Posted by vo...@apache.org.
Merge branch 'ignite-sprint-5' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-389


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

Branch: refs/heads/ignite-gg-10411
Commit: 980bf759e96954577e7a0b8662d7e6a63b6a4d2f
Parents: 079bcc6 928be42
Author: Alexey Goncharuk <ag...@gridgain.com>
Authored: Wed Jun 10 00:05:47 2015 -0700
Committer: Alexey Goncharuk <ag...@gridgain.com>
Committed: Wed Jun 10 00:05:47 2015 -0700

----------------------------------------------------------------------
 .../apache/ignite/internal/IgniteKernal.java    |   2 +-
 .../managers/indexing/GridIndexingManager.java  |   4 -
 .../affinity/GridAffinityAssignment.java        |  12 ++
 .../affinity/GridAffinityAssignmentCache.java   |   4 +-
 .../dht/atomic/GridNearAtomicUpdateFuture.java  |   6 +-
 .../GridDhtPartitionsExchangeFuture.java        |  14 ++-
 .../continuous/GridContinuousProcessor.java     |   2 +
 .../util/nio/GridNioDelimitedBuffer.java        |   2 +-
 .../visor/node/VisorNodeDataCollectorTask.java  |   9 +-
 .../node/VisorNodeDataCollectorTaskResult.java  |  17 +--
 .../node/VisorNodeSuppressedErrorsTask.java     |  12 +-
 .../internal/visor/query/VisorQueryJob.java     |  11 +-
 .../internal/visor/query/VisorQueryTask.java    |   3 +-
 .../visor/util/VisorExceptionWrapper.java       |  81 ++++++++++++++
 .../internal/visor/util/VisorTaskUtils.java     |  10 ++
 .../org/apache/ignite/spi/IgniteSpiAdapter.java |  10 +-
 .../continuous/GridEventConsumeSelfTest.java    |   7 +-
 .../nio/GridNioDelimitedBufferSelfTest.java     | 112 +++++++++++++++++++
 .../util/nio/GridNioDelimitedBufferTest.java    | 112 -------------------
 .../stream/socket/SocketStreamerSelfTest.java   |  29 ++---
 .../ignite/testsuites/IgniteBasicTestSuite.java |   1 +
 .../testsuites/IgniteStreamSelfTestSuite.java   |  39 +++++++
 .../testsuites/IgniteStreamTestSuite.java       |  39 -------
 .../testsuites/IgniteUtilSelfTestSuite.java     |   2 +-
 .../cache/GridCacheOffheapIndexGetSelfTest.java |  62 +++++++++-
 25 files changed, 395 insertions(+), 207 deletions(-)
----------------------------------------------------------------------



[30/50] incubator-ignite git commit: Merge branch 'ignite-classname' into ignite-sprint-6

Posted by vo...@apache.org.
Merge branch 'ignite-classname' into ignite-sprint-6


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

Branch: refs/heads/ignite-gg-10411
Commit: 2b81104aaee4c39260dbd276405ef9f477c90f30
Parents: 2b7a18d e17a2be
Author: nikolay_tikhonov <nt...@gridgain.com>
Authored: Fri Jun 12 17:16:43 2015 +0300
Committer: nikolay_tikhonov <nt...@gridgain.com>
Committed: Fri Jun 12 17:16:43 2015 +0300

----------------------------------------------------------------------
 .../ignite/internal/GridKernalContextImpl.java  |  5 +++--
 .../apache/ignite/internal/IgniteKernal.java    | 21 ++++++++++++++++++--
 .../internal/MarshallerContextAdapter.java      | 18 +++++++++++++++--
 .../ignite/internal/MarshallerContextImpl.java  | 14 ++++++++++++-
 .../GridClientOptimizedMarshaller.java          |  5 +++++
 .../plugin/IgnitePluginProcessor.java           | 16 ++-------------
 .../IgniteCacheP2pUnmarshallingTxErrorTest.java | 14 +++++++++----
 .../marshaller/MarshallerContextTestImpl.java   | 18 +++++++++++++++++
 .../junits/GridTestKernalContext.java           |  1 +
 .../ignite/tools/classgen/ClassesGenerator.java | 18 +++++++++++++----
 10 files changed, 101 insertions(+), 29 deletions(-)
----------------------------------------------------------------------



[15/50] incubator-ignite git commit: Idea code styles added

Posted by vo...@apache.org.
Idea code styles added


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

Branch: refs/heads/ignite-gg-10411
Commit: d36610f41d299a11986525e21c79c23355e426c3
Parents: 89a4f7c
Author: agura <ag...@gridgain.com>
Authored: Thu Jun 11 13:22:32 2015 +0300
Committer: agura <ag...@gridgain.com>
Committed: Thu Jun 11 13:22:32 2015 +0300

----------------------------------------------------------------------
 idea/ignite_codeStyle.xml | 147 +++++++++++++++++++++++++++++++++++++++++
 1 file changed, 147 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/d36610f4/idea/ignite_codeStyle.xml
----------------------------------------------------------------------
diff --git a/idea/ignite_codeStyle.xml b/idea/ignite_codeStyle.xml
new file mode 100644
index 0000000..14faf54
--- /dev/null
+++ b/idea/ignite_codeStyle.xml
@@ -0,0 +1,147 @@
+<code_scheme name="ignite">
+  <option name="USE_SAME_INDENTS" value="true" />
+  <option name="IGNORE_SAME_INDENTS_FOR_LANGUAGES" value="true" />
+  <option name="OTHER_INDENT_OPTIONS">
+    <value>
+      <option name="INDENT_SIZE" value="4" />
+      <option name="CONTINUATION_INDENT_SIZE" value="4" />
+      <option name="TAB_SIZE" value="4" />
+      <option name="USE_TAB_CHARACTER" value="false" />
+      <option name="SMART_TABS" value="false" />
+      <option name="LABEL_INDENT_SIZE" value="0" />
+      <option name="LABEL_INDENT_ABSOLUTE" value="false" />
+      <option name="USE_RELATIVE_INDENTS" value="false" />
+    </value>
+  </option>
+  <option name="PREFER_LONGER_NAMES" value="false" />
+  <option name="USE_SINGLE_CLASS_IMPORTS" value="false" />
+  <option name="CLASS_COUNT_TO_USE_IMPORT_ON_DEMAND" value="0" />
+  <option name="NAMES_COUNT_TO_USE_IMPORT_ON_DEMAND" value="0" />
+  <option name="PACKAGES_TO_USE_IMPORT_ON_DEMAND">
+    <value />
+  </option>
+  <option name="IMPORT_LAYOUT_TABLE">
+    <value>
+      <package name="org.apache" withSubpackages="true" static="false" />
+      <package name="import org.gridgain" withSubpackages="true" static="false" />
+      <emptyLine />
+      <package name="" withSubpackages="true" static="false" />
+      <emptyLine />
+      <package name="javax" withSubpackages="true" static="false" />
+      <package name="java" withSubpackages="true" static="false" />
+      <emptyLine />
+      <package name="" withSubpackages="true" static="true" />
+    </value>
+  </option>
+  <option name="JD_ALIGN_PARAM_COMMENTS" value="false" />
+  <option name="JD_ALIGN_EXCEPTION_COMMENTS" value="false" />
+  <option name="JD_P_AT_EMPTY_LINES" value="false" />
+  <option name="JD_KEEP_INVALID_TAGS" value="false" />
+  <option name="JD_DO_NOT_WRAP_ONE_LINE_COMMENTS" value="true" />
+  <option name="KEEP_CONTROL_STATEMENT_IN_ONE_LINE" value="false" />
+  <option name="KEEP_BLANK_LINES_IN_DECLARATIONS" value="1" />
+  <option name="KEEP_BLANK_LINES_IN_CODE" value="1" />
+  <option name="KEEP_BLANK_LINES_BEFORE_RBRACE" value="1" />
+  <option name="ELSE_ON_NEW_LINE" value="true" />
+  <option name="WHILE_ON_NEW_LINE" value="true" />
+  <option name="CATCH_ON_NEW_LINE" value="true" />
+  <option name="FINALLY_ON_NEW_LINE" value="true" />
+  <option name="ALIGN_MULTILINE_PARAMETERS" value="false" />
+  <option name="ALIGN_MULTILINE_FOR" value="false" />
+  <option name="SPACE_AFTER_TYPE_CAST" value="false" />
+  <option name="SPACE_BEFORE_ARRAY_INITIALIZER_LBRACE" value="true" />
+  <option name="METHOD_PARAMETERS_WRAP" value="1" />
+  <option name="ARRAY_INITIALIZER_LBRACE_ON_NEXT_LINE" value="true" />
+  <option name="LABELED_STATEMENT_WRAP" value="1" />
+  <option name="WRAP_COMMENTS" value="true" />
+  <option name="METHOD_ANNOTATION_WRAP" value="1" />
+  <option name="CLASS_ANNOTATION_WRAP" value="1" />
+  <option name="FIELD_ANNOTATION_WRAP" value="1" />
+  <JavaCodeStyleSettings>
+    <option name="CLASS_NAMES_IN_JAVADOC" value="3" />
+  </JavaCodeStyleSettings>
+  <XML>
+    <option name="XML_LEGACY_SETTINGS_IMPORTED" value="true" />
+  </XML>
+  <ADDITIONAL_INDENT_OPTIONS fileType="haml">
+    <option name="INDENT_SIZE" value="2" />
+  </ADDITIONAL_INDENT_OPTIONS>
+  <codeStyleSettings language="Groovy">
+    <option name="KEEP_CONTROL_STATEMENT_IN_ONE_LINE" value="false" />
+    <option name="KEEP_BLANK_LINES_IN_DECLARATIONS" value="1" />
+    <option name="KEEP_BLANK_LINES_IN_CODE" value="1" />
+    <option name="KEEP_BLANK_LINES_BEFORE_RBRACE" value="1" />
+    <option name="ELSE_ON_NEW_LINE" value="true" />
+    <option name="CATCH_ON_NEW_LINE" value="true" />
+    <option name="FINALLY_ON_NEW_LINE" value="true" />
+    <option name="ALIGN_MULTILINE_PARAMETERS" value="false" />
+    <option name="ALIGN_MULTILINE_FOR" value="false" />
+    <option name="SPACE_AFTER_TYPE_CAST" value="false" />
+    <option name="METHOD_PARAMETERS_WRAP" value="1" />
+    <option name="METHOD_ANNOTATION_WRAP" value="1" />
+    <option name="CLASS_ANNOTATION_WRAP" value="1" />
+    <option name="FIELD_ANNOTATION_WRAP" value="1" />
+    <option name="PARENT_SETTINGS_INSTALLED" value="true" />
+    <indentOptions>
+      <option name="CONTINUATION_INDENT_SIZE" value="4" />
+    </indentOptions>
+  </codeStyleSettings>
+  <codeStyleSettings language="HOCON">
+    <option name="KEEP_BLANK_LINES_BEFORE_RBRACE" value="1" />
+    <option name="PARENT_SETTINGS_INSTALLED" value="true" />
+  </codeStyleSettings>
+  <codeStyleSettings language="JAVA">
+    <option name="KEEP_CONTROL_STATEMENT_IN_ONE_LINE" value="false" />
+    <option name="KEEP_BLANK_LINES_IN_DECLARATIONS" value="1" />
+    <option name="KEEP_BLANK_LINES_IN_CODE" value="1" />
+    <option name="KEEP_BLANK_LINES_BEFORE_RBRACE" value="1" />
+    <option name="ELSE_ON_NEW_LINE" value="true" />
+    <option name="WHILE_ON_NEW_LINE" value="true" />
+    <option name="CATCH_ON_NEW_LINE" value="true" />
+    <option name="FINALLY_ON_NEW_LINE" value="true" />
+    <option name="ALIGN_MULTILINE_PARAMETERS" value="false" />
+    <option name="ALIGN_MULTILINE_FOR" value="false" />
+    <option name="SPACE_AFTER_TYPE_CAST" value="false" />
+    <option name="SPACE_BEFORE_ARRAY_INITIALIZER_LBRACE" value="true" />
+    <option name="METHOD_PARAMETERS_WRAP" value="1" />
+    <option name="ARRAY_INITIALIZER_LBRACE_ON_NEXT_LINE" value="true" />
+    <option name="LABELED_STATEMENT_WRAP" value="1" />
+    <option name="METHOD_ANNOTATION_WRAP" value="1" />
+    <option name="CLASS_ANNOTATION_WRAP" value="1" />
+    <option name="FIELD_ANNOTATION_WRAP" value="1" />
+    <option name="PARENT_SETTINGS_INSTALLED" value="true" />
+    <indentOptions>
+      <option name="CONTINUATION_INDENT_SIZE" value="4" />
+    </indentOptions>
+  </codeStyleSettings>
+  <codeStyleSettings language="JSON">
+    <option name="KEEP_BLANK_LINES_IN_CODE" value="1" />
+    <option name="PARENT_SETTINGS_INSTALLED" value="true" />
+  </codeStyleSettings>
+  <codeStyleSettings language="Scala">
+    <option name="KEEP_BLANK_LINES_IN_DECLARATIONS" value="1" />
+    <option name="KEEP_BLANK_LINES_IN_CODE" value="1" />
+    <option name="KEEP_BLANK_LINES_BEFORE_RBRACE" value="1" />
+    <option name="ELSE_ON_NEW_LINE" value="true" />
+    <option name="WHILE_ON_NEW_LINE" value="true" />
+    <option name="CATCH_ON_NEW_LINE" value="true" />
+    <option name="FINALLY_ON_NEW_LINE" value="true" />
+    <option name="ALIGN_MULTILINE_PARAMETERS" value="false" />
+    <option name="ALIGN_MULTILINE_FOR" value="false" />
+    <option name="METHOD_PARAMETERS_WRAP" value="1" />
+    <option name="METHOD_ANNOTATION_WRAP" value="1" />
+    <option name="CLASS_ANNOTATION_WRAP" value="1" />
+    <option name="FIELD_ANNOTATION_WRAP" value="1" />
+    <option name="PARENT_SETTINGS_INSTALLED" value="true" />
+    <indentOptions>
+      <option name="INDENT_SIZE" value="4" />
+      <option name="CONTINUATION_INDENT_SIZE" value="4" />
+      <option name="TAB_SIZE" value="4" />
+    </indentOptions>
+  </codeStyleSettings>
+  <codeStyleSettings language="XML">
+    <indentOptions>
+      <option name="CONTINUATION_INDENT_SIZE" value="4" />
+    </indentOptions>
+  </codeStyleSettings>
+</code_scheme>
\ No newline at end of file


[38/50] incubator-ignite git commit: # ignite-1009-v4

Posted by vo...@apache.org.
# ignite-1009-v4


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

Branch: refs/heads/ignite-gg-10411
Commit: b06eb0e19b28fb660445585d4602a07389751476
Parents: cd43ff7
Author: sboikov <sb...@gridgain.com>
Authored: Fri Jun 12 18:29:19 2015 +0300
Committer: sboikov <sb...@gridgain.com>
Committed: Fri Jun 12 18:29:19 2015 +0300

----------------------------------------------------------------------
 .../cache/distributed/dht/GridDhtTransactionalCacheAdapter.java    | 2 +-
 .../internal/processors/cache/transactions/IgniteTxHandler.java    | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/b06eb0e1/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTransactionalCacheAdapter.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTransactionalCacheAdapter.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTransactionalCacheAdapter.java
index 4f081bf..703daf9 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTransactionalCacheAdapter.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTransactionalCacheAdapter.java
@@ -859,7 +859,7 @@ public abstract class GridDhtTransactionalCacheAdapter<K, V> extends GridDhtCach
                                         req.isolation(),
                                         req.timeout(),
                                         req.isInvalidate(),
-                                        true,
+                                        false,
                                         req.txSize(),
                                         null,
                                         req.subjectId(),

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/b06eb0e1/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 e481e25..01662ef 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
@@ -325,7 +325,7 @@ public class IgniteTxHandler {
                     req.isolation(),
                     req.timeout(),
                     req.isInvalidate(),
-                    true,
+                    false,
                     req.txSize(),
                     req.transactionNodes(),
                     req.subjectId(),


[33/50] incubator-ignite git commit: Merge remote-tracking branch 'origin/ignite-sprint-6' into ignite-sprint-6

Posted by vo...@apache.org.
Merge remote-tracking branch 'origin/ignite-sprint-6' into ignite-sprint-6


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

Branch: refs/heads/ignite-gg-10411
Commit: 516008811d416b92011d3a70249a579cf41b1e93
Parents: dd58664 2b81104
Author: Yakov Zhdanov <yz...@gridgain.com>
Authored: Fri Jun 12 17:21:14 2015 +0300
Committer: Yakov Zhdanov <yz...@gridgain.com>
Committed: Fri Jun 12 17:21:14 2015 +0300

----------------------------------------------------------------------
 .../ignite/internal/GridKernalContextImpl.java  |  5 +++--
 .../apache/ignite/internal/IgniteKernal.java    | 21 ++++++++++++++++++--
 .../internal/MarshallerContextAdapter.java      | 18 +++++++++++++++--
 .../ignite/internal/MarshallerContextImpl.java  | 14 ++++++++++++-
 .../GridClientOptimizedMarshaller.java          |  5 +++++
 .../plugin/IgnitePluginProcessor.java           | 16 ++-------------
 .../IgniteCacheP2pUnmarshallingTxErrorTest.java | 14 +++++++++----
 .../marshaller/MarshallerContextTestImpl.java   | 18 +++++++++++++++++
 .../junits/GridTestKernalContext.java           |  1 +
 .../ignite/tools/classgen/ClassesGenerator.java | 18 +++++++++++++----
 10 files changed, 101 insertions(+), 29 deletions(-)
----------------------------------------------------------------------



[24/50] incubator-ignite git commit: ignite-sprint-6: fixing/ajusting tests that cooperate with portable marshaller

Posted by vo...@apache.org.
ignite-sprint-6: fixing/ajusting tests that cooperate with portable marshaller


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

Branch: refs/heads/ignite-gg-10411
Commit: c233aa260b35766495b23bc57c6ce55f0ddef3b3
Parents: 83a1986
Author: Denis Magda <dm...@gridgain.com>
Authored: Fri Jun 12 15:37:34 2015 +0300
Committer: Denis Magda <dm...@gridgain.com>
Committed: Fri Jun 12 15:37:34 2015 +0300

----------------------------------------------------------------------
 .../processors/datastreamer/DataStreamProcessorSelfTest.java      | 3 ++-
 .../org/apache/ignite/testsuites/IgniteKernalSelfTestSuite.java   | 2 +-
 2 files changed, 3 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/c233aa26/modules/core/src/test/java/org/apache/ignite/internal/processors/datastreamer/DataStreamProcessorSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/datastreamer/DataStreamProcessorSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/datastreamer/DataStreamProcessorSelfTest.java
index 80bf9e0..8a539d2 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/datastreamer/DataStreamProcessorSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/datastreamer/DataStreamProcessorSelfTest.java
@@ -29,7 +29,6 @@ import org.apache.ignite.internal.processors.cache.*;
 import org.apache.ignite.internal.processors.cache.distributed.near.*;
 import org.apache.ignite.internal.util.typedef.internal.*;
 import org.apache.ignite.lang.*;
-import org.apache.ignite.marshaller.optimized.*;
 import org.apache.ignite.spi.discovery.tcp.*;
 import org.apache.ignite.spi.discovery.tcp.ipfinder.*;
 import org.apache.ignite.spi.discovery.tcp.ipfinder.vm.*;
@@ -82,6 +81,8 @@ public class DataStreamProcessorSelfTest extends GridCommonAbstractTest {
     @Override protected IgniteConfiguration getConfiguration(String gridName) throws Exception {
         IgniteConfiguration cfg = super.getConfiguration(gridName);
 
+        cfg.setPeerClassLoadingEnabled(false);
+
         TcpDiscoverySpi spi = new TcpDiscoverySpi();
 
         spi.setForceServerMode(true);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/c233aa26/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteKernalSelfTestSuite.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteKernalSelfTestSuite.java b/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteKernalSelfTestSuite.java
index 978941d..e8c89ec 100644
--- a/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteKernalSelfTestSuite.java
+++ b/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteKernalSelfTestSuite.java
@@ -77,7 +77,7 @@ public class IgniteKernalSelfTestSuite extends TestSuite {
         suite.addTestSuite(GridHomePathSelfTest.class);
         GridTestUtils.addTestIfNeeded(suite, GridStartupWithSpecifiedWorkDirectorySelfTest.class, ignoredTests);
         suite.addTestSuite(GridStartupWithUndefinedIgniteHomeSelfTest.class);
-        suite.addTestSuite(GridVersionSelfTest.class);
+        GridTestUtils.addTestIfNeeded(suite, GridVersionSelfTest.class, ignoredTests);
         suite.addTestSuite(GridListenActorSelfTest.class);
         suite.addTestSuite(GridNodeLocalSelfTest.class);
         suite.addTestSuite(GridKernalConcurrentAccessStopSelfTest.class);


[49/50] incubator-ignite git commit: # ignite-sprint-6 disabled failing tests

Posted by vo...@apache.org.
# ignite-sprint-6 disabled failing tests


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

Branch: refs/heads/ignite-gg-10411
Commit: f4b112347c37ed2cb899e00e6d76acbbc664e54a
Parents: d28fea0
Author: sboikov <sb...@gridgain.com>
Authored: Tue Jun 16 10:36:49 2015 +0300
Committer: sboikov <sb...@gridgain.com>
Committed: Tue Jun 16 10:36:49 2015 +0300

----------------------------------------------------------------------
 .../processors/cache/distributed/IgniteCacheManyClientsTest.java | 4 ++++
 1 file changed, 4 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/f4b11234/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java
index 4fb4387..62c7c1a 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java
@@ -110,6 +110,8 @@ public class IgniteCacheManyClientsTest extends GridCommonAbstractTest {
      * @throws Exception If failed.
      */
     public void testManyClientsClientDiscovery() throws Exception {
+        fail("https://issues.apache.org/jira/browse/IGNITE-883");
+
         clientDiscovery = true;
 
         manyClientsPutGet();
@@ -119,6 +121,8 @@ public class IgniteCacheManyClientsTest extends GridCommonAbstractTest {
      * @throws Exception If failed.
      */
     public void testManyClientsSequentiallyClientDiscovery() throws Exception {
+        fail("https://issues.apache.org/jira/browse/IGNITE-883");
+
         clientDiscovery = true;
 
         manyClientsSequentially();


[04/50] incubator-ignite git commit: Merge remote-tracking branch 'origin/ignite-389' into ignite-389

Posted by vo...@apache.org.
Merge remote-tracking branch 'origin/ignite-389' into ignite-389


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

Branch: refs/heads/ignite-gg-10411
Commit: 079bcc681343899e6ee7b0848ed57614d610ef55
Parents: f129d08 b812c0f
Author: avinogradov <av...@gridgain.com>
Authored: Tue Jun 9 15:11:56 2015 +0300
Committer: avinogradov <av...@gridgain.com>
Committed: Tue Jun 9 15:11:56 2015 +0300

----------------------------------------------------------------------
 ...CacheScanPartitionQueryFallbackSelfTest.java | 20 ++++++++++++++++----
 1 file changed, 16 insertions(+), 4 deletions(-)
----------------------------------------------------------------------



[37/50] incubator-ignite git commit: Merge remote-tracking branch 'remotes/origin/ignite-sprint-6' into ignite-1009-v4

Posted by vo...@apache.org.
Merge remote-tracking branch 'remotes/origin/ignite-sprint-6' into ignite-1009-v4


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

Branch: refs/heads/ignite-gg-10411
Commit: cd43ff7c4f9db4dc29572bd4dace4443b0373392
Parents: 7f97ec7 2707194
Author: sboikov <sb...@gridgain.com>
Authored: Fri Jun 12 18:28:23 2015 +0300
Committer: sboikov <sb...@gridgain.com>
Committed: Fri Jun 12 18:28:23 2015 +0300

----------------------------------------------------------------------
 RELEASE_NOTES.txt                               | 12 +++
 .../ignite/internal/GridKernalContextImpl.java  |  5 +-
 .../apache/ignite/internal/IgniteKernal.java    | 21 +++++-
 .../internal/MarshallerContextAdapter.java      | 18 ++++-
 .../ignite/internal/MarshallerContextImpl.java  | 14 +++-
 .../GridClientOptimizedMarshaller.java          |  5 ++
 .../distributed/GridCacheTxRecoveryRequest.java | 26 +++----
 .../GridCacheTxRecoveryResponse.java            | 14 ++--
 .../distributed/GridDistributedBaseMessage.java | 77 +-------------------
 .../distributed/GridDistributedLockRequest.java | 54 +++++++-------
 .../GridDistributedLockResponse.java            | 14 ++--
 .../GridDistributedTxFinishRequest.java         | 46 ++++++------
 .../GridDistributedTxPrepareRequest.java        | 62 ++++++++--------
 .../GridDistributedTxPrepareResponse.java       | 64 +---------------
 .../GridDistributedUnlockRequest.java           |  6 +-
 .../distributed/dht/GridDhtLockRequest.java     | 72 ++++++++++++++----
 .../distributed/dht/GridDhtLockResponse.java    | 18 ++---
 .../distributed/dht/GridDhtTxFinishRequest.java | 38 +++++-----
 .../dht/GridDhtTxPrepareRequest.java            | 54 +++++++-------
 .../dht/GridDhtTxPrepareResponse.java           | 22 +++---
 .../distributed/dht/GridDhtUnlockRequest.java   |  6 +-
 .../distributed/near/GridNearLockRequest.java   | 58 +++++++--------
 .../distributed/near/GridNearLockResponse.java  | 26 +++----
 .../near/GridNearTxFinishRequest.java           | 26 +++----
 .../near/GridNearTxPrepareRequest.java          | 50 ++++++-------
 .../near/GridNearTxPrepareResponse.java         | 46 ++++++------
 .../distributed/near/GridNearUnlockRequest.java |  2 +-
 .../cache/transactions/IgniteTxHandler.java     |  3 -
 .../plugin/IgnitePluginProcessor.java           | 16 +---
 .../messages/GridQueryNextPageResponse.java     |  1 +
 .../cache/GridCachePutAllFailoverSelfTest.java  |  5 --
 .../IgniteCacheP2pUnmarshallingTxErrorTest.java | 14 +++-
 .../dht/GridCacheColocatedFailoverSelfTest.java |  5 --
 .../GridCachePartitionedFailoverSelfTest.java   |  5 --
 .../GridCacheReplicatedFailoverSelfTest.java    |  5 --
 .../DataStreamProcessorSelfTest.java            |  3 +-
 .../marshaller/MarshallerContextTestImpl.java   | 18 +++++
 .../junits/GridTestKernalContext.java           |  1 +
 .../testsuites/IgniteKernalSelfTestSuite.java   |  2 +-
 .../ignite/tools/classgen/ClassesGenerator.java | 18 ++++-
 40 files changed, 464 insertions(+), 488 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/cd43ff7c/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxHandler.java
----------------------------------------------------------------------


[08/50] incubator-ignite git commit: # ignite-sprint-5 increased affinity history size

Posted by vo...@apache.org.
# ignite-sprint-5 increased affinity history size


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

Branch: refs/heads/ignite-gg-10411
Commit: 2454eb58ae60718f8fcf55eccb7a4fc7016e0bcf
Parents: addc91b
Author: sboikov <sb...@gridgain.com>
Authored: Wed Jun 10 17:43:02 2015 +0300
Committer: sboikov <sb...@gridgain.com>
Committed: Wed Jun 10 17:43:02 2015 +0300

----------------------------------------------------------------------
 .../apache/ignite/IgniteSystemProperties.java   |   3 +
 .../affinity/GridAffinityAssignmentCache.java   |   5 +-
 .../GridCachePartitionExchangeManager.java      |   2 +-
 .../distributed/IgniteCacheManyClientsTest.java | 169 +++++++++++++++++++
 .../testsuites/IgniteCacheTestSuite4.java       |   2 +
 5 files changed, 178 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/2454eb58/modules/core/src/main/java/org/apache/ignite/IgniteSystemProperties.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/IgniteSystemProperties.java b/modules/core/src/main/java/org/apache/ignite/IgniteSystemProperties.java
index 439ea2d..b166f39 100644
--- a/modules/core/src/main/java/org/apache/ignite/IgniteSystemProperties.java
+++ b/modules/core/src/main/java/org/apache/ignite/IgniteSystemProperties.java
@@ -337,6 +337,9 @@ public final class IgniteSystemProperties {
      */
     public static final String IGNITE_SQL_MERGE_TABLE_MAX_SIZE = "IGNITE_SQL_MERGE_TABLE_MAX_SIZE";
 
+    /** Maximum size for affinity assignment history. */
+    public static final String IGNITE_AFFINITY_HISTORY_SIZE = "IGNITE_AFFINITY_HISTORY_SIZE";
+
     /**
      * Enforces singleton.
      */

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/2454eb58/modules/core/src/main/java/org/apache/ignite/internal/processors/affinity/GridAffinityAssignmentCache.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/affinity/GridAffinityAssignmentCache.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/affinity/GridAffinityAssignmentCache.java
index 47f222e..6989385 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/affinity/GridAffinityAssignmentCache.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/affinity/GridAffinityAssignmentCache.java
@@ -408,9 +408,10 @@ public class GridAffinityAssignmentCache {
                 throw new IllegalStateException("Getting affinity for topology version earlier than affinity is " +
                     "calculated [locNodeId=" + ctx.localNodeId() +
                     ", cache=" + cacheName +
-                    ", history=" + affCache.keySet() +
                     ", topVer=" + topVer +
-                    ", head=" + head.get().topologyVersion() + ']');
+                    ", head=" + head.get().topologyVersion() +
+                    ", history=" + affCache.keySet() +
+                    ']');
             }
         }
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/2454eb58/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCachePartitionExchangeManager.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCachePartitionExchangeManager.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCachePartitionExchangeManager.java
index 3236bb5..3df45cb 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCachePartitionExchangeManager.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCachePartitionExchangeManager.java
@@ -59,7 +59,7 @@ public class GridCachePartitionExchangeManager<K, V> extends GridCacheSharedMana
     private static final int EXCHANGE_HISTORY_SIZE = 1000;
 
     /** Cleanup history size. */
-    public static final int EXCH_FUT_CLEANUP_HISTORY_SIZE = 10;
+    public static final int EXCH_FUT_CLEANUP_HISTORY_SIZE = getInteger(IGNITE_AFFINITY_HISTORY_SIZE, 100);
 
     /** Atomic reference for pending timeout object. */
     private AtomicReference<ResendTimeoutObject> pendingResend = new AtomicReference<>();

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/2454eb58/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java
new file mode 100644
index 0000000..24ebb7c
--- /dev/null
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java
@@ -0,0 +1,169 @@
+/*
+ * 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.processors.cache.distributed;
+
+import org.apache.ignite.*;
+import org.apache.ignite.cache.*;
+import org.apache.ignite.configuration.*;
+import org.apache.ignite.internal.*;
+import org.apache.ignite.spi.discovery.tcp.*;
+import org.apache.ignite.spi.discovery.tcp.ipfinder.*;
+import org.apache.ignite.spi.discovery.tcp.ipfinder.vm.*;
+import org.apache.ignite.testframework.*;
+import org.apache.ignite.testframework.junits.common.*;
+
+import java.util.concurrent.*;
+import java.util.concurrent.atomic.*;
+
+import static org.apache.ignite.cache.CacheAtomicityMode.*;
+import static org.apache.ignite.cache.CacheMode.*;
+import static org.apache.ignite.cache.CacheWriteSynchronizationMode.*;
+
+/**
+ *
+ */
+public class IgniteCacheManyClientsTest extends GridCommonAbstractTest {
+    /** */
+    protected static TcpDiscoveryIpFinder ipFinder = new TcpDiscoveryVmIpFinder(true);
+
+    /** */
+    private static final int SRVS = 4;
+
+    /** */
+    private boolean client;
+
+    /** */
+    private boolean clientDiscovery;
+
+    /** {@inheritDoc} */
+    @Override protected IgniteConfiguration getConfiguration(String gridName) throws Exception {
+        IgniteConfiguration cfg = super.getConfiguration(gridName);
+
+        ((TcpDiscoverySpi)cfg.getDiscoverySpi()).setIpFinder(ipFinder);
+
+        if (!clientDiscovery)
+            ((TcpDiscoverySpi)cfg.getDiscoverySpi()).setForceServerMode(true);
+
+        cfg.setClientMode(client);
+
+        CacheConfiguration ccfg = new CacheConfiguration();
+
+        ccfg.setCacheMode(PARTITIONED);
+        ccfg.setAtomicityMode(ATOMIC);
+        ccfg.setWriteSynchronizationMode(PRIMARY_SYNC);
+        ccfg.setBackups(1);
+
+        cfg.setCacheConfiguration(ccfg);
+
+        return cfg;
+    }
+
+    /** {@inheritDoc} */
+    @Override protected void beforeTestsStarted() throws Exception {
+        startGrids(SRVS);
+    }
+
+    /** {@inheritDoc} */
+    @Override protected void afterTestsStopped() throws Exception {
+        super.afterTestsStopped();
+
+        stopAllGrids();
+    }
+
+    /**
+     * @throws Exception If failed.
+     */
+    public void testManyClients() throws Exception {
+        manyClientsPutGet();
+    }
+
+    /**
+     * @throws Exception If failed.
+     */
+    public void testManyClientsClientDiscovery() throws Exception {
+        clientDiscovery = true;
+
+        manyClientsPutGet();
+    }
+
+    /**
+     * @throws Exception If failed.
+     */
+    private void manyClientsPutGet() throws Exception {
+        client = true;
+
+        final AtomicInteger idx = new AtomicInteger(SRVS);
+
+        final AtomicBoolean stop = new AtomicBoolean();
+
+        final int THREADS = 30;
+
+        final CountDownLatch latch = new CountDownLatch(THREADS);
+
+        try {
+            IgniteInternalFuture<?> fut = GridTestUtils.runMultiThreadedAsync(new Callable<Object>() {
+                @Override public Object call() throws Exception {
+                    try (Ignite ignite = startGrid(idx.getAndIncrement())) {
+                        log.info("Started node: " + ignite.name());
+
+                        assertTrue(ignite.configuration().isClientMode());
+
+                        IgniteCache<Object, Object> cache = ignite.cache(null);
+
+                        ThreadLocalRandom rnd = ThreadLocalRandom.current();
+
+                        int iter = 0;
+
+                        Integer key = rnd.nextInt(0, 1000);
+
+                        cache.put(key, iter++);
+
+                        assertNotNull(cache.get(key));
+
+                        latch.countDown();
+
+                        while (!stop.get()) {
+                            key = rnd.nextInt(0, 1000);
+
+                            cache.put(key, iter++);
+
+                            assertNotNull(cache.get(key));
+                        }
+
+                        log.info("Stopping node: " + ignite.name());
+                    }
+
+                    return null;
+                }
+            }, THREADS, "client-thread");
+
+            latch.await();
+
+            Thread.sleep(10_000);
+
+            log.info("Stop clients.");
+
+            stop.set(true);
+
+            fut.get();
+        }
+        finally {
+            stop.set(true);
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/2454eb58/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java b/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
index 713c5e5..ed9fc9a 100644
--- a/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
+++ b/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
@@ -138,6 +138,8 @@ public class IgniteCacheTestSuite4 extends TestSuite {
 
         suite.addTestSuite(CacheReadOnlyTransactionalClientSelfTest.class);
 
+        suite.addTestSuite(IgniteCacheManyClientsTest.class);
+
         return suite;
     }
 }


[16/50] incubator-ignite git commit: ScanQuery setPartition chaining style fixed

Posted by vo...@apache.org.
ScanQuery setPartition chaining style fixed


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

Branch: refs/heads/ignite-gg-10411
Commit: 4f500fdf65275ef066578578493212433075a201
Parents: d36610f
Author: agura <ag...@gridgain.com>
Authored: Thu Jun 11 13:33:15 2015 +0300
Committer: agura <ag...@gridgain.com>
Committed: Thu Jun 11 13:33:15 2015 +0300

----------------------------------------------------------------------
 .../src/main/java/org/apache/ignite/cache/query/ScanQuery.java  | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/4f500fdf/modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java b/modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
index e6b69bc..11a8c84 100644
--- a/modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
+++ b/modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
@@ -111,9 +111,12 @@ public final class ScanQuery<K, V> extends Query<Cache.Entry<K, V>> {
      * all partitions in the cache. Must be in the range [0, N) where N is partition number in the cache.
      *
      * @param part Partition number over which this query should iterate.
+     * @return {@code this} for chaining.
      */
-    public void setPartition(@Nullable Integer part) {
+    public ScanQuery<K, V> setPartition(@Nullable Integer part) {
         this.part = part;
+
+        return this;
     }
 
     /** {@inheritDoc} */


[26/50] incubator-ignite git commit: Tests unmuted

Posted by vo...@apache.org.
Tests unmuted


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

Branch: refs/heads/ignite-gg-10411
Commit: 96d12d0ec2bcee65a4f4f76869b3eb1c259f316e
Parents: b087aca
Author: agura <ag...@gridgain.com>
Authored: Fri Jun 12 16:38:29 2015 +0300
Committer: agura <ag...@gridgain.com>
Committed: Fri Jun 12 16:38:29 2015 +0300

----------------------------------------------------------------------
 .../processors/cache/GridCachePutAllFailoverSelfTest.java       | 5 -----
 .../distributed/dht/GridCacheColocatedFailoverSelfTest.java     | 5 -----
 .../distributed/near/GridCachePartitionedFailoverSelfTest.java  | 5 -----
 .../replicated/GridCacheReplicatedFailoverSelfTest.java         | 5 -----
 4 files changed, 20 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/96d12d0e/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCachePutAllFailoverSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCachePutAllFailoverSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCachePutAllFailoverSelfTest.java
index 4ef5787..fc9e17b 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCachePutAllFailoverSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCachePutAllFailoverSelfTest.java
@@ -49,11 +49,6 @@ import static org.apache.ignite.cache.CacheWriteSynchronizationMode.*;
  * Tests putAll() method along with failover and different configurations.
  */
 public class GridCachePutAllFailoverSelfTest extends GridCommonAbstractTest {
-    /** {@inheritDoc} */
-    @Override protected void beforeTest() throws Exception {
-        fail("https://issues.apache.org/jira/browse/IGNITE-157");
-    }
-
     /** IP finder. */
     private static TcpDiscoveryIpFinder ipFinder = new TcpDiscoveryVmIpFinder(true);
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/96d12d0e/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridCacheColocatedFailoverSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridCacheColocatedFailoverSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridCacheColocatedFailoverSelfTest.java
index 74a107d..568b08f 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridCacheColocatedFailoverSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridCacheColocatedFailoverSelfTest.java
@@ -28,11 +28,6 @@ import static org.apache.ignite.cache.CacheMode.*;
  */
 public class GridCacheColocatedFailoverSelfTest extends GridCacheAbstractFailoverTxSelfTest {
     /** {@inheritDoc} */
-    @Override protected void beforeTest() throws Exception {
-        fail("https://issues.apache.org/jira/browse/IGNITE-631 or IGNITE-157 or IGNITE-882");
-    }
-
-    /** {@inheritDoc} */
     @Override protected CacheMode cacheMode() {
         return PARTITIONED;
     }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/96d12d0e/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/GridCachePartitionedFailoverSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/GridCachePartitionedFailoverSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/GridCachePartitionedFailoverSelfTest.java
index 9825cfd..553d748 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/GridCachePartitionedFailoverSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/GridCachePartitionedFailoverSelfTest.java
@@ -27,11 +27,6 @@ import static org.apache.ignite.cache.CacheMode.*;
  */
 public class GridCachePartitionedFailoverSelfTest extends GridCacheAbstractFailoverTxSelfTest {
     /** {@inheritDoc} */
-    @Override protected void beforeTest() throws Exception {
-        fail("https://issues.apache.org/jira/browse/IGNITE-631 or IGNITE-157 or IGNITE-882");
-    }
-
-    /** {@inheritDoc} */
     @Override protected CacheMode cacheMode() {
         return PARTITIONED;
     }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/96d12d0e/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/replicated/GridCacheReplicatedFailoverSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/replicated/GridCacheReplicatedFailoverSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/replicated/GridCacheReplicatedFailoverSelfTest.java
index 1103773..3461dd4 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/replicated/GridCacheReplicatedFailoverSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/replicated/GridCacheReplicatedFailoverSelfTest.java
@@ -28,11 +28,6 @@ import static org.apache.ignite.cache.CacheMode.*;
  */
 public class GridCacheReplicatedFailoverSelfTest extends GridCacheAbstractFailoverTxSelfTest {
     /** {@inheritDoc} */
-    @Override protected void beforeTest() throws Exception {
-        fail("https://issues.apache.org/jira/browse/IGNITE-631 or IGNITE-157 or IGNITE-882");
-    }
-
-    /** {@inheritDoc} */
     @Override protected CacheMode cacheMode() {
         return REPLICATED;
     }


[47/50] incubator-ignite git commit: Merge branches 'ignite-883-1' and 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-883-1

Posted by vo...@apache.org.
Merge branches 'ignite-883-1' and 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-883-1

Conflicts:
	modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
	modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java


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

Branch: refs/heads/ignite-gg-10411
Commit: 5d8a5e61945436e6bcda31d9fb12edda2feac2a0
Parents: 4a13491
Author: Yakov Zhdanov <yz...@gridgain.com>
Authored: Mon Jun 15 10:45:38 2015 +0300
Committer: Yakov Zhdanov <yz...@gridgain.com>
Committed: Mon Jun 15 10:45:38 2015 +0300

----------------------------------------------------------------------
 .../java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/5d8a5e61/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java b/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
index c598e38..fed5efe 100644
--- a/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
+++ b/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
@@ -136,11 +136,11 @@ public class IgniteCacheTestSuite4 extends TestSuite {
 
         suite.addTestSuite(CacheReadOnlyTransactionalClientSelfTest.class);
 
-        suite.addTestSuite(IgniteCacheManyClientsTest.class);
-
         suite.addTestSuite(IgniteStartCacheInTransactionSelfTest.class);
         suite.addTestSuite(IgniteStartCacheInTransactionAtomicSelfTest.class);
 
+        suite.addTestSuite(IgniteCacheManyClientsTest.class);
+
         return suite;
     }
 }


[22/50] incubator-ignite git commit: ignite-classname Marshaller load classname properties by plugin name.

Posted by vo...@apache.org.
ignite-classname Marshaller load classname properties by plugin name.


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

Branch: refs/heads/ignite-gg-10411
Commit: a515ec91d23910b3a4d686f5d53f279cdb6e4cb0
Parents: b087aca
Author: nikolay_tikhonov <nt...@gridgain.com>
Authored: Fri Jun 12 12:49:53 2015 +0300
Committer: nikolay_tikhonov <nt...@gridgain.com>
Committed: Fri Jun 12 12:49:53 2015 +0300

----------------------------------------------------------------------
 .../ignite/internal/GridKernalContextImpl.java   |  5 +++--
 .../org/apache/ignite/internal/IgniteKernal.java | 19 +++++++++++++++++--
 .../internal/MarshallerContextAdapter.java       | 18 ++++++++++++++++--
 .../ignite/internal/MarshallerContextImpl.java   |  7 ++++++-
 .../optimized/GridClientOptimizedMarshaller.java |  5 +++++
 .../processors/plugin/IgnitePluginProcessor.java | 16 ++--------------
 .../marshaller/MarshallerContextTestImpl.java    | 18 ++++++++++++++++++
 .../junits/GridTestKernalContext.java            |  1 +
 8 files changed, 68 insertions(+), 21 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/a515ec91/modules/core/src/main/java/org/apache/ignite/internal/GridKernalContextImpl.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/GridKernalContextImpl.java b/modules/core/src/main/java/org/apache/ignite/internal/GridKernalContextImpl.java
index f921d49..7b07593 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/GridKernalContextImpl.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/GridKernalContextImpl.java
@@ -340,7 +340,8 @@ public class GridKernalContextImpl implements GridKernalContext, Externalizable
         ExecutorService p2pExecSvc,
         ExecutorService mgmtExecSvc,
         ExecutorService igfsExecSvc,
-        ExecutorService restExecSvc) throws IgniteCheckedException {
+        ExecutorService restExecSvc,
+        List<PluginProvider> plugins) throws IgniteCheckedException {
         assert grid != null;
         assert cfg != null;
         assert gw != null;
@@ -357,7 +358,7 @@ public class GridKernalContextImpl implements GridKernalContext, Externalizable
         this.igfsExecSvc = igfsExecSvc;
         this.restExecSvc = restExecSvc;
 
-        marshCtx = new MarshallerContextImpl();
+        marshCtx = new MarshallerContextImpl(plugins);
 
         try {
             spring = SPRING.create(false);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/a515ec91/modules/core/src/main/java/org/apache/ignite/internal/IgniteKernal.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/IgniteKernal.java b/modules/core/src/main/java/org/apache/ignite/internal/IgniteKernal.java
index db238c8..9b2ae27 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/IgniteKernal.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/IgniteKernal.java
@@ -77,6 +77,7 @@ import javax.management.*;
 import java.io.*;
 import java.lang.management.*;
 import java.lang.reflect.*;
+import java.security.*;
 import java.text.*;
 import java.util.*;
 import java.util.concurrent.*;
@@ -629,6 +630,19 @@ public class IgniteKernal implements IgniteEx, IgniteMXBean, Externalizable {
         // Ack configuration.
         ackSpis();
 
+        List<PluginProvider> plugins = AccessController.doPrivileged(new PrivilegedAction<List<PluginProvider>>() {
+            @Override public List<PluginProvider> run() {
+                List<PluginProvider> providers = new ArrayList<>();
+
+                ServiceLoader<PluginProvider> ldr = ServiceLoader.load(PluginProvider.class);
+
+                for (PluginProvider provider : ldr)
+                    providers.add(provider);
+
+                return providers;
+            }
+        });
+
         // Spin out SPIs & managers.
         try {
             ctx = new GridKernalContextImpl(log,
@@ -642,7 +656,8 @@ public class IgniteKernal implements IgniteEx, IgniteMXBean, Externalizable {
                 p2pExecSvc,
                 mgmtExecSvc,
                 igfsExecSvc,
-                restExecSvc);
+                restExecSvc,
+                plugins);
 
             cfg.getMarshaller().setContext(ctx.marshallerContext());
 
@@ -678,7 +693,7 @@ public class IgniteKernal implements IgniteEx, IgniteMXBean, Externalizable {
 
             addHelper(IGFS_HELPER.create(F.isEmpty(cfg.getFileSystemConfiguration())));
 
-            startProcessor(new IgnitePluginProcessor(ctx, cfg));
+            startProcessor(new IgnitePluginProcessor(ctx, cfg, plugins));
 
             verChecker = null;
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/a515ec91/modules/core/src/main/java/org/apache/ignite/internal/MarshallerContextAdapter.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/MarshallerContextAdapter.java b/modules/core/src/main/java/org/apache/ignite/internal/MarshallerContextAdapter.java
index 2ec9825..6ef7713 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/MarshallerContextAdapter.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/MarshallerContextAdapter.java
@@ -21,6 +21,8 @@ import org.apache.ignite.*;
 import org.apache.ignite.internal.processors.cache.distributed.dht.preloader.*;
 import org.apache.ignite.internal.util.typedef.internal.*;
 import org.apache.ignite.marshaller.*;
+import org.apache.ignite.plugin.*;
+import org.jetbrains.annotations.*;
 import org.jsr166.*;
 
 import java.io.*;
@@ -46,8 +48,10 @@ public abstract class MarshallerContextAdapter implements MarshallerContext {
 
     /**
      * Initializes context.
+     *
+     * @param plugins Plugins.
      */
-    public MarshallerContextAdapter() {
+    public MarshallerContextAdapter(@Nullable List<PluginProvider> plugins) {
         try {
             ClassLoader ldr = U.gridClassLoader();
 
@@ -76,6 +80,16 @@ public abstract class MarshallerContextAdapter implements MarshallerContext {
             checkHasClassName(GridDhtPartitionFullMap.class.getName(), ldr, CLS_NAMES_FILE);
             checkHasClassName(GridDhtPartitionMap.class.getName(), ldr, CLS_NAMES_FILE);
             checkHasClassName(HashMap.class.getName(), ldr, JDK_CLS_NAMES_FILE);
+
+            if (plugins != null && !plugins.isEmpty()) {
+                for (PluginProvider plugin : plugins) {
+                    URL pluginClsNames = ldr.getResource("META-INF/" + plugin.name().toLowerCase()
+                        + ".classnames.properties");
+
+                    if (pluginClsNames != null)
+                        processResource(pluginClsNames);
+                }
+            }
         }
         catch (IOException e) {
             throw new IllegalStateException("Failed to initialize marshaller context.", e);
@@ -87,7 +101,7 @@ public abstract class MarshallerContextAdapter implements MarshallerContext {
      * @param ldr Class loader used to get properties file.
      * @param fileName File name.
      */
-    private void checkHasClassName(String clsName, ClassLoader ldr, String fileName) {
+    public void checkHasClassName(String clsName, ClassLoader ldr, String fileName) {
         if (!map.containsKey(clsName.hashCode()))
             throw new IgniteException("Failed to read class name from class names properties file. " +
                 "Make sure class names properties file packaged with ignite binaries is not corrupted " +

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/a515ec91/modules/core/src/main/java/org/apache/ignite/internal/MarshallerContextImpl.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/MarshallerContextImpl.java b/modules/core/src/main/java/org/apache/ignite/internal/MarshallerContextImpl.java
index 4b0251d..7940e95 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/MarshallerContextImpl.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/MarshallerContextImpl.java
@@ -20,9 +20,11 @@ package org.apache.ignite.internal;
 import org.apache.ignite.*;
 import org.apache.ignite.internal.processors.cache.*;
 import org.apache.ignite.internal.util.typedef.internal.*;
+import org.apache.ignite.plugin.*;
 
 import javax.cache.event.*;
 import java.io.*;
+import java.util.*;
 import java.util.concurrent.*;
 
 /**
@@ -45,9 +47,12 @@ public class MarshallerContextImpl extends MarshallerContextAdapter {
     private int failedCnt;
 
     /**
+     * @param plugins Plugins.
      * @throws IgniteCheckedException In case of error.
      */
-    public MarshallerContextImpl() throws IgniteCheckedException {
+    public MarshallerContextImpl(List<PluginProvider> plugins) throws IgniteCheckedException {
+        super(plugins);
+
         workDir = U.resolveWorkDirectory("marshaller", false);
     }
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/a515ec91/modules/core/src/main/java/org/apache/ignite/internal/client/marshaller/optimized/GridClientOptimizedMarshaller.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/client/marshaller/optimized/GridClientOptimizedMarshaller.java b/modules/core/src/main/java/org/apache/ignite/internal/client/marshaller/optimized/GridClientOptimizedMarshaller.java
index 254962a..7c2bd2f 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/client/marshaller/optimized/GridClientOptimizedMarshaller.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/client/marshaller/optimized/GridClientOptimizedMarshaller.java
@@ -100,6 +100,11 @@ public class GridClientOptimizedMarshaller implements GridClientMarshaller {
     /**
      */
     private static class ClientMarshallerContext extends MarshallerContextAdapter {
+        /** */
+        public ClientMarshallerContext() {
+            super(null);
+        }
+
         /** {@inheritDoc} */
         @Override protected boolean registerClassName(int id, String clsName) {
             throw new UnsupportedOperationException(clsName);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/a515ec91/modules/core/src/main/java/org/apache/ignite/internal/processors/plugin/IgnitePluginProcessor.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/plugin/IgnitePluginProcessor.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/plugin/IgnitePluginProcessor.java
index 8f2cc51..ecc6924 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/plugin/IgnitePluginProcessor.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/plugin/IgnitePluginProcessor.java
@@ -48,26 +48,14 @@ public class IgnitePluginProcessor extends GridProcessorAdapter {
      *
      * @param ctx Kernal context.
      * @param cfg Ignite configuration.
+     * @param providers Plugin providers.
      */
     @SuppressWarnings("TypeMayBeWeakened")
-    public IgnitePluginProcessor(GridKernalContext ctx, IgniteConfiguration cfg) {
+    public IgnitePluginProcessor(GridKernalContext ctx, IgniteConfiguration cfg, List<PluginProvider> providers) {
         super(ctx);
 
         ExtensionRegistryImpl registry = new ExtensionRegistryImpl();
 
-        List<PluginProvider> providers = AccessController.doPrivileged(new PrivilegedAction<List<PluginProvider>>() {
-            @Override public List<PluginProvider> run() {
-                List<PluginProvider> providers = new ArrayList<>();
-
-                ServiceLoader<PluginProvider> ldr = ServiceLoader.load(PluginProvider.class);
-
-                for (PluginProvider provider : ldr)
-                    providers.add(provider);
-
-                return providers;
-            }
-        });
-
         for (PluginProvider provider : providers) {
             GridPluginContext pluginCtx = new GridPluginContext(ctx, cfg);
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/a515ec91/modules/core/src/test/java/org/apache/ignite/marshaller/MarshallerContextTestImpl.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/marshaller/MarshallerContextTestImpl.java b/modules/core/src/test/java/org/apache/ignite/marshaller/MarshallerContextTestImpl.java
index 4164fda..00d1f43 100644
--- a/modules/core/src/test/java/org/apache/ignite/marshaller/MarshallerContextTestImpl.java
+++ b/modules/core/src/test/java/org/apache/ignite/marshaller/MarshallerContextTestImpl.java
@@ -19,8 +19,10 @@ package org.apache.ignite.marshaller;
 
 import org.apache.ignite.*;
 import org.apache.ignite.internal.*;
+import org.apache.ignite.plugin.*;
 import org.jsr166.*;
 
+import java.util.*;
 import java.util.concurrent.*;
 
 /**
@@ -30,6 +32,22 @@ public class MarshallerContextTestImpl extends MarshallerContextAdapter {
     /** */
     private final static ConcurrentMap<Integer, String> map = new ConcurrentHashMap8<>();
 
+    /**
+     * Initializes context.
+     *
+     * @param plugins Plugins.
+     */
+    public MarshallerContextTestImpl(List<PluginProvider> plugins) {
+        super(plugins);
+    }
+
+    /**
+     * Initializes context.
+     */
+    public MarshallerContextTestImpl() {
+        super(null);
+    }
+
     /** {@inheritDoc} */
     @Override protected boolean registerClassName(int id, String clsName) throws IgniteCheckedException {
         String oldClsName = map.putIfAbsent(id, clsName);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/a515ec91/modules/core/src/test/java/org/apache/ignite/testframework/junits/GridTestKernalContext.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/testframework/junits/GridTestKernalContext.java b/modules/core/src/test/java/org/apache/ignite/testframework/junits/GridTestKernalContext.java
index 6b7a7f9..37948d9 100644
--- a/modules/core/src/test/java/org/apache/ignite/testframework/junits/GridTestKernalContext.java
+++ b/modules/core/src/test/java/org/apache/ignite/testframework/junits/GridTestKernalContext.java
@@ -45,6 +45,7 @@ public class GridTestKernalContext extends GridKernalContextImpl {
             null,
             null,
             null,
+            null,
             null);
 
         GridTestUtils.setFieldValue(grid(), "cfg", config());


[46/50] incubator-ignite git commit: Merge branches 'ignite-883-1' and 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-883-1

Posted by vo...@apache.org.
Merge branches 'ignite-883-1' and 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-883-1

Conflicts:
	modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
	modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java


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

Branch: refs/heads/ignite-gg-10411
Commit: 4a1349126eb3b7a78cb849f2e8d4b772ced43fe1
Parents: ca7032e 0907338
Author: Yakov Zhdanov <yz...@gridgain.com>
Authored: Mon Jun 15 10:45:25 2015 +0300
Committer: Yakov Zhdanov <yz...@gridgain.com>
Committed: Mon Jun 15 10:45:25 2015 +0300

----------------------------------------------------------------------
 .../datastructures/DataStructuresProcessor.java | 67 +++++++++++++++++++-
 .../rest/client/message/GridRouterRequest.java  | 18 ++++++
 .../rest/client/message/GridRouterResponse.java | 18 ++++++
 .../testsuites/IgniteCacheTestSuite4.java       |  4 +-
 .../ignite/tools/classgen/ClassesGenerator.java | 12 ++++
 5 files changed, 114 insertions(+), 5 deletions(-)
----------------------------------------------------------------------



[06/50] incubator-ignite git commit: ignite-998

Posted by vo...@apache.org.
ignite-998


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

Branch: refs/heads/ignite-gg-10411
Commit: c47438e8d2ea734218bcd9c14945ce43456269ce
Parents: af120a7
Author: sboikov <sb...@gridgain.com>
Authored: Wed Jun 10 14:24:24 2015 +0300
Committer: sboikov <sb...@gridgain.com>
Committed: Wed Jun 10 15:23:37 2015 +0300

----------------------------------------------------------------------
 .../ignite/spi/discovery/tcp/ServerImpl.java    |  38 +------
 .../tcp/TcpClientDiscoverySpiSelfTest.java      | 102 ++++++++++++++++++-
 2 files changed, 103 insertions(+), 37 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/c47438e8/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java
index 5aceaae..44374db 100644
--- a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java
+++ b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java
@@ -1752,6 +1752,9 @@ class ServerImpl extends TcpDiscoveryImpl {
         @Nullable Collection<TcpDiscoveryAbstractMessage> messages(IgniteUuid lastMsgId) {
             assert lastMsgId != null;
 
+            if (msgs.isEmpty())
+                return Collections.emptyList();
+
             Collection<TcpDiscoveryAbstractMessage> cp = new ArrayList<>(msgs.size());
 
             boolean skip = true;
@@ -1769,30 +1772,6 @@ class ServerImpl extends TcpDiscoveryImpl {
         }
 
         /**
-         * Resets pending messages.
-         *
-         * @param msgs Message.
-         * @param discardId Discarded message ID.
-         */
-        void reset(@Nullable Collection<TcpDiscoveryAbstractMessage> msgs, @Nullable IgniteUuid discardId) {
-            this.msgs.clear();
-
-            if (msgs != null)
-                this.msgs.addAll(msgs);
-
-            this.discardId = discardId;
-        }
-
-        /**
-         * Clears pending messages.
-         */
-        void clear() {
-            msgs.clear();
-
-            discardId = null;
-        }
-
-        /**
          * Discards message with provided ID and all before it.
          *
          * @param id Discarded message ID.
@@ -2921,8 +2900,7 @@ class ServerImpl extends TcpDiscoveryImpl {
                             topHist.clear();
                             topHist.putAll(msg.topologyHistory());
 
-                            // Restore pending messages.
-                            pendingMsgs.reset(msg.messages(), msg.discardedMessageId());
+                            pendingMsgs.discard(msg.discardedMessageId());
 
                             // Clear data to minimize message size.
                             msg.messages(null, null);
@@ -3180,10 +3158,6 @@ class ServerImpl extends TcpDiscoveryImpl {
                 if (log.isDebugEnabled())
                     log.debug("Removed node from topology: " + leftNode);
 
-                // Clear pending messages map.
-                if (!ring.hasRemoteNodes())
-                    pendingMsgs.clear();
-
                 long topVer;
 
                 if (locNodeCoord) {
@@ -3347,10 +3321,6 @@ class ServerImpl extends TcpDiscoveryImpl {
 
                 assert node != null;
 
-                // Clear pending messages map.
-                if (!ring.hasRemoteNodes())
-                    pendingMsgs.clear();
-
                 long topVer;
 
                 if (locNodeCoord) {

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/c47438e8/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpiSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpiSelfTest.java
index 7333020..ece898d 100644
--- a/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpiSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpiSelfTest.java
@@ -103,12 +103,17 @@ public class TcpClientDiscoverySpiSelfTest extends GridCommonAbstractTest {
     /** */
     private boolean longSockTimeouts;
 
+    /** */
+    private int maxMissedClientHbs = TcpDiscoverySpi.DFLT_MAX_MISSED_CLIENT_HEARTBEATS;
+
     /** {@inheritDoc} */
     @Override protected IgniteConfiguration getConfiguration(String gridName) throws Exception {
         IgniteConfiguration cfg = super.getConfiguration(gridName);
 
         TcpDiscoverySpi disco = new TestTcpDiscoverySpi();
 
+        disco.setMaxMissedClientHeartbeats(maxMissedClientHbs);
+
         if (gridName.startsWith("server"))
             disco.setIpFinder(IP_FINDER);
         else if (gridName.startsWith("client")) {
@@ -494,6 +499,96 @@ public class TcpClientDiscoverySpiSelfTest extends GridCommonAbstractTest {
     /**
      * @throws Exception If failed.
      */
+    public void testClientReconnectTopologyChange1() throws Exception {
+        maxMissedClientHbs = 100;
+
+        clientsPerSrv = 1;
+
+        startServerNodes(2);
+        startClientNodes(1);
+
+        checkNodes(2, 1);
+
+        srvLeftLatch = new CountDownLatch(3);
+        srvFailedLatch = new CountDownLatch(1);
+
+        attachListeners(2, 0);
+
+        Ignite ignite = G.ignite("client-0");
+
+        TestTcpDiscoverySpi spi = ((TestTcpDiscoverySpi)ignite.configuration().getDiscoverySpi());
+
+        spi.pauseAll();
+
+        try {
+            spi.brakeConnection();
+
+            Ignite g = startGrid("server-" + srvIdx.getAndIncrement());
+
+            g.close();
+
+            spi.resumeAll();
+
+            assertFalse(srvFailedLatch.await(2000, TimeUnit.MILLISECONDS));
+
+            assertEquals(1L, srvLeftLatch.getCount());
+
+            checkNodes(2, 1);
+        }
+        finally {
+            spi.resumeAll();
+        }
+    }
+
+    /**
+     * @throws Exception If failed.
+     */
+    public void testClientReconnectTopologyChange2() throws Exception {
+        fail("https://issues.apache.org/jira/browse/IGNITE-998");
+
+        maxMissedClientHbs = 100;
+
+        clientsPerSrv = 1;
+
+        startServerNodes(1);
+        startClientNodes(1);
+
+        checkNodes(1, 1);
+
+        srvLeftLatch = new CountDownLatch(2);
+        srvFailedLatch = new CountDownLatch(1);
+
+        attachListeners(1, 0);
+
+        Ignite ignite = G.ignite("client-0");
+
+        TestTcpDiscoverySpi spi = ((TestTcpDiscoverySpi)ignite.configuration().getDiscoverySpi());
+
+        spi.pauseAll();
+
+        try {
+            spi.brakeConnection();
+
+            Ignite g = startGrid("server-" + srvIdx.getAndIncrement());
+
+            g.close();
+
+            spi.resumeAll();
+
+            assertFalse(srvFailedLatch.await(2000, TimeUnit.MILLISECONDS));
+
+            assertEquals(1L, srvLeftLatch.getCount());
+
+            checkNodes(1, 1);
+        }
+        finally {
+            spi.resumeAll();
+        }
+    }
+
+    /**
+     * @throws Exception If failed.
+     */
     public void testGetMissedMessagesOnReconnect() throws Exception {
         clientsPerSrv = 1;
 
@@ -731,8 +826,6 @@ public class TcpClientDiscoverySpiSelfTest extends GridCommonAbstractTest {
     }
 
     /**
-     * TODO: IGNITE-587.
-     *
      * @throws Exception If failed.
      */
     public void testDataExchangeFromClient() throws Exception {
@@ -740,6 +833,7 @@ public class TcpClientDiscoverySpiSelfTest extends GridCommonAbstractTest {
     }
 
     /**
+     * @param masterName Node name
      * @throws Exception If failed.
      */
     private void testDataExchange(String masterName) throws Exception {
@@ -890,7 +984,8 @@ public class TcpClientDiscoverySpiSelfTest extends GridCommonAbstractTest {
     }
 
     /**
-     * @param clientIdx Index.
+     * @param clientIdx Client index.
+     * @param srvIdx Server index.
      * @throws Exception In case of error.
      */
     private void setClientRouter(int clientIdx, int srvIdx) throws Exception {
@@ -948,6 +1043,7 @@ public class TcpClientDiscoverySpiSelfTest extends GridCommonAbstractTest {
     /**
      * @param srvCnt Number of server nodes.
      * @param clientCnt Number of client nodes.
+     * @throws Exception If failed.
      */
     private void attachListeners(int srvCnt, int clientCnt) throws Exception {
         if (srvJoinedLatch != null) {


[19/50] incubator-ignite git commit: # ignite-883

Posted by vo...@apache.org.
# ignite-883


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

Branch: refs/heads/ignite-gg-10411
Commit: de0d61f6a3467379c168a15bbd9c4580aeebb092
Parents: 89a4f7c
Author: sboikov <sb...@gridgain.com>
Authored: Thu Jun 11 10:40:27 2015 +0300
Committer: sboikov <sb...@gridgain.com>
Committed: Thu Jun 11 17:40:01 2015 +0300

----------------------------------------------------------------------
 .../apache/ignite/internal/IgniteKernal.java    |   1 -
 .../discovery/GridDiscoveryManager.java         |   9 +-
 .../dht/preloader/GridDhtPreloader.java         |   2 +-
 .../org/apache/ignite/spi/IgniteSpiAdapter.java |  28 ++-
 .../communication/tcp/TcpCommunicationSpi.java  |   2 +-
 .../ignite/spi/discovery/tcp/ClientImpl.java    | 214 ++++++++++++-------
 .../ignite/spi/discovery/tcp/ServerImpl.java    |  64 ------
 .../spi/discovery/tcp/TcpDiscoveryImpl.java     |  66 ++++++
 .../distributed/IgniteCacheManyClientsTest.java |  87 +++++++-
 9 files changed, 323 insertions(+), 150 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/de0d61f6/modules/core/src/main/java/org/apache/ignite/internal/IgniteKernal.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/IgniteKernal.java b/modules/core/src/main/java/org/apache/ignite/internal/IgniteKernal.java
index 4f5e365..f38fee1 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/IgniteKernal.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/IgniteKernal.java
@@ -1001,7 +1001,6 @@ public class IgniteKernal implements IgniteEx, IgniteMXBean, Externalizable {
         A.notNull(cfg.getMBeanServer(), "cfg.getMBeanServer()");
         A.notNull(cfg.getGridLogger(), "cfg.getGridLogger()");
         A.notNull(cfg.getMarshaller(), "cfg.getMarshaller()");
-        A.notNull(cfg.getPublicThreadPoolSize(), "cfg.getPublicThreadPoolSize()");
         A.notNull(cfg.getUserAttributes(), "cfg.getUserAttributes()");
 
         // All SPIs should be non-null.

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/de0d61f6/modules/core/src/main/java/org/apache/ignite/internal/managers/discovery/GridDiscoveryManager.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/managers/discovery/GridDiscoveryManager.java b/modules/core/src/main/java/org/apache/ignite/internal/managers/discovery/GridDiscoveryManager.java
index 71fbc61..464110c 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/managers/discovery/GridDiscoveryManager.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/managers/discovery/GridDiscoveryManager.java
@@ -2057,17 +2057,22 @@ public class GridDiscoveryManager extends GridManagerAdapter<DiscoverySpi> {
         private final AffinityTopologyVersion topVer;
 
         /** */
+        @GridToStringExclude
         private final DiscoCache discoCache;
 
         /**
          * @param topVer Topology version.
          * @param discoCache Disco cache.
          */
-        private Snapshot(AffinityTopologyVersion topVer,
-            DiscoCache discoCache) {
+        private Snapshot(AffinityTopologyVersion topVer, DiscoCache discoCache) {
             this.topVer = topVer;
             this.discoCache = discoCache;
         }
+
+        /** {@inheritDoc} */
+        @Override public String toString() {
+            return S.toString(Snapshot.class, this);
+        }
     }
 
     /** Cache for discovery collections. */

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/de0d61f6/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPreloader.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPreloader.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPreloader.java
index 51010ce..0355bb3 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPreloader.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPreloader.java
@@ -102,7 +102,7 @@ public class GridDhtPreloader extends GridCachePreloaderAdapter {
                 boolean set = topVer.setIfGreater(e.topologyVersion());
 
                 assert set : "Have you configured TcpDiscoverySpi for your in-memory data grid? [newVer=" +
-                    e.topologyVersion() + ", curVer=" + topVer.get() + ']';
+                    e.topologyVersion() + ", curVer=" + topVer.get() + ", evt=" + e + ']';
 
                 if (e.type() == EVT_NODE_LEFT || e.type() == EVT_NODE_FAILED) {
                     for (GridDhtAssignmentFetchFuture fut : pendingAssignmentFetchFuts.values())

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/de0d61f6/modules/core/src/main/java/org/apache/ignite/spi/IgniteSpiAdapter.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/spi/IgniteSpiAdapter.java b/modules/core/src/main/java/org/apache/ignite/spi/IgniteSpiAdapter.java
index 6e7a706..476f8a8 100644
--- a/modules/core/src/main/java/org/apache/ignite/spi/IgniteSpiAdapter.java
+++ b/modules/core/src/main/java/org/apache/ignite/spi/IgniteSpiAdapter.java
@@ -585,8 +585,32 @@ public abstract class IgniteSpiAdapter implements IgniteSpi, IgniteSpiManagement
         GridDummySpiContext(ClusterNode locNode, boolean stopping, @Nullable IgniteSpiContext spiCtx) {
             this.locNode = locNode;
             this.stopping = stopping;
-            this.msgFactory = spiCtx != null ? spiCtx.messageFactory() : null;
-            this.msgFormatter = spiCtx != null ? spiCtx.messageFormatter() : null;
+
+            MessageFactory msgFactory0 = spiCtx != null ? spiCtx.messageFactory() : null;
+            MessageFormatter msgFormatter0 = spiCtx != null ? spiCtx.messageFormatter() : null;
+
+            if (msgFactory0 == null) {
+                msgFactory0 = new MessageFactory() {
+                    @Nullable @Override public Message create(byte type) {
+                        throw new IgniteException("Failed to read message, node is not started.");
+                    }
+                };
+            }
+
+            if (msgFormatter0 == null) {
+                msgFormatter0 = new MessageFormatter() {
+                    @Override public MessageWriter writer() {
+                        throw new IgniteException("Failed to write message, node is not started.");
+                    }
+
+                    @Override public MessageReader reader(MessageFactory factory) {
+                        throw new IgniteException("Failed to read message, node is not started.");
+                    }
+                };
+            }
+
+            this.msgFactory = msgFactory0;
+            this.msgFormatter = msgFormatter0;
         }
 
         /** {@inheritDoc} */

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/de0d61f6/modules/core/src/main/java/org/apache/ignite/spi/communication/tcp/TcpCommunicationSpi.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/spi/communication/tcp/TcpCommunicationSpi.java b/modules/core/src/main/java/org/apache/ignite/spi/communication/tcp/TcpCommunicationSpi.java
index a661965..f19e25b 100644
--- a/modules/core/src/main/java/org/apache/ignite/spi/communication/tcp/TcpCommunicationSpi.java
+++ b/modules/core/src/main/java/org/apache/ignite/spi/communication/tcp/TcpCommunicationSpi.java
@@ -2028,7 +2028,7 @@ public class TcpCommunicationSpi extends IgniteSpiAdapter
 
                     if (X.hasCause(e, SocketTimeoutException.class))
                         LT.warn(log, null, "Connect timed out (consider increasing 'connTimeout' " +
-                            "configuration property) [addr=" + addr + ']');
+                            "configuration property) [addr=" + addr + ", connTimeout" + connTimeout + ']');
 
                     if (errs == null)
                         errs = new IgniteCheckedException("Failed to connect to node (is node still alive?). " +

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/de0d61f6/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ClientImpl.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ClientImpl.java b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ClientImpl.java
index d064c8d..23297ed 100644
--- a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ClientImpl.java
+++ b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ClientImpl.java
@@ -195,7 +195,7 @@ class ClientImpl extends TcpDiscoveryImpl {
                     U.warn(log, "Failed to left node: timeout [nodeId=" + locNode + ']');
             }
             catch (InterruptedException ignored) {
-
+                // No-op.
             }
         }
 
@@ -282,7 +282,7 @@ class ClientImpl extends TcpDiscoveryImpl {
             return false;
         }
         catch (IgniteCheckedException e) {
-            throw new IgniteSpiException(e); // Should newer occur
+            throw new IgniteSpiException(e); // Should newer occur.
         }
     }
 
@@ -347,7 +347,10 @@ class ClientImpl extends TcpDiscoveryImpl {
     }
 
     /**
+     * @param recon {@code True} if reconnects.
      * @return Opened socket or {@code null} if timeout.
+     * @throws InterruptedException If interrupted.
+     * @throws IgniteSpiException If failed.
      * @see TcpDiscoverySpi#joinTimeout
      */
     @SuppressWarnings("BusyWait")
@@ -387,71 +390,152 @@ class ClientImpl extends TcpDiscoveryImpl {
 
                 InetSocketAddress addr = it.next();
 
-                Socket sock = null;
+                T2<Socket, Integer> sockAndRes = sendJoinRequest(recon, addr);
 
-                try {
-                    long ts = U.currentTimeMillis();
+                if (sockAndRes == null) {
+                    it.remove();
 
-                    IgniteBiTuple<Socket, UUID> t = initConnection(addr);
+                    continue;
+                }
 
-                    sock = t.get1();
+                assert sockAndRes.get1() != null;
+                assert sockAndRes.get2() != null;
 
-                    UUID rmtNodeId = t.get2();
+                Socket sock = sockAndRes.get1();
 
-                    spi.stats.onClientSocketInitialized(U.currentTimeMillis() - ts);
+                switch (sockAndRes.get2()) {
+                    case RES_OK:
+                        return sock;
 
-                    locNode.clientRouterNodeId(rmtNodeId);
+                    case RES_CONTINUE_JOIN:
+                    case RES_WAIT:
+                        U.closeQuiet(sock);
 
-                    TcpDiscoveryAbstractMessage msg = recon ?
-                        new TcpDiscoveryClientReconnectMessage(getLocalNodeId(), rmtNodeId,
-                            lastMsgId) :
-                        new TcpDiscoveryJoinRequestMessage(locNode, spi.collectExchangeData(getLocalNodeId()));
+                        break;
 
-                    msg.client(true);
+                    default:
+                        if (log.isDebugEnabled())
+                            log.debug("Received unexpected response to join request: " + sockAndRes.get2());
 
-                    spi.writeToSocket(sock, msg);
+                        U.closeQuiet(sock);
+                }
+            }
 
-                    int res = spi.readReceipt(sock, spi.ackTimeout);
+            if (addrs.isEmpty()) {
+                if (spi.joinTimeout > 0 && (U.currentTimeMillis() - startTime) > spi.joinTimeout)
+                    return null;
 
-                    switch (res) {
-                        case RES_OK:
-                            return sock;
+                Thread.sleep(2000);
 
-                        case RES_CONTINUE_JOIN:
-                        case RES_WAIT:
-                            U.closeQuiet(sock);
+                U.warn(log, "Failed to connect to any address from IP finder (will retry to join topology " +
+                    "in 2000ms): " + addrs0);
+            }
+        }
+    }
 
-                            break;
+    /**
+     * @param recon {@code True} if reconnects.
+     * @param addr Address.
+     * @return Socket and connect response.
+     */
+    @Nullable private T2<Socket, Integer> sendJoinRequest(boolean recon, InetSocketAddress addr) {
+        assert addr != null;
 
-                        default:
-                            if (log.isDebugEnabled())
-                                log.debug("Received unexpected response to join request: " + res);
+        Collection<Throwable> errs = null;
 
-                            U.closeQuiet(sock);
-                    }
-                }
-                catch (IOException | IgniteCheckedException e) {
-                    if (log.isDebugEnabled())
-                        U.error(log, "Failed to establish connection with address: " + addr, e);
+        long ackTimeout0 = spi.ackTimeout;
 
-                    U.closeQuiet(sock);
+        int connectAttempts = 1;
 
-                    it.remove();
-                }
+        UUID locNodeId = getLocalNodeId();
+
+        for (int i = 0; i < spi.reconCnt; i++) {
+            boolean openSock = false;
+
+            Socket sock = null;
+
+            try {
+                long tstamp = U.currentTimeMillis();
+
+                sock = spi.openSocket(addr);
+
+                openSock = true;
+
+                TcpDiscoveryHandshakeRequest req = new TcpDiscoveryHandshakeRequest(locNodeId);
+
+                req.client(true);
+
+                spi.writeToSocket(sock, req);
+
+                TcpDiscoveryHandshakeResponse res = spi.readMessage(sock, null, ackTimeout0);
+
+                UUID rmtNodeId = res.creatorNodeId();
+
+                assert rmtNodeId != null;
+                assert !getLocalNodeId().equals(rmtNodeId);
+
+                spi.stats.onClientSocketInitialized(U.currentTimeMillis() - tstamp);
+
+                locNode.clientRouterNodeId(rmtNodeId);
+
+                tstamp = U.currentTimeMillis();
+
+                TcpDiscoveryAbstractMessage msg = recon ?
+                    new TcpDiscoveryClientReconnectMessage(getLocalNodeId(), rmtNodeId, lastMsgId) :
+                    new TcpDiscoveryJoinRequestMessage(locNode, spi.collectExchangeData(getLocalNodeId()));
+
+                msg.client(true);
+
+                spi.writeToSocket(sock, msg);
+
+                spi.stats.onMessageSent(msg, U.currentTimeMillis() - tstamp);
+
+                if (log.isDebugEnabled())
+                    log.debug("Message has been sent to address [msg=" + msg + ", addr=" + addr +
+                        ", rmtNodeId=" + rmtNodeId + ']');
+
+                return new T2<>(sock, spi.readReceipt(sock, ackTimeout0));
             }
+            catch (IOException | IgniteCheckedException e) {
+                U.closeQuiet(sock);
 
-            if (addrs.isEmpty()) {
-                U.warn(log, "Failed to connect to any address from IP finder (will retry to join topology " +
-                    "in 2000ms): " + addrs0);
+                if (log.isDebugEnabled())
+                    log.error("Exception on joining: " + e.getMessage(), e);
 
-                if (spi.joinTimeout > 0 && (U.currentTimeMillis() - startTime) > spi.joinTimeout)
-                    return null;
+                onException("Exception on joining: " + e.getMessage(), e);
 
-                Thread.sleep(2000);
+                if (errs == null)
+                    errs = new ArrayList<>();
+
+                errs.add(e);
+
+                if (!openSock) {
+                    // Reconnect for the second time, if connection is not established.
+                    if (connectAttempts < 2) {
+                        connectAttempts++;
+
+                        continue;
+                    }
+
+                    break; // Don't retry if we can not establish connection.
+                }
+
+                if (e instanceof SocketTimeoutException || X.hasCause(e, SocketTimeoutException.class)) {
+                    ackTimeout0 *= 2;
+
+                    if (!checkAckTimeout(ackTimeout0))
+                        break;
+                }
             }
         }
+
+        if (log.isDebugEnabled())
+            log.debug("Failed to join to address [addr=" + addr + ", recon=" + recon + ", errs=" + errs + ']');
+
+        return null;
     }
 
+
     /**
      * @param topVer New topology version.
      * @return Latest topology snapshot.
@@ -493,33 +577,6 @@ class ClientImpl extends TcpDiscoveryImpl {
         return allNodes;
     }
 
-    /**
-     * @param addr Address.
-     * @return Remote node ID.
-     * @throws IOException In case of I/O error.
-     * @throws IgniteCheckedException In case of other error.
-     */
-    private IgniteBiTuple<Socket, UUID> initConnection(InetSocketAddress addr) throws IOException, IgniteCheckedException {
-        assert addr != null;
-
-        Socket sock = spi.openSocket(addr);
-
-        TcpDiscoveryHandshakeRequest req = new TcpDiscoveryHandshakeRequest(getLocalNodeId());
-
-        req.client(true);
-
-        spi.writeToSocket(sock, req);
-
-        TcpDiscoveryHandshakeResponse res = spi.readMessage(sock, null, spi.ackTimeout);
-
-        UUID nodeId = res.creatorNodeId();
-
-        assert nodeId != null;
-        assert !getLocalNodeId().equals(nodeId);
-
-        return F.t(sock, nodeId);
-    }
-
     /** {@inheritDoc} */
     @Override void simulateNodeFailure() {
         U.warn(log, "Simulating client node failure: " + getLocalNodeId());
@@ -736,7 +793,7 @@ class ClientImpl extends TcpDiscoveryImpl {
         }
 
         /**
-         *
+         * @return {@code True} if connection is alive.
          */
         public boolean isOnline() {
             synchronized (mux) {
@@ -780,7 +837,8 @@ class ClientImpl extends TcpDiscoveryImpl {
                 }
                 catch (IOException e) {
                     if (log.isDebugEnabled())
-                        U.error(log, "Failed to send node left message (will stop anyway) [sock=" + sock + ']', e);
+                        U.error(log, "Failed to send node left message (will stop anyway) " +
+                            "[sock=" + sock + ", msg=" + msg + ']', e);
 
                     U.closeQuiet(sock);
 
@@ -909,7 +967,7 @@ class ClientImpl extends TcpDiscoveryImpl {
                 final Socket sock = joinTopology(false);
 
                 if (sock == null) {
-                    joinErr = new IgniteSpiException("Join process timed out");
+                    joinErr = new IgniteSpiException("Join process timed out.");
 
                     joinLatch.countDown();
 
@@ -934,8 +992,9 @@ class ClientImpl extends TcpDiscoveryImpl {
 
                     if (msg == JOIN_TIMEOUT) {
                         if (joinLatch.getCount() > 0) {
-                            joinErr = new IgniteSpiException("Join process timed out [sock=" + sock +
-                                ", timeout=" + spi.netTimeout + ']');
+                            joinErr = new IgniteSpiException("Join process timed out, did not receive response for " +
+                                "join request (consider increasing 'networkTimeout' configuration property) " +
+                                "[networkTimeout=" + spi.netTimeout + ", sock=" + sock +']');
 
                             joinLatch.countDown();
 
@@ -1027,7 +1086,7 @@ class ClientImpl extends TcpDiscoveryImpl {
 
                 if (joinLatch.getCount() > 0) {
                     // This should not occurs.
-                    joinErr = new IgniteSpiException("Some error occurs in joinig process");
+                    joinErr = new IgniteSpiException("Some error occur in join process.");
 
                     joinLatch.countDown();
                 }
@@ -1236,8 +1295,9 @@ class ClientImpl extends TcpDiscoveryImpl {
             if (spi.getSpiContext().isStopping()) {
                 if (!getLocalNodeId().equals(msg.creatorNodeId()) && getLocalNodeId().equals(msg.failedNodeId())) {
                     if (leaveLatch.getCount() > 0) {
-                        log.debug("Remote node fail this node while node is stopping [locNode=" + getLocalNodeId()
-                            + ", rmtNode=" + msg.creatorNodeId() + ']');
+                        if (log.isDebugEnabled())
+                            log.debug("Remote node fail this node while node is stopping [locNode=" + getLocalNodeId()
+                                + ", rmtNode=" + msg.creatorNodeId() + ']');
 
                         leaveLatch.countDown();
                     }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/de0d61f6/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java
index 5aceaae..311c783 100644
--- a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java
+++ b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java
@@ -125,16 +125,6 @@ class ServerImpl extends TcpDiscoveryImpl {
     private final ConcurrentMap<InetSocketAddress, IgniteInternalFuture<IgniteBiTuple<UUID, Boolean>>> pingMap =
         new ConcurrentHashMap8<>();
 
-    /** Debug mode. */
-    private boolean debugMode;
-
-    /** Debug messages history. */
-    private int debugMsgHist = 512;
-
-    /** Received messages. */
-    @SuppressWarnings("FieldAccessedSynchronizedAndUnsynchronized")
-    private ConcurrentLinkedDeque<String> debugLog;
-
     /**
      * @param adapter Adapter.
      */
@@ -142,24 +132,6 @@ class ServerImpl extends TcpDiscoveryImpl {
         super(adapter);
     }
 
-    /**
-     * This method is intended for troubleshooting purposes only.
-     *
-     * @param debugMode {code True} to start SPI in debug mode.
-     */
-    public void setDebugMode(boolean debugMode) {
-        this.debugMode = debugMode;
-    }
-
-    /**
-     * This method is intended for troubleshooting purposes only.
-     *
-     * @param debugMsgHist Message history log size.
-     */
-    public void setDebugMessageHistory(int debugMsgHist) {
-        this.debugMsgHist = debugMsgHist;
-    }
-
     /** {@inheritDoc} */
     @Override public String getSpiState() {
         synchronized (mux) {
@@ -1060,23 +1032,6 @@ class ServerImpl extends TcpDiscoveryImpl {
     }
 
     /**
-     * @param ackTimeout Acknowledgement timeout.
-     * @return {@code True} if acknowledgement timeout is less or equal to
-     * maximum acknowledgement timeout, {@code false} otherwise.
-     */
-    private boolean checkAckTimeout(long ackTimeout) {
-        if (ackTimeout > spi.maxAckTimeout) {
-            LT.warn(log, null, "Acknowledgement timeout is greater than maximum acknowledgement timeout " +
-                "(consider increasing 'maxAckTimeout' configuration property) " +
-                "[ackTimeout=" + ackTimeout + ", maxAckTimeout=" + spi.maxAckTimeout + ']');
-
-            return false;
-        }
-
-        return true;
-    }
-
-    /**
      * Notify external listener on discovery event.
      *
      * @param type Discovery event type. See {@link org.apache.ignite.events.DiscoveryEvent} for more details.
@@ -1422,25 +1377,6 @@ class ServerImpl extends TcpDiscoveryImpl {
 
     /**
      * @param msg Message.
-     */
-    private void debugLog(String msg) {
-        assert debugMode;
-
-        String msg0 = new SimpleDateFormat("[HH:mm:ss,SSS]").format(new Date(System.currentTimeMillis())) +
-            '[' + Thread.currentThread().getName() + "][" + getLocalNodeId() +
-            "-" + locNode.internalOrder() + "] " +
-            msg;
-
-        debugLog.add(msg0);
-
-        int delta = debugLog.size() - debugMsgHist;
-
-        for (int i = 0; i < delta && debugLog.size() > debugMsgHist; i++)
-            debugLog.poll();
-    }
-
-    /**
-     * @param msg Message.
      * @return {@code True} if recordable in debug mode.
      */
     private boolean recordable(TcpDiscoveryAbstractMessage msg) {

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/de0d61f6/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoveryImpl.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoveryImpl.java b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoveryImpl.java
index b7e9e53..94097c9 100644
--- a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoveryImpl.java
+++ b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoveryImpl.java
@@ -26,7 +26,9 @@ import org.apache.ignite.spi.discovery.*;
 import org.apache.ignite.spi.discovery.tcp.internal.*;
 import org.jetbrains.annotations.*;
 
+import java.text.*;
 import java.util.*;
+import java.util.concurrent.*;
 
 /**
  *
@@ -50,6 +52,16 @@ abstract class TcpDiscoveryImpl {
     /** */
     protected TcpDiscoveryNode locNode;
 
+    /** Debug mode. */
+    protected boolean debugMode;
+
+    /** Debug messages history. */
+    private int debugMsgHist = 512;
+
+    /** Received messages. */
+    @SuppressWarnings("FieldAccessedSynchronizedAndUnsynchronized")
+    protected ConcurrentLinkedDeque<String> debugLog;
+
     /**
      * @param spi Adapter.
      */
@@ -60,6 +72,43 @@ abstract class TcpDiscoveryImpl {
     }
 
     /**
+     * This method is intended for troubleshooting purposes only.
+     *
+     * @param debugMode {code True} to start SPI in debug mode.
+     */
+    public void setDebugMode(boolean debugMode) {
+        this.debugMode = debugMode;
+    }
+
+    /**
+     * This method is intended for troubleshooting purposes only.
+     *
+     * @param debugMsgHist Message history log size.
+     */
+    public void setDebugMessageHistory(int debugMsgHist) {
+        this.debugMsgHist = debugMsgHist;
+    }
+
+    /**
+     * @param msg Message.
+     */
+    protected void debugLog(String msg) {
+        assert debugMode;
+
+        String msg0 = new SimpleDateFormat("[HH:mm:ss,SSS]").format(new Date(System.currentTimeMillis())) +
+            '[' + Thread.currentThread().getName() + "][" + getLocalNodeId() +
+            "-" + locNode.internalOrder() + "] " +
+            msg;
+
+        debugLog.add(msg0);
+
+        int delta = debugLog.size() - debugMsgHist;
+
+        for (int i = 0; i < delta && debugLog.size() > debugMsgHist; i++)
+            debugLog.poll();
+    }
+
+    /**
      * @return Local node ID.
      */
     public UUID getLocalNodeId() {
@@ -209,4 +258,21 @@ abstract class TcpDiscoveryImpl {
             }
         }
     }
+
+    /**
+     * @param ackTimeout Acknowledgement timeout.
+     * @return {@code True} if acknowledgement timeout is less or equal to
+     * maximum acknowledgement timeout, {@code false} otherwise.
+     */
+    protected boolean checkAckTimeout(long ackTimeout) {
+        if (ackTimeout > spi.maxAckTimeout) {
+            LT.warn(log, null, "Acknowledgement timeout is greater than maximum acknowledgement timeout " +
+                "(consider increasing 'maxAckTimeout' configuration property) " +
+                "[ackTimeout=" + ackTimeout + ", maxAckTimeout=" + spi.maxAckTimeout + ']');
+
+            return false;
+        }
+
+        return true;
+    }
 }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/de0d61f6/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java
index 24ebb7c..77ddd40 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java
@@ -18,15 +18,17 @@
 package org.apache.ignite.internal.processors.cache.distributed;
 
 import org.apache.ignite.*;
-import org.apache.ignite.cache.*;
 import org.apache.ignite.configuration.*;
 import org.apache.ignite.internal.*;
+import org.apache.ignite.internal.util.typedef.*;
+import org.apache.ignite.spi.communication.tcp.*;
 import org.apache.ignite.spi.discovery.tcp.*;
 import org.apache.ignite.spi.discovery.tcp.ipfinder.*;
 import org.apache.ignite.spi.discovery.tcp.ipfinder.vm.*;
 import org.apache.ignite.testframework.*;
 import org.apache.ignite.testframework.junits.common.*;
 
+import java.util.*;
 import java.util.concurrent.*;
 import java.util.concurrent.atomic.*;
 
@@ -54,6 +56,12 @@ public class IgniteCacheManyClientsTest extends GridCommonAbstractTest {
     @Override protected IgniteConfiguration getConfiguration(String gridName) throws Exception {
         IgniteConfiguration cfg = super.getConfiguration(gridName);
 
+        cfg.setConnectorConfiguration(null);
+        cfg.setPeerClassLoadingEnabled(false);
+        cfg.setTimeServerPortRange(200);
+
+        ((TcpCommunicationSpi)cfg.getCommunicationSpi()).setLocalPortRange(200);
+
         ((TcpDiscoverySpi)cfg.getDiscoverySpi()).setIpFinder(ipFinder);
 
         if (!clientDiscovery)
@@ -61,6 +69,12 @@ public class IgniteCacheManyClientsTest extends GridCommonAbstractTest {
 
         cfg.setClientMode(client);
 
+        if (client) {
+//            cfg.setPublicThreadPoolSize(1);
+//            cfg.setPeerClassLoadingThreadPoolSize(1);
+//            cfg.setIgfsThreadPoolSize(1);
+        }
+
         CacheConfiguration ccfg = new CacheConfiguration();
 
         ccfg.setCacheMode(PARTITIONED);
@@ -85,6 +99,11 @@ public class IgniteCacheManyClientsTest extends GridCommonAbstractTest {
         stopAllGrids();
     }
 
+    /** {@inheritDoc} */
+    @Override protected long getTestTimeout() {
+        return 10 * 60_000;
+    }
+
     /**
      * @throws Exception If failed.
      */
@@ -104,6 +123,66 @@ public class IgniteCacheManyClientsTest extends GridCommonAbstractTest {
     /**
      * @throws Exception If failed.
      */
+    public void testManyClientsSequentiallyClientDiscovery() throws Exception {
+        clientDiscovery = true;
+
+        manyClientsSequentially();
+    }
+
+    /**
+     * @throws Exception If failed.
+     */
+    private void manyClientsSequentially() throws Exception {
+        client = true;
+
+        List<Ignite> clients = new ArrayList<>();
+
+        final int CLIENTS = 50;
+
+        int idx = SRVS;
+
+        ThreadLocalRandom rnd = ThreadLocalRandom.current();
+
+        for (int i = 0; i < CLIENTS; i++) {
+            Ignite ignite = startGrid(idx++);
+
+            log.info("Started node: " + ignite.name());
+
+            assertTrue(ignite.configuration().isClientMode());
+
+            clients.add(ignite);
+
+            IgniteCache<Object, Object> cache = ignite.cache(null);
+
+            Integer key = rnd.nextInt(0, 1000);
+
+            cache.put(key, i);
+
+            assertNotNull(cache.get(key));
+        }
+
+        log.info("All clients started.");
+
+        assertEquals(SRVS + CLIENTS, G.allGrids().size());
+
+        long topVer = -1L;
+
+        for (Ignite ignite : G.allGrids()) {
+            assertEquals(SRVS + CLIENTS, ignite.cluster().nodes().size());
+
+            if (topVer == -1L)
+                topVer = ignite.cluster().topologyVersion();
+            else
+                assertEquals(topVer, ignite.cluster().topologyVersion());
+        }
+
+        for (Ignite client : clients)
+            client.close();
+    }
+
+    /**
+     * @throws Exception If failed.
+     */
     private void manyClientsPutGet() throws Exception {
         client = true;
 
@@ -111,7 +190,7 @@ public class IgniteCacheManyClientsTest extends GridCommonAbstractTest {
 
         final AtomicBoolean stop = new AtomicBoolean();
 
-        final int THREADS = 30;
+        final int THREADS = 50;
 
         final CountDownLatch latch = new CountDownLatch(THREADS);
 
@@ -143,6 +222,8 @@ public class IgniteCacheManyClientsTest extends GridCommonAbstractTest {
                             cache.put(key, iter++);
 
                             assertNotNull(cache.get(key));
+
+                            Thread.sleep(1);
                         }
 
                         log.info("Stopping node: " + ignite.name());
@@ -154,6 +235,8 @@ public class IgniteCacheManyClientsTest extends GridCommonAbstractTest {
 
             latch.await();
 
+            log.info("All clients started.");
+
             Thread.sleep(10_000);
 
             log.info("Stop clients.");


[31/50] incubator-ignite git commit: # ignite-883

Posted by vo...@apache.org.
# ignite-883


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

Branch: refs/heads/ignite-gg-10411
Commit: 8870a177acaa16f6757615cab6017b21aa274c01
Parents: 16f3d32
Author: sboikov <sb...@gridgain.com>
Authored: Fri Jun 12 10:05:22 2015 +0300
Committer: sboikov <sb...@gridgain.com>
Committed: Fri Jun 12 17:20:14 2015 +0300

----------------------------------------------------------------------
 .../communication/tcp/TcpCommunicationSpi.java  |   2 +-
 .../ignite/spi/discovery/tcp/ClientImpl.java    | 232 ++++++++++++-------
 .../ignite/spi/discovery/tcp/ServerImpl.java    | 170 +++++++++++---
 .../ipfinder/TcpDiscoveryIpFinderAdapter.java   |  34 ++-
 .../TcpDiscoveryMulticastIpFinder.java          |  19 +-
 .../messages/TcpDiscoveryAbstractMessage.java   |  10 +-
 .../distributed/IgniteCacheManyClientsTest.java |  65 ++++--
 .../tcp/TcpClientDiscoverySpiSelfTest.java      |  42 +++-
 8 files changed, 412 insertions(+), 162 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8870a177/modules/core/src/main/java/org/apache/ignite/spi/communication/tcp/TcpCommunicationSpi.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/spi/communication/tcp/TcpCommunicationSpi.java b/modules/core/src/main/java/org/apache/ignite/spi/communication/tcp/TcpCommunicationSpi.java
index f19e25b..9e38788 100644
--- a/modules/core/src/main/java/org/apache/ignite/spi/communication/tcp/TcpCommunicationSpi.java
+++ b/modules/core/src/main/java/org/apache/ignite/spi/communication/tcp/TcpCommunicationSpi.java
@@ -2028,7 +2028,7 @@ public class TcpCommunicationSpi extends IgniteSpiAdapter
 
                     if (X.hasCause(e, SocketTimeoutException.class))
                         LT.warn(log, null, "Connect timed out (consider increasing 'connTimeout' " +
-                            "configuration property) [addr=" + addr + ", connTimeout" + connTimeout + ']');
+                            "configuration property) [addr=" + addr + ", connTimeout=" + connTimeout + ']');
 
                     if (errs == null)
                         errs = new IgniteCheckedException("Failed to connect to node (is node still alive?). " +

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8870a177/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ClientImpl.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ClientImpl.java b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ClientImpl.java
index 23e6f88..d8108e5 100644
--- a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ClientImpl.java
+++ b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ClientImpl.java
@@ -311,7 +311,7 @@ class ClientImpl extends TcpDiscoveryImpl {
             for (ClusterNode n : rmts) {
                 rmtNodes.remove(n.id());
 
-                Collection<ClusterNode> top = updateTopologyHistory(topVer + 1);
+                Collection<ClusterNode> top = updateTopologyHistory(topVer + 1, null);
 
                 lsnr.onDiscovery(EVT_NODE_FAILED, topVer, n, top, new TreeMap<>(topHist), null);
             }
@@ -348,13 +348,14 @@ class ClientImpl extends TcpDiscoveryImpl {
 
     /**
      * @param recon {@code True} if reconnects.
+     * @param timeout Timeout.
      * @return Opened socket or {@code null} if timeout.
      * @throws InterruptedException If interrupted.
      * @throws IgniteSpiException If failed.
      * @see TcpDiscoverySpi#joinTimeout
      */
     @SuppressWarnings("BusyWait")
-    @Nullable private Socket joinTopology(boolean recon) throws IgniteSpiException, InterruptedException {
+    @Nullable private Socket joinTopology(boolean recon, long timeout) throws IgniteSpiException, InterruptedException {
         Collection<InetSocketAddress> addrs = null;
 
         long startTime = U.currentTimeMillis();
@@ -371,11 +372,11 @@ class ClientImpl extends TcpDiscoveryImpl {
                         log.debug("Resolved addresses from IP finder: " + addrs);
                 }
                 else {
-                    U.warn(log, "No addresses registered in the IP finder (will retry in 2000ms): " + spi.ipFinder);
-
-                    if (spi.joinTimeout > 0 && (U.currentTimeMillis() - startTime) > spi.joinTimeout)
+                    if (timeout > 0 && (U.currentTimeMillis() - startTime) > timeout)
                         return null;
 
+                    U.warn(log, "No addresses registered in the IP finder (will retry in 2000ms): " + spi.ipFinder);
+
                     Thread.sleep(2000);
                 }
             }
@@ -421,13 +422,13 @@ class ClientImpl extends TcpDiscoveryImpl {
             }
 
             if (addrs.isEmpty()) {
-                if (spi.joinTimeout > 0 && (U.currentTimeMillis() - startTime) > spi.joinTimeout)
+                if (timeout > 0 && (U.currentTimeMillis() - startTime) > timeout)
                     return null;
 
-                Thread.sleep(2000);
-
                 U.warn(log, "Failed to connect to any address from IP finder (will retry to join topology " +
                     "in 2000ms): " + addrs0);
+
+                Thread.sleep(2000);
             }
         }
     }
@@ -541,16 +542,17 @@ class ClientImpl extends TcpDiscoveryImpl {
 
     /**
      * @param topVer New topology version.
+     * @param msg Discovery message.
      * @return Latest topology snapshot.
      */
-    private NavigableSet<ClusterNode> updateTopologyHistory(long topVer) {
+    private NavigableSet<ClusterNode> updateTopologyHistory(long topVer, @Nullable TcpDiscoveryAbstractMessage msg) {
         this.topVer = topVer;
 
         NavigableSet<ClusterNode> allNodes = allVisibleNodes();
 
         if (!topHist.containsKey(topVer)) {
             assert topHist.isEmpty() || topHist.lastKey() == topVer - 1 :
-                "lastVer=" + topHist.lastKey() + ", newVer=" + topVer;
+                "lastVer=" + topHist.lastKey() + ", newVer=" + topVer + ", locNode=" + locNode + ", msg=" + msg;
 
             topHist.put(topVer, allNodes);
 
@@ -619,6 +621,17 @@ class ClientImpl extends TcpDiscoveryImpl {
     }
 
     /**
+     * @param err Error.
+     */
+    private void joinError(IgniteSpiException err) {
+        assert err != null;
+
+        joinErr = err;
+
+        joinLatch.countDown();
+    }
+
+    /**
      * Heartbeat sender.
      */
     private class HeartbeatSender extends TimerTask {
@@ -727,7 +740,7 @@ class ClientImpl extends TcpDiscoveryImpl {
 
                         spi.stats.onMessageReceived(msg);
 
-                        if (spi.ensured(msg))
+                        if (spi.ensured(msg) && joinLatch.getCount() == 0L)
                             lastMsgId = msg.id();
 
                         msgWorker.addMessage(msg);
@@ -866,11 +879,16 @@ class ClientImpl extends TcpDiscoveryImpl {
         /** */
         private volatile Socket sock;
 
+        /** */
+        private boolean join;
+
         /**
-         *
+         * @param join {@code True} if reconnects during join.
          */
-        protected Reconnector() {
+        protected Reconnector(boolean join) {
             super(spi.ignite().name(), "tcp-client-disco-msg-worker", log);
+
+            this.join = join;
         }
 
         /**
@@ -888,51 +906,94 @@ class ClientImpl extends TcpDiscoveryImpl {
 
             boolean success = false;
 
+            Exception err = null;
+
+            long timeout = join ? spi.joinTimeout : spi.netTimeout;
+
+            long startTime = U.currentTimeMillis();
+
             try {
-                sock = joinTopology(true);
+                while (true) {
+                    sock = joinTopology(true, timeout);
 
-                if (sock == null) {
-                    U.error(log, "Failed to reconnect to cluster: timeout.");
+                    if (sock == null) {
+                        if (join) {
+                            joinError(new IgniteSpiException("Join process timed out, connection failed and " +
+                                "failed to reconnect (consider increasing 'joinTimeout' configuration property) " +
+                                "[networkTimeout=" + spi.joinTimeout + ", sock=" + sock + ']'));
+                        }
+                        else
+                            U.error(log, "Failed to reconnect to cluster (consider increasing 'networkTimeout' " +
+                                "configuration  property) [networkTimeout=" + spi.netTimeout + ", sock=" + sock + ']');
 
-                    return;
-                }
+                        return;
+                    }
 
-                if (isInterrupted())
-                    throw new InterruptedException();
+                    if (isInterrupted())
+                        throw new InterruptedException();
 
-                InputStream in = new BufferedInputStream(sock.getInputStream());
+                    int oldTimeout = 0;
 
-                sock.setKeepAlive(true);
-                sock.setTcpNoDelay(true);
+                    try {
+                        oldTimeout = sock.getSoTimeout();
 
-                // Wait for
-                while (!isInterrupted()) {
-                    TcpDiscoveryAbstractMessage msg = spi.marsh.unmarshal(in, U.gridClassLoader());
+                        sock.setSoTimeout((int)spi.netTimeout);
 
-                    if (msg instanceof TcpDiscoveryClientReconnectMessage) {
-                        TcpDiscoveryClientReconnectMessage res = (TcpDiscoveryClientReconnectMessage)msg;
+                        InputStream in = new BufferedInputStream(sock.getInputStream());
 
-                        if (res.creatorNodeId().equals(getLocalNodeId())) {
-                            if (res.success()) {
-                                msgWorker.addMessage(res);
+                        sock.setKeepAlive(true);
+                        sock.setTcpNoDelay(true);
 
-                                success = true;
-                            }
+                        // Wait for
+                        while (!isInterrupted()) {
+                            TcpDiscoveryAbstractMessage msg = spi.marsh.unmarshal(in, U.gridClassLoader());
 
-                            break;
+                            if (msg instanceof TcpDiscoveryClientReconnectMessage) {
+                                TcpDiscoveryClientReconnectMessage res = (TcpDiscoveryClientReconnectMessage)msg;
+
+                                if (res.creatorNodeId().equals(getLocalNodeId())) {
+                                    if (res.success()) {
+                                        msgWorker.addMessage(res);
+
+                                        success = true;
+                                    }
+
+                                    return;
+                                }
+                            }
                         }
                     }
+                    catch (IOException | IgniteCheckedException e) {
+                        U.closeQuiet(sock);
+
+                        if (log.isDebugEnabled())
+                            log.error("Reconnect error [join=" + join + ", timeout=" + timeout + ']', e);
 
+                        if (timeout > 0 && (U.currentTimeMillis() - startTime) > timeout)
+                            throw e;
+                        else
+                            U.warn(log, "Failed to reconnect to cluster (will retry): " + e);
+                    }
+                    finally {
+                        if (success)
+                            sock.setSoTimeout(oldTimeout);
+                    }
                 }
             }
             catch (IOException | IgniteCheckedException e) {
+                err = e;
+
                 U.error(log, "Failed to reconnect", e);
             }
             finally {
                 if (!success) {
                     U.closeQuiet(sock);
 
-                    msgWorker.addMessage(SPI_RECONNECT_FAILED);
+                    if (join)
+                        joinError(new IgniteSpiException("Failed to connect to cluster, connection failed and failed " +
+                            "to reconnect.", err));
+                    else
+                        msgWorker.addMessage(SPI_RECONNECT_FAILED);
                 }
             }
         }
@@ -967,7 +1028,7 @@ class ClientImpl extends TcpDiscoveryImpl {
             spi.stats.onJoinStarted();
 
             try {
-                final Socket sock = joinTopology(false);
+                final Socket sock = joinTopology(false, spi.joinTimeout);
 
                 if (sock == null) {
                     joinErr = new IgniteSpiException("Join process timed out.");
@@ -981,12 +1042,14 @@ class ClientImpl extends TcpDiscoveryImpl {
 
                 sockWriter.setSocket(sock);
 
-                timer.schedule(new TimerTask() {
-                    @Override public void run() {
-                        if (joinLatch.getCount() > 0)
-                            queue.add(JOIN_TIMEOUT);
-                    }
-                }, spi.netTimeout);
+                if (spi.joinTimeout > 0) {
+                    timer.schedule(new TimerTask() {
+                        @Override public void run() {
+                            if (joinLatch.getCount() > 0)
+                                queue.add(JOIN_TIMEOUT);
+                        }
+                    }, spi.joinTimeout);
+                }
 
                 sockReader.setSocket(sock, locNode.clientRouterNodeId());
 
@@ -996,8 +1059,8 @@ class ClientImpl extends TcpDiscoveryImpl {
                     if (msg == JOIN_TIMEOUT) {
                         if (joinLatch.getCount() > 0) {
                             joinErr = new IgniteSpiException("Join process timed out, did not receive response for " +
-                                "join request (consider increasing 'networkTimeout' configuration property) " +
-                                "[networkTimeout=" + spi.netTimeout + ", sock=" + sock +']');
+                                "join request (consider increasing 'joinTimeout' configuration property) " +
+                                "[joinTimeout=" + spi.joinTimeout + ", sock=" + sock +']');
 
                             joinLatch.countDown();
 
@@ -1021,30 +1084,23 @@ class ClientImpl extends TcpDiscoveryImpl {
                         if (((SocketClosedMessage)msg).sock == currSock) {
                             currSock = null;
 
-                            if (joinLatch.getCount() > 0) {
-                                joinErr = new IgniteSpiException("Failed to connect to cluster: socket closed.");
+                            boolean join = joinLatch.getCount() > 0;
 
-                                joinLatch.countDown();
+                            if (spi.getSpiContext().isStopping() || segmented) {
+                                leaveLatch.countDown();
 
-                                break;
+                                if (join) {
+                                    joinError(new IgniteSpiException("Failed to connect to cluster: socket closed."));
+
+                                    break;
+                                }
                             }
                             else {
-                                if (spi.getSpiContext().isStopping() || segmented)
-                                    leaveLatch.countDown();
-                                else {
-                                    assert reconnector == null;
-
-                                    final Reconnector reconnector = new Reconnector();
-                                    this.reconnector = reconnector;
-                                    reconnector.start();
-
-                                    timer.schedule(new TimerTask() {
-                                        @Override public void run() {
-                                            if (reconnector.isAlive())
-                                                reconnector.cancel();
-                                        }
-                                    }, spi.netTimeout);
-                                }
+                                assert reconnector == null;
+
+                                final Reconnector reconnector = new Reconnector(join);
+                                this.reconnector = reconnector;
+                                reconnector.start();
                             }
                         }
                     }
@@ -1208,7 +1264,7 @@ class ClientImpl extends TcpDiscoveryImpl {
 
                     locNode.order(topVer);
 
-                    notifyDiscovery(EVT_NODE_JOINED, topVer, locNode, updateTopologyHistory(topVer));
+                    notifyDiscovery(EVT_NODE_JOINED, topVer, locNode, updateTopologyHistory(topVer, msg));
 
                     joinErr = null;
 
@@ -1230,6 +1286,14 @@ class ClientImpl extends TcpDiscoveryImpl {
                     return;
                 }
 
+                if (!topHist.isEmpty() && msg.topologyVersion() <= topHist.lastKey()) {
+                    if (log.isDebugEnabled())
+                        log.debug("Discarding node add finished message since topology already updated " +
+                            "[msg=" + msg + ", lastHistKey=" + topHist.lastKey() + ", node=" + node + ']');
+
+                    return;
+                }
+
                 long topVer = msg.topologyVersion();
 
                 node.order(topVer);
@@ -1238,7 +1302,7 @@ class ClientImpl extends TcpDiscoveryImpl {
                 if (spi.locNodeVer.equals(node.version()))
                     node.version(spi.locNodeVer);
 
-                NavigableSet<ClusterNode> top = updateTopologyHistory(topVer);
+                NavigableSet<ClusterNode> top = updateTopologyHistory(topVer, msg);
 
                 if (!pending && joinLatch.getCount() > 0) {
                     if (log.isDebugEnabled())
@@ -1276,7 +1340,7 @@ class ClientImpl extends TcpDiscoveryImpl {
                     return;
                 }
 
-                NavigableSet<ClusterNode> top = updateTopologyHistory(msg.topologyVersion());
+                NavigableSet<ClusterNode> top = updateTopologyHistory(msg.topologyVersion(), msg);
 
                 if (!pending && joinLatch.getCount() > 0) {
                     if (log.isDebugEnabled())
@@ -1319,7 +1383,7 @@ class ClientImpl extends TcpDiscoveryImpl {
                     return;
                 }
 
-                NavigableSet<ClusterNode> top = updateTopologyHistory(msg.topologyVersion());
+                NavigableSet<ClusterNode> top = updateTopologyHistory(msg.topologyVersion(), msg);
 
                 if (!pending && joinLatch.getCount() > 0) {
                     if (log.isDebugEnabled())
@@ -1376,28 +1440,32 @@ class ClientImpl extends TcpDiscoveryImpl {
                 return;
 
             if (getLocalNodeId().equals(msg.creatorNodeId())) {
-                assert msg.success();
+                assert msg.success() : msg;
 
-                currSock = reconnector.sock;
+                if (reconnector != null) {
+                    currSock = reconnector.sock;
 
-                sockWriter.setSocket(currSock);
-                sockReader.setSocket(currSock, locNode.clientRouterNodeId());
+                    sockWriter.setSocket(currSock);
+                    sockReader.setSocket(currSock, locNode.clientRouterNodeId());
 
-                reconnector = null;
+                    reconnector = null;
 
-                pending = true;
+                    pending = true;
 
-                try {
-                    for (TcpDiscoveryAbstractMessage pendingMsg : msg.pendingMessages()) {
-                        if (log.isDebugEnabled())
-                            log.debug("Process message on reconnect [msg=" + pendingMsg + ']');
+                    try {
+                        for (TcpDiscoveryAbstractMessage pendingMsg : msg.pendingMessages()) {
+                            if (log.isDebugEnabled())
+                                log.debug("Process message on reconnect [msg=" + pendingMsg + ']');
 
-                        processDiscoveryMessage(pendingMsg);
+                            processDiscoveryMessage(pendingMsg);
+                        }
+                    }
+                    finally {
+                        pending = false;
                     }
                 }
-                finally {
-                    pending = false;
-                }
+                else if (log.isDebugEnabled())
+                    log.debug("Discarding reconnect message, reconnect is completed: " + msg);
             }
             else if (log.isDebugEnabled())
                 log.debug("Discarding reconnect message for another client: " + msg);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8870a177/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java
index 65bea9f..9041557 100644
--- a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java
+++ b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java
@@ -41,7 +41,6 @@ import org.jsr166.*;
 
 import java.io.*;
 import java.net.*;
-import java.text.*;
 import java.util.*;
 import java.util.concurrent.*;
 import java.util.concurrent.atomic.*;
@@ -1192,7 +1191,7 @@ class ServerImpl extends TcpDiscoveryImpl {
 
             if (node.id().equals(destNodeId)) {
                 Collection<TcpDiscoveryNode> allNodes = ring.allNodes();
-                Collection<TcpDiscoveryNode> topToSend = new ArrayList<>(allNodes.size());
+                Collection<TcpDiscoveryNode> topToSnd = new ArrayList<>(allNodes.size());
 
                 for (TcpDiscoveryNode n0 : allNodes) {
                     assert n0.internalOrder() != 0 : n0;
@@ -1202,10 +1201,10 @@ class ServerImpl extends TcpDiscoveryImpl {
                     // There will be separate messages for nodes with greater
                     // internal order.
                     if (n0.internalOrder() < nodeAddedMsg.node().internalOrder())
-                        topToSend.add(n0);
+                        topToSnd.add(n0);
                 }
 
-                nodeAddedMsg.topology(topToSend);
+                nodeAddedMsg.topology(topToSnd);
                 nodeAddedMsg.messages(msgs, discardMsgId);
 
                 Map<Long, Collection<ClusterNode>> hist;
@@ -1646,6 +1645,108 @@ class ServerImpl extends TcpDiscoveryImpl {
     }
 
     /**
+     * Discovery messages history used for client reconnect.
+     */
+    private class EnsuredMessageHistory {
+        /** */
+        private static final int MAX = 1024;
+
+        /** Pending messages. */
+        private final ArrayDeque<TcpDiscoveryAbstractMessage> msgs = new ArrayDeque<>(MAX * 2);
+
+        /**
+         * @param msg Adds message.
+         */
+        void add(TcpDiscoveryAbstractMessage msg) {
+            assert spi.ensured(msg) : msg;
+
+            msgs.addLast(msg);
+
+            while (msgs.size() > MAX)
+                msgs.pollFirst();
+        }
+
+        /**
+         * Gets messages starting from provided ID (exclusive). If such
+         * message is not found, {@code null} is returned (this indicates
+         * a failure condition when it was already removed from queue).
+         *
+         * @param lastMsgId Last message ID received on client. {@code Null} if client did not finish connect procedure.
+         * @param node Client node.
+         * @return Collection of messages.
+         */
+        @Nullable Collection<TcpDiscoveryAbstractMessage> messages(@Nullable IgniteUuid lastMsgId,
+            TcpDiscoveryNode node)
+        {
+            assert node != null && node.isClient() : node;
+
+            if (lastMsgId == null) {
+                // Client connection failed before it received TcpDiscoveryNodeAddedMessage.
+                List<TcpDiscoveryAbstractMessage> res = null;
+
+                for (TcpDiscoveryAbstractMessage msg : msgs) {
+                    if (msg instanceof TcpDiscoveryNodeAddedMessage) {
+                        if (node.id().equals(((TcpDiscoveryNodeAddedMessage) msg).node().id()))
+                            res = new ArrayList<>(msgs.size());
+                    }
+
+                    if (res != null)
+                        res.add(prepare(msg, node.id()));
+                }
+
+                if (log.isDebugEnabled()) {
+                    if (res == null)
+                        log.debug("Failed to find node added message [node=" + node + ']');
+                    else
+                        log.debug("Found add added message [node=" + node + ", hist=" + res + ']');
+                }
+
+                return res;
+            }
+            else {
+                if (msgs.isEmpty())
+                    return Collections.emptyList();
+
+                Collection<TcpDiscoveryAbstractMessage> cp = new ArrayList<>(msgs.size());
+
+                boolean skip = true;
+
+                for (TcpDiscoveryAbstractMessage msg : msgs) {
+                    if (skip) {
+                        if (msg.id().equals(lastMsgId))
+                            skip = false;
+                    }
+                    else
+                        cp.add(prepare(msg, node.id()));
+                }
+
+                cp = !skip ? cp : null;
+
+                if (log.isDebugEnabled()) {
+                    if (cp == null)
+                        log.debug("Failed to find messages history [node=" + node + ", lastMsgId" + lastMsgId + ']');
+                    else
+                        log.debug("Found messages history [node=" + node + ", hist=" + cp + ']');
+                }
+
+                return cp;
+            }
+        }
+
+        /**
+         * @param msg Message.
+         * @param destNodeId Client node ID.
+         * @return Prepared message.
+         */
+        private TcpDiscoveryAbstractMessage prepare(TcpDiscoveryAbstractMessage msg, UUID destNodeId) {
+            if (msg instanceof TcpDiscoveryNodeAddedMessage)
+                prepareNodeAddedMessage(msg, destNodeId, null, null);
+
+            return msg;
+        }
+    }
+
+    /**
      * Pending messages container.
      */
     private static class PendingMessages {
@@ -1678,33 +1779,27 @@ class ServerImpl extends TcpDiscoveryImpl {
         }
 
         /**
-         * Gets messages starting from provided ID (exclusive). If such
-         * message is not found, {@code null} is returned (this indicates
-         * a failure condition when it was already removed from queue).
+         * Resets pending messages.
          *
-         * @param lastMsgId Last message ID.
-         * @return Collection of messages.
+         * @param msgs Message.
+         * @param discardId Discarded message ID.
          */
-        @Nullable Collection<TcpDiscoveryAbstractMessage> messages(IgniteUuid lastMsgId) {
-            assert lastMsgId != null;
-
-            if (msgs.isEmpty())
-                return Collections.emptyList();
+        void reset(@Nullable Collection<TcpDiscoveryAbstractMessage> msgs, @Nullable IgniteUuid discardId) {
+            this.msgs.clear();
 
-            Collection<TcpDiscoveryAbstractMessage> cp = new ArrayList<>(msgs.size());
+            if (msgs != null)
+                this.msgs.addAll(msgs);
 
-            boolean skip = true;
+            this.discardId = discardId;
+        }
 
-            for (TcpDiscoveryAbstractMessage msg : msgs) {
-                if (skip) {
-                    if (msg.id().equals(lastMsgId))
-                        skip = false;
-                }
-                else
-                    cp.add(msg);
-            }
+        /**
+         * Clears pending messages.
+         */
+        void clear() {
+            msgs.clear();
 
-            return !skip ? cp : null;
+            discardId = null;
         }
 
         /**
@@ -1728,6 +1823,9 @@ class ServerImpl extends TcpDiscoveryImpl {
         /** Pending messages. */
         private final PendingMessages pendingMsgs = new PendingMessages();
 
+        /** Messages history used for client reconnect. */
+        private final EnsuredMessageHistory msgHist = new EnsuredMessageHistory();
+
         /** Last message that updated topology. */
         private TcpDiscoveryAbstractMessage lastMsg;
 
@@ -1794,6 +1892,9 @@ class ServerImpl extends TcpDiscoveryImpl {
             else
                 assert false : "Unknown message type: " + msg.getClass().getSimpleName();
 
+            if (spi.ensured(msg))
+                msgHist.add(msg);
+
             spi.stats.onMessageProcessingFinished(msg);
         }
 
@@ -2130,6 +2231,8 @@ class ServerImpl extends TcpDiscoveryImpl {
                             onException("Failed to send message to next node [next=" + next.id() + ", msg=" + msg + ']',
                                 e);
 
+                            log.error("Will resend [msg=" + msg + ", e=" + e + ']');
+
                             if (e instanceof SocketTimeoutException || X.hasCause(e, SocketTimeoutException.class)) {
                                 ackTimeout0 *= 2;
 
@@ -2619,11 +2722,15 @@ class ServerImpl extends TcpDiscoveryImpl {
                 node.aliveCheck(spi.maxMissedClientHbs);
 
                 if (isLocalNodeCoordinator()) {
-                    Collection<TcpDiscoveryAbstractMessage> pending = pendingMsgs.messages(msg.lastMessageId());
+                    Collection<TcpDiscoveryAbstractMessage> pending = msgHist.messages(msg.lastMessageId(), node);
 
                     if (pending != null) {
                         msg.pendingMessages(pending);
                         msg.success(true);
+
+                        if (log.isDebugEnabled())
+                            log.debug("Accept client reconnect, restored pending messages " +
+                                "[locNodeId=" + locNodeId + ", clientNodeId=" + nodeId + ']');
                     }
                     else {
                         if (log.isDebugEnabled())
@@ -2836,7 +2943,8 @@ class ServerImpl extends TcpDiscoveryImpl {
                             topHist.clear();
                             topHist.putAll(msg.topologyHistory());
 
-                            pendingMsgs.discard(msg.discardedMessageId());
+                            // Restore pending messages.
+                            pendingMsgs.reset(msg.messages(), msg.discardedMessageId());
 
                             // Clear data to minimize message size.
                             msg.messages(null, null);
@@ -3094,6 +3202,10 @@ class ServerImpl extends TcpDiscoveryImpl {
                 if (log.isDebugEnabled())
                     log.debug("Removed node from topology: " + leftNode);
 
+                // Clear pending messages map.
+                if (!ring.hasRemoteNodes())
+                    pendingMsgs.clear();
+
                 long topVer;
 
                 if (locNodeCoord) {
@@ -3257,6 +3369,10 @@ class ServerImpl extends TcpDiscoveryImpl {
 
                 assert node != null;
 
+                // Clear pending messages map.
+                if (!ring.hasRemoteNodes())
+                    pendingMsgs.clear();
+
                 long topVer;
 
                 if (locNodeCoord) {

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8870a177/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ipfinder/TcpDiscoveryIpFinderAdapter.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ipfinder/TcpDiscoveryIpFinderAdapter.java b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ipfinder/TcpDiscoveryIpFinderAdapter.java
index 99a2cdc..4d62ff2 100644
--- a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ipfinder/TcpDiscoveryIpFinderAdapter.java
+++ b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ipfinder/TcpDiscoveryIpFinderAdapter.java
@@ -17,9 +17,13 @@
 
 package org.apache.ignite.spi.discovery.tcp.ipfinder;
 
+import org.apache.ignite.*;
 import org.apache.ignite.internal.util.tostring.*;
 import org.apache.ignite.internal.util.typedef.internal.*;
+import org.apache.ignite.resources.*;
 import org.apache.ignite.spi.*;
+import org.apache.ignite.spi.discovery.*;
+import org.apache.ignite.spi.discovery.tcp.*;
 
 import java.net.*;
 import java.util.*;
@@ -35,6 +39,11 @@ public abstract class TcpDiscoveryIpFinderAdapter implements TcpDiscoveryIpFinde
     @GridToStringExclude
     private volatile IgniteSpiContext spiCtx;
 
+    /** Ignite instance . */
+    @IgniteInstanceResource
+    @GridToStringExclude
+    protected Ignite ignite;
+
     /** {@inheritDoc} */
     @Override public void onSpiContextInitialized(IgniteSpiContext spiCtx) throws IgniteSpiException {
         this.spiCtx = spiCtx;
@@ -47,7 +56,8 @@ public abstract class TcpDiscoveryIpFinderAdapter implements TcpDiscoveryIpFinde
 
     /** {@inheritDoc} */
     @Override public void initializeLocalAddresses(Collection<InetSocketAddress> addrs) throws IgniteSpiException {
-        registerAddresses(addrs);
+        if (!discoveryClientMode())
+            registerAddresses(addrs);
     }
 
     /** {@inheritDoc} */
@@ -77,6 +87,28 @@ public abstract class TcpDiscoveryIpFinderAdapter implements TcpDiscoveryIpFinde
     }
 
     /**
+     * @return {@code True} if TCP discovery works in client mode.
+     */
+    protected boolean discoveryClientMode() {
+        boolean clientMode;
+
+        Ignite ignite0 = ignite;
+
+        if (ignite0 != null) { // Can be null if used in tests without starting Ignite.
+            DiscoverySpi discoSpi = ignite0.configuration().getDiscoverySpi();
+
+            if (!(discoSpi instanceof TcpDiscoverySpi))
+                throw new IgniteSpiException("TcpDiscoveryIpFinder should be used with TcpDiscoverySpi: " + discoSpi);
+
+            clientMode = ignite0.configuration().isClientMode() && !((TcpDiscoverySpi)discoSpi).isForceServerMode();
+        }
+        else
+            clientMode = false;
+
+        return clientMode;
+    }
+
+    /**
      * @return SPI context.
      */
     protected IgniteSpiContext spiContext() {

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8870a177/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ipfinder/multicast/TcpDiscoveryMulticastIpFinder.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ipfinder/multicast/TcpDiscoveryMulticastIpFinder.java b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ipfinder/multicast/TcpDiscoveryMulticastIpFinder.java
index a992620..8e5a1fd 100644
--- a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ipfinder/multicast/TcpDiscoveryMulticastIpFinder.java
+++ b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ipfinder/multicast/TcpDiscoveryMulticastIpFinder.java
@@ -85,11 +85,6 @@ public class TcpDiscoveryMulticastIpFinder extends TcpDiscoveryVmIpFinder {
     @LoggerResource
     private IgniteLogger log;
 
-    /** Ignite instance . */
-    @IgniteInstanceResource
-    @GridToStringExclude
-    private Ignite ignite;
-
     /** Multicast IP address as string. */
     private String mcastGrp = DFLT_MCAST_GROUP;
 
@@ -256,19 +251,7 @@ public class TcpDiscoveryMulticastIpFinder extends TcpDiscoveryVmIpFinder {
                 "(it is recommended in production to specify at least one address in " +
                 "TcpDiscoveryMulticastIpFinder.getAddresses() configuration property)");
 
-        boolean clientMode;
-
-        if (ignite != null) { // Can be null if used in tests without starting Ignite.
-            DiscoverySpi discoSpi = ignite.configuration().getDiscoverySpi();
-
-            if (!(discoSpi instanceof TcpDiscoverySpi))
-                throw new IgniteSpiException("TcpDiscoveryMulticastIpFinder should be used with " +
-                    "TcpDiscoverySpi: " + discoSpi);
-
-            clientMode = ((TcpDiscoverySpi)discoSpi).isClientMode();
-        }
-        else
-            clientMode = false;
+        boolean clientMode = discoveryClientMode();
 
         InetAddress mcastAddr;
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8870a177/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/messages/TcpDiscoveryAbstractMessage.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/messages/TcpDiscoveryAbstractMessage.java b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/messages/TcpDiscoveryAbstractMessage.java
index 145b518..21dbf4f 100644
--- a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/messages/TcpDiscoveryAbstractMessage.java
+++ b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/messages/TcpDiscoveryAbstractMessage.java
@@ -41,7 +41,7 @@ public abstract class TcpDiscoveryAbstractMessage implements Serializable {
     protected static final int CLIENT_RECON_SUCCESS_FLAG_POS = 2;
 
     /** Sender of the message (transient). */
-    private transient UUID senderNodeId;
+    private transient UUID sndNodeId;
 
     /** Message ID. */
     private IgniteUuid id;
@@ -99,16 +99,16 @@ public abstract class TcpDiscoveryAbstractMessage implements Serializable {
      * @return Sender node ID.
      */
     public UUID senderNodeId() {
-        return senderNodeId;
+        return sndNodeId;
     }
 
     /**
      * Sets sender node ID.
      *
-     * @param senderNodeId Sender node ID.
+     * @param sndNodeId Sender node ID.
      */
-    public void senderNodeId(UUID senderNodeId) {
-        this.senderNodeId = senderNodeId;
+    public void senderNodeId(UUID sndNodeId) {
+        this.sndNodeId = sndNodeId;
     }
 
     /**

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8870a177/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java
index 77ddd40..4fb4387 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java
@@ -63,18 +63,13 @@ public class IgniteCacheManyClientsTest extends GridCommonAbstractTest {
         ((TcpCommunicationSpi)cfg.getCommunicationSpi()).setLocalPortRange(200);
 
         ((TcpDiscoverySpi)cfg.getDiscoverySpi()).setIpFinder(ipFinder);
+        ((TcpDiscoverySpi)cfg.getDiscoverySpi()).setJoinTimeout(2 * 60_000);
 
         if (!clientDiscovery)
             ((TcpDiscoverySpi)cfg.getDiscoverySpi()).setForceServerMode(true);
 
         cfg.setClientMode(client);
 
-        if (client) {
-//            cfg.setPublicThreadPoolSize(1);
-//            cfg.setPeerClassLoadingThreadPoolSize(1);
-//            cfg.setIgfsThreadPoolSize(1);
-        }
-
         CacheConfiguration ccfg = new CacheConfiguration();
 
         ccfg.setCacheMode(PARTITIONED);
@@ -197,43 +192,62 @@ public class IgniteCacheManyClientsTest extends GridCommonAbstractTest {
         try {
             IgniteInternalFuture<?> fut = GridTestUtils.runMultiThreadedAsync(new Callable<Object>() {
                 @Override public Object call() throws Exception {
-                    try (Ignite ignite = startGrid(idx.getAndIncrement())) {
-                        log.info("Started node: " + ignite.name());
+                    boolean counted = false;
 
-                        assertTrue(ignite.configuration().isClientMode());
+                    try {
+                        int nodeIdx = idx.getAndIncrement();
 
-                        IgniteCache<Object, Object> cache = ignite.cache(null);
+                        Thread.currentThread().setName("client-thread-node-" + nodeIdx);
 
-                        ThreadLocalRandom rnd = ThreadLocalRandom.current();
+                        try (Ignite ignite = startGrid(nodeIdx)) {
+                            log.info("Started node: " + ignite.name());
 
-                        int iter = 0;
+                            assertTrue(ignite.configuration().isClientMode());
 
-                        Integer key = rnd.nextInt(0, 1000);
+                            IgniteCache<Object, Object> cache = ignite.cache(null);
 
-                        cache.put(key, iter++);
+                            ThreadLocalRandom rnd = ThreadLocalRandom.current();
 
-                        assertNotNull(cache.get(key));
+                            int iter = 0;
 
-                        latch.countDown();
-
-                        while (!stop.get()) {
-                            key = rnd.nextInt(0, 1000);
+                            Integer key = rnd.nextInt(0, 1000);
 
                             cache.put(key, iter++);
 
                             assertNotNull(cache.get(key));
 
-                            Thread.sleep(1);
+                            latch.countDown();
+
+                            counted = true;
+
+                            while (!stop.get()) {
+                                key = rnd.nextInt(0, 1000);
+
+                                cache.put(key, iter++);
+
+                                assertNotNull(cache.get(key));
+
+                                Thread.sleep(1);
+                            }
+
+                            log.info("Stopping node: " + ignite.name());
                         }
 
-                        log.info("Stopping node: " + ignite.name());
+                        return null;
                     }
+                    catch (Throwable e) {
+                        log.error("Unexpected error in client thread: " + e, e);
 
-                    return null;
+                        throw e;
+                    }
+                    finally {
+                        if (!counted)
+                            latch.countDown();
+                    }
                 }
             }, THREADS, "client-thread");
 
-            latch.await();
+            assertTrue(latch.await(getTestTimeout(), TimeUnit.MILLISECONDS));
 
             log.info("All clients started.");
 
@@ -245,6 +259,11 @@ public class IgniteCacheManyClientsTest extends GridCommonAbstractTest {
 
             fut.get();
         }
+        catch (Throwable e) {
+            log.error("Unexpected error: " + e, e);
+
+            throw e;
+        }
         finally {
             stop.set(true);
         }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8870a177/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpiSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpiSelfTest.java
index 44fe299..8147958 100644
--- a/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpiSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpiSelfTest.java
@@ -193,8 +193,7 @@ public class TcpClientDiscoverySpiSelfTest extends GridCommonAbstractTest {
     }
 
     /**
-     *
-     * @throws Exception
+     * @throws Exception If failed.
      */
     public void testJoinTimeout() throws Exception {
         clientIpFinder = new TcpDiscoveryVmIpFinder();
@@ -544,8 +543,6 @@ public class TcpClientDiscoverySpiSelfTest extends GridCommonAbstractTest {
      * @throws Exception If failed.
      */
     public void testClientReconnectTopologyChange2() throws Exception {
-        fail("https://issues.apache.org/jira/browse/IGNITE-998");
-
         maxMissedClientHbs = 100;
 
         clientsPerSrv = 1;
@@ -1001,6 +998,24 @@ public class TcpClientDiscoverySpiSelfTest extends GridCommonAbstractTest {
     }
 
     /**
+     * @throws Exception If failed.
+     */
+    public void testJoinError2() throws Exception {
+        startServerNodes(1);
+
+        Ignite ignite = G.ignite("server-0");
+
+        TestTcpDiscoverySpi srvSpi = ((TestTcpDiscoverySpi)ignite.configuration().getDiscoverySpi());
+
+        srvSpi.failNodeAddedMessage();
+        srvSpi.failClientReconnectMessage();
+
+        startClientNodes(1);
+
+        checkNodes(1, 1);
+    }
+
+    /**
      * @param clientIdx Client index.
      * @param srvIdx Server index.
      * @throws Exception In case of error.
@@ -1251,6 +1266,9 @@ public class TcpClientDiscoverySpiSelfTest extends GridCommonAbstractTest {
         /** */
         private AtomicInteger failNodeAdded = new AtomicInteger();
 
+        /** */
+        private AtomicInteger failClientReconnect = new AtomicInteger();
+
         /**
          * @param lock Lock.
          */
@@ -1276,6 +1294,13 @@ public class TcpClientDiscoverySpiSelfTest extends GridCommonAbstractTest {
         }
 
         /**
+         *
+         */
+        void failClientReconnectMessage() {
+            failClientReconnect.set(1);
+        }
+
+        /**
          * @param isPause Is lock.
          * @param locks Locks.
          */
@@ -1293,7 +1318,14 @@ public class TcpClientDiscoverySpiSelfTest extends GridCommonAbstractTest {
             GridByteArrayOutputStream bout) throws IOException, IgniteCheckedException {
             waitFor(writeLock);
 
-            if (msg instanceof TcpDiscoveryNodeAddedMessage && failNodeAdded.getAndDecrement() > 0) {
+            boolean fail = false;
+
+            if (msg instanceof TcpDiscoveryNodeAddedMessage)
+                fail = failNodeAdded.getAndDecrement() > 0;
+            else if (msg instanceof TcpDiscoveryClientReconnectMessage)
+                fail = failClientReconnect.getAndDecrement() > 0;
+
+            if (fail) {
                 log.info("Close socket on message write [msg=" + msg + "]");
 
                 sock.close();



[35/50] incubator-ignite git commit: Merge remote-tracking branch 'remotes/origin/ignite-883' into ignite-883-1

Posted by vo...@apache.org.
Merge remote-tracking branch 'remotes/origin/ignite-883' into ignite-883-1

Conflicts:
	modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
	modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryManager.java
	modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java
	modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java
	modules/core/src/test/java/org/apache/ignite/internal/processors/cache/query/GridCacheSwapScanQueryAbstractSelfTest.java
	modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpiSelfTest.java
	modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
	modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheCrossCacheQuerySelfTest.java
	modules/scalar-2.10/pom.xml
	modules/spark-2.10/pom.xml
	modules/spark/pom.xml
	modules/visor-console-2.10/pom.xml


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

Branch: refs/heads/ignite-gg-10411
Commit: f115c048083cd36edd31b589a9c3389322e0220e
Parents: 65db72e
Author: sboikov <sb...@gridgain.com>
Authored: Fri Jun 12 18:02:31 2015 +0300
Committer: sboikov <sb...@gridgain.com>
Committed: Fri Jun 12 18:02:31 2015 +0300

----------------------------------------------------------------------
 .../apache/ignite/cache/query/ScanQuery.java    | 20 --------------------
 .../ignite/spi/discovery/tcp/ClientImpl.java    |  2 +-
 .../ignite/spi/discovery/tcp/ServerImpl.java    |  2 --
 .../testsuites/IgniteCacheTestSuite4.java       |  2 --
 4 files changed, 1 insertion(+), 25 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/f115c048/modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java b/modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
index 90000e8..6e02ff9 100644
--- a/modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
+++ b/modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
@@ -97,16 +97,6 @@ public final class ScanQuery<K, V> extends Query<Cache.Entry<K, V>> {
     }
 
     /**
-     * Gets partition number over which this query should iterate. Will return {@code null} if partition was not
-     * set. In this case query will iterate over all partitions in the cache.
-     *
-     * @return Partition number or {@code null}.
-     */
-    @Nullable public Integer getPartition() {
-        return part;
-    }
-
-    /**
      * Sets partition number over which this query should iterate. If {@code null}, query will iterate over
      * all partitions in the cache. Must be in the range [0, N) where N is partition number in the cache.
      *
@@ -129,16 +119,6 @@ public final class ScanQuery<K, V> extends Query<Cache.Entry<K, V>> {
         return part;
     }
 
-    /**
-     * Sets partition number over which this query should iterate. If {@code null}, query will iterate over
-     * all partitions in the cache. Must be in the range [0, N) where N is partition number in the cache.
-     *
-     * @param part Partition number over which this query should iterate.
-     */
-    public void setPartition(@Nullable Integer part) {
-        this.part = part;
-    }
-
     /** {@inheritDoc} */
     @Override public ScanQuery<K, V> setPageSize(int pageSize) {
         return (ScanQuery<K, V>)super.setPageSize(pageSize);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/f115c048/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ClientImpl.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ClientImpl.java b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ClientImpl.java
index d8108e5..a17296c 100644
--- a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ClientImpl.java
+++ b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ClientImpl.java
@@ -1145,7 +1145,7 @@ class ClientImpl extends TcpDiscoveryImpl {
 
                 if (joinLatch.getCount() > 0) {
                     // This should not occurs.
-                    joinErr = new IgniteSpiException("Some error occur in join process.");
+                    joinErr = new IgniteSpiException("Some error in join process.");
 
                     joinLatch.countDown();
                 }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/f115c048/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java
index c92fcde..63f165d 100644
--- a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java
+++ b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java
@@ -2231,8 +2231,6 @@ class ServerImpl extends TcpDiscoveryImpl {
                             onException("Failed to send message to next node [next=" + next.id() + ", msg=" + msg + ']',
                                 e);
 
-                            log.error("Will resend [msg=" + msg + ", e=" + e + ']');
-
                             if (e instanceof SocketTimeoutException || X.hasCause(e, SocketTimeoutException.class)) {
                                 ackTimeout0 *= 2;
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/f115c048/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java b/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
index 7fa038c..fed5efe 100644
--- a/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
+++ b/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
@@ -136,8 +136,6 @@ public class IgniteCacheTestSuite4 extends TestSuite {
 
         suite.addTestSuite(CacheReadOnlyTransactionalClientSelfTest.class);
 
-        suite.addTestSuite(IgniteCacheManyClientsTest.class);
-
         suite.addTestSuite(IgniteStartCacheInTransactionSelfTest.class);
         suite.addTestSuite(IgniteStartCacheInTransactionAtomicSelfTest.class);
 


[43/50] incubator-ignite git commit: Merge branches 'ignite-sprint-5' and 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-sprint-6

Posted by vo...@apache.org.
Merge branches 'ignite-sprint-5' and 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-sprint-6

Conflicts:
	modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
	modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryManager.java
	modules/core/src/test/java/org/apache/ignite/internal/processors/cache/query/GridCacheSwapScanQueryAbstractSelfTest.java
	modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
	modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheCrossCacheQuerySelfTest.java
	modules/scalar-2.10/pom.xml
	modules/spark-2.10/pom.xml
	modules/spark/pom.xml
	modules/visor-console-2.10/pom.xml


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

Branch: refs/heads/ignite-gg-10411
Commit: 460521c353e7672c686e90df38d0356455e3c397
Parents: 40f826b 4375529
Author: Yakov Zhdanov <yz...@gridgain.com>
Authored: Mon Jun 15 10:21:46 2015 +0300
Committer: Yakov Zhdanov <yz...@gridgain.com>
Committed: Mon Jun 15 10:21:46 2015 +0300

----------------------------------------------------------------------
 .../apache/ignite/cache/query/ScanQuery.java    | 23 ++++++++++++++++++++
 .../cache/query/GridCacheQueryManager.java      |  5 +++++
 .../testsuites/IgniteCacheTestSuite4.java       |  2 ++
 3 files changed, 30 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/460521c3/modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
----------------------------------------------------------------------
diff --cc modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
index e6b69bc,11a8c84..90000e8
--- a/modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
+++ b/modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
@@@ -99,23 -99,26 +99,46 @@@ public final class ScanQuery<K, V> exte
      /**
       * Gets partition number over which this query should iterate. Will return {@code null} if partition was not
       * set. In this case query will iterate over all partitions in the cache.
+      *
+      * @return Partition number or {@code null}.
+      */
+     @Nullable public Integer getPartition() {
+         return part;
+     }
+ 
+     /**
+      * Sets partition number over which this query should iterate. If {@code null}, query will iterate over
+      * all partitions in the cache. Must be in the range [0, N) where N is partition number in the cache.
+      *
+      * @param part Partition number over which this query should iterate.
+      * @return {@code this} for chaining.
+      */
+     public ScanQuery<K, V> setPartition(@Nullable Integer part) {
+         this.part = part;
+ 
+         return this;
+     }
+ 
++    /**
++     * Gets partition number over which this query should iterate. Will return {@code null} if partition was not
++     * set. In this case query will iterate over all partitions in the cache.
 +     *
 +     * @return Partition number or {@code null}.
 +     */
 +    @Nullable public Integer getPartition() {
 +        return part;
 +    }
 +
 +    /**
 +     * Sets partition number over which this query should iterate. If {@code null}, query will iterate over
 +     * all partitions in the cache. Must be in the range [0, N) where N is partition number in the cache.
 +     *
 +     * @param part Partition number over which this query should iterate.
 +     */
 +    public void setPartition(@Nullable Integer part) {
 +        this.part = part;
 +    }
 +
      /** {@inheritDoc} */
      @Override public ScanQuery<K, V> setPageSize(int pageSize) {
          return (ScanQuery<K, V>)super.setPageSize(pageSize);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/460521c3/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryManager.java
----------------------------------------------------------------------
diff --cc modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryManager.java
index 1317d38,6e71ba7..7493d07
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryManager.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryManager.java
@@@ -791,9 -791,8 +791,14 @@@ public abstract class GridCacheQueryMan
  
                          locPart = dht.topology().localPartition(part, topVer, false);
  
++<<<<<<< HEAD
 +                        // double check for owning state
 +                        if (locPart == null || locPart.state() != OWNING || !locPart.reserve() ||
 +                            locPart.state() != OWNING)
++=======
+                         if (locPart == null || (locPart.state() != OWNING && locPart.state() != RENTING) ||
+                             !locPart.reserve())
++>>>>>>> 4375529fa929e650f7b68d750318d67a8609ee10
                              throw new GridDhtInvalidPartitionException(part, "Partition can't be reserved");
  
                          iter = new Iterator<K>() {

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/460521c3/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
----------------------------------------------------------------------
diff --cc modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
index c598e38,ed9fc9a..7fa038c
--- a/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
+++ b/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
@@@ -138,9 -140,6 +138,11 @@@ public class IgniteCacheTestSuite4 exte
  
          suite.addTestSuite(IgniteCacheManyClientsTest.class);
  
 +        suite.addTestSuite(IgniteStartCacheInTransactionSelfTest.class);
 +        suite.addTestSuite(IgniteStartCacheInTransactionAtomicSelfTest.class);
 +
++        suite.addTestSuite(IgniteCacheManyClientsTest.class);
++
          return suite;
      }
  }


[45/50] incubator-ignite git commit: Merge branches 'ignite-1009-v4' and 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-1009-v4

Posted by vo...@apache.org.
Merge branches 'ignite-1009-v4' and 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-1009-v4


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

Branch: refs/heads/ignite-gg-10411
Commit: 7c51a14166113e38a1d749fe0a2510c37dc86fe3
Parents: b06eb0e 0907338
Author: Yakov Zhdanov <yz...@gridgain.com>
Authored: Mon Jun 15 10:30:06 2015 +0300
Committer: Yakov Zhdanov <yz...@gridgain.com>
Committed: Mon Jun 15 10:30:06 2015 +0300

----------------------------------------------------------------------
 .../apache/ignite/cache/query/ScanQuery.java    |  5 +-
 .../datastructures/DataStructuresProcessor.java | 67 +++++++++++++++++++-
 .../rest/client/message/GridRouterRequest.java  | 18 ++++++
 .../rest/client/message/GridRouterResponse.java | 18 ++++++
 .../ignite/tools/classgen/ClassesGenerator.java | 12 ++++
 5 files changed, 116 insertions(+), 4 deletions(-)
----------------------------------------------------------------------



[40/50] incubator-ignite git commit: Merge branch 'ignite-1007' into ignite-sprint-6

Posted by vo...@apache.org.
Merge branch 'ignite-1007' into ignite-sprint-6


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

Branch: refs/heads/ignite-gg-10411
Commit: 2f7b253e3832951d9e373c6fb13549f5c7e45ebf
Parents: 2707194 811872c
Author: agura <ag...@gridgain.com>
Authored: Fri Jun 12 18:37:41 2015 +0300
Committer: agura <ag...@gridgain.com>
Committed: Fri Jun 12 18:37:41 2015 +0300

----------------------------------------------------------------------
 .../datastructures/DataStructuresProcessor.java | 67 +++++++++++++++++++-
 1 file changed, 64 insertions(+), 3 deletions(-)
----------------------------------------------------------------------



[29/50] incubator-ignite git commit: Release latch in marshaller context in stop method.

Posted by vo...@apache.org.
Release latch in marshaller context in stop method.


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

Branch: refs/heads/ignite-gg-10411
Commit: e17a2be1b931ea6b4e56be653b73a7994fd59898
Parents: e158c90
Author: nikolay_tikhonov <nt...@gridgain.com>
Authored: Fri Jun 12 17:13:06 2015 +0300
Committer: nikolay_tikhonov <nt...@gridgain.com>
Committed: Fri Jun 12 17:13:06 2015 +0300

----------------------------------------------------------------------
 .../main/java/org/apache/ignite/internal/IgniteKernal.java    | 2 ++
 .../org/apache/ignite/internal/MarshallerContextImpl.java     | 7 +++++++
 2 files changed, 9 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/e17a2be1/modules/core/src/main/java/org/apache/ignite/internal/IgniteKernal.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/IgniteKernal.java b/modules/core/src/main/java/org/apache/ignite/internal/IgniteKernal.java
index 9b2ae27..9da3346 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/IgniteKernal.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/IgniteKernal.java
@@ -1705,6 +1705,8 @@ public class IgniteKernal implements IgniteEx, IgniteMXBean, Externalizable {
 
             List<GridComponent> comps = ctx.components();
 
+            ctx.marshallerContext().onKernalStop();
+
             // Callback component in reverse order while kernal is still functional
             // if called in the same thread, at least.
             for (ListIterator<GridComponent> it = comps.listIterator(comps.size()); it.hasPrevious();) {

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/e17a2be1/modules/core/src/main/java/org/apache/ignite/internal/MarshallerContextImpl.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/MarshallerContextImpl.java b/modules/core/src/main/java/org/apache/ignite/internal/MarshallerContextImpl.java
index 7940e95..48f24ac 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/MarshallerContextImpl.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/MarshallerContextImpl.java
@@ -83,6 +83,13 @@ public class MarshallerContextImpl extends MarshallerContextAdapter {
         latch.countDown();
     }
 
+    /**
+     * Release marshaller context.
+     */
+    public void onKernalStop() {
+        latch.countDown();
+    }
+
     /** {@inheritDoc} */
     @Override protected boolean registerClassName(int id, String clsName) throws IgniteCheckedException {
         GridCacheAdapter<Integer, String> cache0 = cache;


[27/50] incubator-ignite git commit: Merge branch 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-sprint-6

Posted by vo...@apache.org.
Merge branch 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-sprint-6


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

Branch: refs/heads/ignite-gg-10411
Commit: 2b7a18d9a0bd1c98f9a780e0f8f29c34af95e5e3
Parents: 96d12d0 c233aa2
Author: agura <ag...@gridgain.com>
Authored: Fri Jun 12 16:39:07 2015 +0300
Committer: agura <ag...@gridgain.com>
Committed: Fri Jun 12 16:39:07 2015 +0300

----------------------------------------------------------------------
 .../distributed/GridCacheTxRecoveryRequest.java | 26 +++----
 .../GridCacheTxRecoveryResponse.java            | 14 ++--
 .../distributed/GridDistributedBaseMessage.java | 77 +-------------------
 .../distributed/GridDistributedLockRequest.java | 54 +++++++-------
 .../GridDistributedLockResponse.java            | 14 ++--
 .../GridDistributedTxFinishRequest.java         | 46 ++++++------
 .../GridDistributedTxPrepareRequest.java        | 62 ++++++++--------
 .../GridDistributedTxPrepareResponse.java       | 64 +---------------
 .../GridDistributedUnlockRequest.java           |  6 +-
 .../distributed/dht/GridDhtLockRequest.java     | 72 ++++++++++++++----
 .../distributed/dht/GridDhtLockResponse.java    | 18 ++---
 .../distributed/dht/GridDhtTxFinishRequest.java | 38 +++++-----
 .../dht/GridDhtTxPrepareRequest.java            | 54 +++++++-------
 .../dht/GridDhtTxPrepareResponse.java           | 22 +++---
 .../distributed/dht/GridDhtUnlockRequest.java   |  6 +-
 .../distributed/near/GridNearLockRequest.java   | 58 +++++++--------
 .../distributed/near/GridNearLockResponse.java  | 26 +++----
 .../near/GridNearTxFinishRequest.java           | 26 +++----
 .../near/GridNearTxPrepareRequest.java          | 50 ++++++-------
 .../near/GridNearTxPrepareResponse.java         | 46 ++++++------
 .../distributed/near/GridNearUnlockRequest.java |  2 +-
 .../cache/transactions/IgniteTxHandler.java     |  3 -
 .../messages/GridQueryNextPageResponse.java     |  1 +
 .../DataStreamProcessorSelfTest.java            |  3 +-
 .../testsuites/IgniteKernalSelfTestSuite.java   |  2 +-
 25 files changed, 351 insertions(+), 439 deletions(-)
----------------------------------------------------------------------



[13/50] incubator-ignite git commit: #IGNITE-389 - Minor

Posted by vo...@apache.org.
#IGNITE-389 - Minor


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

Branch: refs/heads/ignite-gg-10411
Commit: 89a4f7c569e3f50d1623d461756e8a0bc2c1dd13
Parents: f149c82
Author: Alexey Goncharuk <ag...@gridgain.com>
Authored: Wed Jun 10 15:59:15 2015 -0700
Committer: Alexey Goncharuk <ag...@gridgain.com>
Committed: Wed Jun 10 15:59:15 2015 -0700

----------------------------------------------------------------------
 .../internal/util/ipc/shmem/IpcSharedMemoryNativeLoader.java       | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/89a4f7c5/modules/core/src/main/java/org/apache/ignite/internal/util/ipc/shmem/IpcSharedMemoryNativeLoader.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/util/ipc/shmem/IpcSharedMemoryNativeLoader.java b/modules/core/src/main/java/org/apache/ignite/internal/util/ipc/shmem/IpcSharedMemoryNativeLoader.java
index 5b3274d..d4ae147 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/util/ipc/shmem/IpcSharedMemoryNativeLoader.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/util/ipc/shmem/IpcSharedMemoryNativeLoader.java
@@ -163,7 +163,7 @@ public class IpcSharedMemoryNativeLoader {
                 }
             }
             catch (IgniteCheckedException ignore) {
-
+                // No-op.
             }
 
             // Failed to find the library.


[17/50] incubator-ignite git commit: Idea code style excluded from licence validator

Posted by vo...@apache.org.
Idea code style excluded from licence validator


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

Branch: refs/heads/ignite-gg-10411
Commit: b52e47ae53e905cb67bd3c644bb246e393349652
Parents: 4f500fd
Author: agura <ag...@gridgain.com>
Authored: Thu Jun 11 14:56:16 2015 +0300
Committer: agura <ag...@gridgain.com>
Committed: Thu Jun 11 14:56:16 2015 +0300

----------------------------------------------------------------------
 parent/pom.xml | 1 +
 1 file changed, 1 insertion(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/b52e47ae/parent/pom.xml
----------------------------------------------------------------------
diff --git a/parent/pom.xml b/parent/pom.xml
index f5b73df..b167932 100644
--- a/parent/pom.xml
+++ b/parent/pom.xml
@@ -626,6 +626,7 @@
                                         <exclude>**/keystore/*.pem</exclude><!--auto generated files-->
                                         <exclude>**/keystore/*.pfx</exclude><!--bin-files-->
                                         <!--special excludes-->
+                                        <exclude>idea/ignite_codeStyle.xml</exclude>
                                         <exclude>DEVNOTES.txt</exclude>
                                         <exclude>src/main/java/org/apache/ignite/internal/util/offheap/unsafe/GridOffHeapSnapTreeMap.java</exclude><!--BSD license-->
                                         <exclude>src/main/java/org/apache/ignite/internal/util/snaptree/*.java</exclude><!--BSD license-->


[10/50] incubator-ignite git commit: IGNITE-389 - Fixing tests.

Posted by vo...@apache.org.
IGNITE-389 - Fixing tests.


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

Branch: refs/heads/ignite-gg-10411
Commit: 71f29e98e2ea571e437206a3712b7261e086e1db
Parents: 3417215
Author: Alexey Goncharuk <ag...@gridgain.com>
Authored: Wed Jun 10 13:22:15 2015 -0700
Committer: Alexey Goncharuk <ag...@gridgain.com>
Committed: Wed Jun 10 13:22:15 2015 -0700

----------------------------------------------------------------------
 .../ignite/internal/processors/query/GridQueryIndexing.java   | 4 +++-
 .../ignite/internal/processors/query/GridQueryProcessor.java  | 7 +++++--
 .../ignite/internal/processors/query/h2/IgniteH2Indexing.java | 7 ++++---
 .../processors/query/h2/twostep/GridReduceQueryExecutor.java  | 4 ++--
 4 files changed, 14 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/71f29e98/modules/core/src/main/java/org/apache/ignite/internal/processors/query/GridQueryIndexing.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/query/GridQueryIndexing.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/query/GridQueryIndexing.java
index cc0916a..7fcc284 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/query/GridQueryIndexing.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/query/GridQueryIndexing.java
@@ -58,9 +58,11 @@ public interface GridQueryIndexing {
      *
      * @param cctx Cache context.
      * @param qry Query.
+     * @param keepCacheObjects If {@code true}, cache objects representation will be preserved.
      * @return Cursor.
      */
-    public Iterable<List<?>> queryTwoStep(GridCacheContext<?,?> cctx, GridCacheTwoStepQuery qry);
+    public Iterable<List<?>> queryTwoStep(GridCacheContext<?,?> cctx, GridCacheTwoStepQuery qry,
+        boolean keepCacheObjects);
 
     /**
      * Parses SQL query into two step query and executes it.

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/71f29e98/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 1be2a36..e187713 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
@@ -546,9 +546,12 @@ public class GridQueryProcessor extends GridProcessorAdapter {
             throw new IllegalStateException("Failed to execute query (grid is stopping).");
 
         try {
+            GridCacheContext<Object, Object> cacheCtx = ctx.cache().internalCache(space).context();
+
             return idx.queryTwoStep(
-                ctx.cache().internalCache(space).context(),
-                qry);
+                cacheCtx,
+                qry,
+                cacheCtx.keepPortable());
         }
         finally {
             busyLock.leaveBusy();

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/71f29e98/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/IgniteH2Indexing.java
----------------------------------------------------------------------
diff --git a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/IgniteH2Indexing.java b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/IgniteH2Indexing.java
index 6ec329f..5e27c24 100644
--- a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/IgniteH2Indexing.java
+++ b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/IgniteH2Indexing.java
@@ -771,10 +771,11 @@ public class IgniteH2Indexing implements GridQueryIndexing {
     }
 
     /** {@inheritDoc} */
-    @Override public Iterable<List<?>> queryTwoStep(final GridCacheContext<?,?> cctx, final GridCacheTwoStepQuery qry) {
+    @Override public Iterable<List<?>> queryTwoStep(final GridCacheContext<?,?> cctx, final GridCacheTwoStepQuery qry,
+        final boolean keepCacheObj) {
         return new Iterable<List<?>>() {
             @Override public Iterator<List<?>> iterator() {
-                return rdcQryExec.query(cctx, qry);
+                return rdcQryExec.query(cctx, qry, keepCacheObj);
             }
         };
     }
@@ -872,7 +873,7 @@ public class IgniteH2Indexing implements GridQueryIndexing {
 
         twoStepQry.pageSize(qry.getPageSize());
 
-        QueryCursorImpl<List<?>> cursor = new QueryCursorImpl<>(queryTwoStep(cctx, twoStepQry));
+        QueryCursorImpl<List<?>> cursor = new QueryCursorImpl<>(queryTwoStep(cctx, twoStepQry, cctx.keepPortable()));
 
         cursor.fieldsMeta(meta);
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/71f29e98/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridReduceQueryExecutor.java
----------------------------------------------------------------------
diff --git a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridReduceQueryExecutor.java b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridReduceQueryExecutor.java
index cfacfcf..11054b7 100644
--- a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridReduceQueryExecutor.java
+++ b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridReduceQueryExecutor.java
@@ -269,7 +269,7 @@ public class GridReduceQueryExecutor {
      * @param qry Query.
      * @return Cursor.
      */
-    public Iterator<List<?>> query(GridCacheContext<?,?> cctx, GridCacheTwoStepQuery qry) {
+    public Iterator<List<?>> query(GridCacheContext<?,?> cctx, GridCacheTwoStepQuery qry, boolean keepPortable) {
         long qryReqId = reqIdGen.incrementAndGet();
 
         QueryRun r = new QueryRun();
@@ -356,7 +356,7 @@ public class GridReduceQueryExecutor {
 //                dropTable(r.conn, tbl.getName()); TODO
             }
 
-            return new GridQueryCacheObjectsIterator(new Iter(res), cctx, cctx.keepPortable());
+            return new GridQueryCacheObjectsIterator(new Iter(res), cctx, keepPortable);
         }
         catch (IgniteCheckedException | InterruptedException | RuntimeException e) {
             U.closeQuiet(r.conn);


[36/50] incubator-ignite git commit: # Release notes for Hadoop.

Posted by vo...@apache.org.
# Release notes for Hadoop.


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

Branch: refs/heads/ignite-gg-10411
Commit: 2707194f50070622dd646c85ebbdb2671dfd6586
Parents: 5160088
Author: vozerov-gridgain <vo...@gridgain.com>
Authored: Fri Jun 12 18:10:06 2015 +0300
Committer: vozerov-gridgain <vo...@gridgain.com>
Committed: Fri Jun 12 18:10:06 2015 +0300

----------------------------------------------------------------------
 RELEASE_NOTES.txt | 2 ++
 1 file changed, 2 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/2707194f/RELEASE_NOTES.txt
----------------------------------------------------------------------
diff --git a/RELEASE_NOTES.txt b/RELEASE_NOTES.txt
index fcd281a..1783131 100644
--- a/RELEASE_NOTES.txt
+++ b/RELEASE_NOTES.txt
@@ -1,5 +1,6 @@
 Apache Ignite Release Notes
 ===========================
+
 Apache Ignite In-Memory Data Fabric 1.2
 ---------------------------------------
 
@@ -9,6 +10,7 @@ Apache Ignite In-Memory Data Fabric 1.2
 * Added integration with Apache Mesos.
 * Added support for log4j2.
 * Added IgniteCache.getAllOutTx() method.
+* Bug fixes in In-Memory Accelerator For Apache Hadoop.
 * Many stability and fault-tolerance fixes.
 
 Apache Ignite In-Memory Data Fabric 1.1


[21/50] incubator-ignite git commit: # ignite-883

Posted by vo...@apache.org.
# ignite-883


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

Branch: refs/heads/ignite-gg-10411
Commit: 16f3d32ea2059efedb5fc24bbb24fce80da6a346
Parents: 58fe3ed
Author: sboikov <se...@inria.fr>
Authored: Thu Jun 11 21:53:18 2015 +0300
Committer: sboikov <se...@inria.fr>
Committed: Fri Jun 12 07:24:21 2015 +0300

----------------------------------------------------------------------
 .../ignite/spi/discovery/tcp/ClientImpl.java    | 13 ++++++--
 .../tcp/TcpClientDiscoverySpiSelfTest.java      | 33 ++++++++++++++++++++
 2 files changed, 43 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/16f3d32e/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ClientImpl.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ClientImpl.java b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ClientImpl.java
index 23297ed..23e6f88 100644
--- a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ClientImpl.java
+++ b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ClientImpl.java
@@ -398,8 +398,7 @@ class ClientImpl extends TcpDiscoveryImpl {
                     continue;
                 }
 
-                assert sockAndRes.get1() != null;
-                assert sockAndRes.get2() != null;
+                assert sockAndRes.get1() != null && sockAndRes.get2() != null : sockAndRes;
 
                 Socket sock = sockAndRes.get1();
 
@@ -441,6 +440,10 @@ class ClientImpl extends TcpDiscoveryImpl {
     @Nullable private T2<Socket, Integer> sendJoinRequest(boolean recon, InetSocketAddress addr) {
         assert addr != null;
 
+        if (log.isDebugEnabled())
+            log.debug("Send join request [addr=" + addr + ", reconnect=" + recon +
+                ", locNodeId=" + getLocalNodeId() + ']');
+
         Collection<Throwable> errs = null;
 
         long ackTimeout0 = spi.ackTimeout;
@@ -1385,8 +1388,12 @@ class ClientImpl extends TcpDiscoveryImpl {
                 pending = true;
 
                 try {
-                    for (TcpDiscoveryAbstractMessage pendingMsg : msg.pendingMessages())
+                    for (TcpDiscoveryAbstractMessage pendingMsg : msg.pendingMessages()) {
+                        if (log.isDebugEnabled())
+                            log.debug("Process message on reconnect [msg=" + pendingMsg + ']');
+
                         processDiscoveryMessage(pendingMsg);
+                    }
                 }
                 finally {
                     pending = false;

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/16f3d32e/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpiSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpiSelfTest.java
index 55a14e4..44fe299 100644
--- a/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpiSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpClientDiscoverySpiSelfTest.java
@@ -984,6 +984,23 @@ public class TcpClientDiscoverySpiSelfTest extends GridCommonAbstractTest {
     }
 
     /**
+     * @throws Exception If failed.
+     */
+    public void testJoinError() throws Exception {
+        startServerNodes(1);
+
+        Ignite ignite = G.ignite("server-0");
+
+        TestTcpDiscoverySpi srvSpi = ((TestTcpDiscoverySpi)ignite.configuration().getDiscoverySpi());
+
+        srvSpi.failNodeAddedMessage();
+
+        startClientNodes(1);
+
+        checkNodes(1, 1);
+    }
+
+    /**
      * @param clientIdx Client index.
      * @param srvIdx Server index.
      * @throws Exception In case of error.
@@ -1231,6 +1248,9 @@ public class TcpClientDiscoverySpiSelfTest extends GridCommonAbstractTest {
         /** */
         private final AtomicBoolean openSockLock = new AtomicBoolean();
 
+        /** */
+        private AtomicInteger failNodeAdded = new AtomicInteger();
+
         /**
          * @param lock Lock.
          */
@@ -1249,6 +1269,13 @@ public class TcpClientDiscoverySpiSelfTest extends GridCommonAbstractTest {
         }
 
         /**
+         *
+         */
+        void failNodeAddedMessage() {
+            failNodeAdded.set(1);
+        }
+
+        /**
          * @param isPause Is lock.
          * @param locks Locks.
          */
@@ -1266,6 +1293,12 @@ public class TcpClientDiscoverySpiSelfTest extends GridCommonAbstractTest {
             GridByteArrayOutputStream bout) throws IOException, IgniteCheckedException {
             waitFor(writeLock);
 
+            if (msg instanceof TcpDiscoveryNodeAddedMessage && failNodeAdded.getAndDecrement() > 0) {
+                log.info("Close socket on message write [msg=" + msg + "]");
+
+                sock.close();
+            }
+
             super.writeToSocket(sock, msg, bout);
         }
 


[32/50] incubator-ignite git commit: # sp-6 release notes

Posted by vo...@apache.org.
# sp-6 release notes


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

Branch: refs/heads/ignite-gg-10411
Commit: dd58664fc81462c81ac28e5bfefb4d07099ff1e8
Parents: 2b7a18d
Author: Yakov Zhdanov <yz...@gridgain.com>
Authored: Fri Jun 12 17:20:50 2015 +0300
Committer: Yakov Zhdanov <yz...@gridgain.com>
Committed: Fri Jun 12 17:20:50 2015 +0300

----------------------------------------------------------------------
 RELEASE_NOTES.txt | 10 ++++++++++
 1 file changed, 10 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/dd58664f/RELEASE_NOTES.txt
----------------------------------------------------------------------
diff --git a/RELEASE_NOTES.txt b/RELEASE_NOTES.txt
index 0369ecd..fcd281a 100644
--- a/RELEASE_NOTES.txt
+++ b/RELEASE_NOTES.txt
@@ -1,5 +1,15 @@
 Apache Ignite Release Notes
 ===========================
+Apache Ignite In-Memory Data Fabric 1.2
+---------------------------------------
+
+* Added client mode to TCP discovery SPI.
+* Added memory based evictions.
+* Added integration with Apache Spark.
+* Added integration with Apache Mesos.
+* Added support for log4j2.
+* Added IgniteCache.getAllOutTx() method.
+* Many stability and fault-tolerance fixes.
 
 Apache Ignite In-Memory Data Fabric 1.1
 ---------------------------------------


[42/50] incubator-ignite git commit: sprint-6 - Fixed broken Externalizable classes + added check

Posted by vo...@apache.org.
sprint-6 - Fixed broken Externalizable classes + added check


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

Branch: refs/heads/ignite-gg-10411
Commit: 40f826bf9037e4341904e87b90f20e3eb0388f85
Parents: 2f7b253
Author: Valentin Kulichenko <vk...@gridgain.com>
Authored: Fri Jun 12 17:05:07 2015 -0700
Committer: Valentin Kulichenko <vk...@gridgain.com>
Committed: Fri Jun 12 17:05:07 2015 -0700

----------------------------------------------------------------------
 .../rest/client/message/GridRouterRequest.java    | 18 ++++++++++++++++++
 .../rest/client/message/GridRouterResponse.java   | 18 ++++++++++++++++++
 .../ignite/tools/classgen/ClassesGenerator.java   | 12 ++++++++++++
 3 files changed, 48 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/40f826bf/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/client/message/GridRouterRequest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/client/message/GridRouterRequest.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/client/message/GridRouterRequest.java
index 6dcbf92..7839e22 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/client/message/GridRouterRequest.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/client/message/GridRouterRequest.java
@@ -17,6 +17,7 @@
 
 package org.apache.ignite.internal.processors.rest.client.message;
 
+import java.io.*;
 import java.util.*;
 
 /**
@@ -30,6 +31,13 @@ public class GridRouterRequest extends GridClientAbstractMessage {
     private final byte[] body;
 
     /**
+     * For {@link Externalizable} (not supported).
+     */
+    public GridRouterRequest() {
+        throw new UnsupportedOperationException();
+    }
+
+    /**
      * @param body Message in raw form.
      * @param clientId Client id.
      * @param reqId Request id.
@@ -51,6 +59,16 @@ public class GridRouterRequest extends GridClientAbstractMessage {
     }
 
     /** {@inheritDoc} */
+    @Override public void writeExternal(ObjectOutput out) throws IOException {
+        throw new UnsupportedOperationException();
+    }
+
+    /** {@inheritDoc} */
+    @Override public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException {
+        throw new UnsupportedOperationException();
+    }
+
+    /** {@inheritDoc} */
     @Override public String toString() {
         return "GridRouterRequest [clientId=" + clientId() + ", reqId=" + requestId() + ", " +
             "destId=" + destinationId() + ", length=" + body.length + "]";

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/40f826bf/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/client/message/GridRouterResponse.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/client/message/GridRouterResponse.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/client/message/GridRouterResponse.java
index 2ff3e21..9054d8e 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/client/message/GridRouterResponse.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/client/message/GridRouterResponse.java
@@ -17,6 +17,7 @@
 
 package org.apache.ignite.internal.processors.rest.client.message;
 
+import java.io.*;
 import java.util.*;
 
 /**
@@ -36,6 +37,13 @@ public class GridRouterResponse extends GridClientAbstractMessage {
     private final int status;
 
     /**
+     * For {@link Externalizable} (not supported).
+     */
+    public GridRouterResponse() {
+        throw new UnsupportedOperationException();
+    }
+
+    /**
      * @param body Message in raw form.
      * @param clientId Client id.
      * @param reqId Request id.
@@ -73,6 +81,16 @@ public class GridRouterResponse extends GridClientAbstractMessage {
     }
 
     /** {@inheritDoc} */
+    @Override public void writeExternal(ObjectOutput out) throws IOException {
+        throw new UnsupportedOperationException();
+    }
+
+    /** {@inheritDoc} */
+    @Override public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException {
+        throw new UnsupportedOperationException();
+    }
+
+    /** {@inheritDoc} */
     @Override public String toString() {
         return "GridRouterResponse [" +
             "clientId=" + clientId() +

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/40f826bf/modules/tools/src/main/java/org/apache/ignite/tools/classgen/ClassesGenerator.java
----------------------------------------------------------------------
diff --git a/modules/tools/src/main/java/org/apache/ignite/tools/classgen/ClassesGenerator.java b/modules/tools/src/main/java/org/apache/ignite/tools/classgen/ClassesGenerator.java
index feb2d9d..20dcc7f 100644
--- a/modules/tools/src/main/java/org/apache/ignite/tools/classgen/ClassesGenerator.java
+++ b/modules/tools/src/main/java/org/apache/ignite/tools/classgen/ClassesGenerator.java
@@ -215,6 +215,18 @@ public class ClassesGenerator {
                     catch (NoSuchFieldException ignored) {
                         errs.add("No serialVersionUID field in class: " + cls.getName());
                     }
+
+                    if (Externalizable.class.isAssignableFrom(cls)) {
+                        try {
+                            Constructor<?> cons = cls.getConstructor();
+
+                            if (!Modifier.isPublic(cons.getModifiers()))
+                                errs.add("Default constructor in Externalizable class is not public: " + cls.getName());
+                        }
+                        catch (NoSuchMethodException e) {
+                            errs.add("No default constructor in Externalizable class: " + cls.getName());
+                        }
+                    }
                 }
 
                 classes.add((Class)cls);


[02/50] incubator-ignite git commit: Merge branch 'ignite-389' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-389

Posted by vo...@apache.org.
Merge branch 'ignite-389' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-389


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

Branch: refs/heads/ignite-gg-10411
Commit: b812c0f165162a94f766bf8e4e12beb7e8170e5d
Parents: 9fca6b5 79ae323
Author: agura <ag...@gridgain.com>
Authored: Tue Jun 9 14:43:14 2015 +0300
Committer: agura <ag...@gridgain.com>
Committed: Tue Jun 9 14:43:14 2015 +0300

----------------------------------------------------------------------
 modules/hadoop/pom.xml        | 1 +
 modules/spark-2.10/README.txt | 4 ----
 modules/spark/README.txt      | 4 ++++
 3 files changed, 5 insertions(+), 4 deletions(-)
----------------------------------------------------------------------



[23/50] incubator-ignite git commit: ignite-classname Changed script for classnames property.

Posted by vo...@apache.org.
ignite-classname Changed script for classnames property.


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

Branch: refs/heads/ignite-gg-10411
Commit: fe1750d3f15ef283ecc76c0fcba0c8a59493691f
Parents: a515ec9
Author: nikolay_tikhonov <nt...@gridgain.com>
Authored: Fri Jun 12 13:37:48 2015 +0300
Committer: nikolay_tikhonov <nt...@gridgain.com>
Committed: Fri Jun 12 13:37:48 2015 +0300

----------------------------------------------------------------------
 .../ignite/tools/classgen/ClassesGenerator.java   | 18 ++++++++++++++----
 1 file changed, 14 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/fe1750d3/modules/tools/src/main/java/org/apache/ignite/tools/classgen/ClassesGenerator.java
----------------------------------------------------------------------
diff --git a/modules/tools/src/main/java/org/apache/ignite/tools/classgen/ClassesGenerator.java b/modules/tools/src/main/java/org/apache/ignite/tools/classgen/ClassesGenerator.java
index ba0aab9..feb2d9d 100644
--- a/modules/tools/src/main/java/org/apache/ignite/tools/classgen/ClassesGenerator.java
+++ b/modules/tools/src/main/java/org/apache/ignite/tools/classgen/ClassesGenerator.java
@@ -29,7 +29,10 @@ import java.util.jar.*;
  */
 public class ClassesGenerator {
     /** */
-    private static final String FILE_PATH = "META-INF/classnames.properties";
+    private static final String META_INF = "META-INF/";
+
+    /** */
+    private static final String DEFAULT_FILE_PATH = META_INF + "classnames.properties";
 
     /** */
     private static final String[] EXCLUDED_PACKAGES = {
@@ -46,8 +49,9 @@ public class ClassesGenerator {
         String basePath = args[0];
         String hdr = args[1];
         String[] packages = args[2].split(":");
+        String finaName = args.length == 4 ? args[3] : null;
 
-        ClassesGenerator gen = new ClassesGenerator(basePath, hdr, packages);
+        ClassesGenerator gen = new ClassesGenerator(basePath, hdr, packages, finaName);
 
         gen.generate();
     }
@@ -74,15 +78,20 @@ public class ClassesGenerator {
     /** */
     private final String[] packages;
 
+    /** */
+    private final String fileName;
+
     /**
      * @param basePath Base file path.
      * @param hdr Header.
      * @param packages Included packages.
+     * @param fileName Property file name.
      */
-    private ClassesGenerator(String basePath, String hdr, String[] packages) {
+    private ClassesGenerator(String basePath, String hdr, String[] packages, String fileName) {
         this.basePath = basePath;
         this.hdr = hdr;
         this.packages = packages;
+        this.fileName = fileName;
     }
 
     /**
@@ -103,7 +112,8 @@ public class ClassesGenerator {
             throw new Exception(sb.toString().trim());
         }
 
-        PrintStream out = new PrintStream(new File(basePath, FILE_PATH));
+        PrintStream out = new PrintStream(new File(basePath,
+            (fileName == null || fileName.isEmpty()) ? DEFAULT_FILE_PATH : META_INF + fileName));
 
         out.println(hdr);
         out.println();


[44/50] incubator-ignite git commit: Merge branches 'ignite-sprint-5' and 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-sprint-6

Posted by vo...@apache.org.
Merge branches 'ignite-sprint-5' and 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-sprint-6

Conflicts:
	modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
	modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryManager.java
	modules/core/src/test/java/org/apache/ignite/internal/processors/cache/query/GridCacheSwapScanQueryAbstractSelfTest.java
	modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
	modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheCrossCacheQuerySelfTest.java
	modules/scalar-2.10/pom.xml
	modules/spark-2.10/pom.xml
	modules/spark/pom.xml
	modules/visor-console-2.10/pom.xml


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

Branch: refs/heads/ignite-gg-10411
Commit: 0907338684050e952b01df06fe927707e4a280a1
Parents: 460521c
Author: Yakov Zhdanov <yz...@gridgain.com>
Authored: Mon Jun 15 10:21:53 2015 +0300
Committer: Yakov Zhdanov <yz...@gridgain.com>
Committed: Mon Jun 15 10:21:53 2015 +0300

----------------------------------------------------------------------
 .../apache/ignite/cache/query/ScanQuery.java    | 20 --------------------
 .../cache/query/GridCacheQueryManager.java      |  5 -----
 .../testsuites/IgniteCacheTestSuite4.java       |  2 --
 3 files changed, 27 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/09073386/modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java b/modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
index 90000e8..11a8c84 100644
--- a/modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
+++ b/modules/core/src/main/java/org/apache/ignite/cache/query/ScanQuery.java
@@ -119,26 +119,6 @@ public final class ScanQuery<K, V> extends Query<Cache.Entry<K, V>> {
         return this;
     }
 
-    /**
-     * Gets partition number over which this query should iterate. Will return {@code null} if partition was not
-     * set. In this case query will iterate over all partitions in the cache.
-     *
-     * @return Partition number or {@code null}.
-     */
-    @Nullable public Integer getPartition() {
-        return part;
-    }
-
-    /**
-     * Sets partition number over which this query should iterate. If {@code null}, query will iterate over
-     * all partitions in the cache. Must be in the range [0, N) where N is partition number in the cache.
-     *
-     * @param part Partition number over which this query should iterate.
-     */
-    public void setPartition(@Nullable Integer part) {
-        this.part = part;
-    }
-
     /** {@inheritDoc} */
     @Override public ScanQuery<K, V> setPageSize(int pageSize) {
         return (ScanQuery<K, V>)super.setPageSize(pageSize);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/09073386/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryManager.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryManager.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryManager.java
index 7493d07..1317d38 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryManager.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryManager.java
@@ -791,14 +791,9 @@ public abstract class GridCacheQueryManager<K, V> extends GridCacheManagerAdapte
 
                         locPart = dht.topology().localPartition(part, topVer, false);
 
-<<<<<<< HEAD
                         // double check for owning state
                         if (locPart == null || locPart.state() != OWNING || !locPart.reserve() ||
                             locPart.state() != OWNING)
-=======
-                        if (locPart == null || (locPart.state() != OWNING && locPart.state() != RENTING) ||
-                            !locPart.reserve())
->>>>>>> 4375529fa929e650f7b68d750318d67a8609ee10
                             throw new GridDhtInvalidPartitionException(part, "Partition can't be reserved");
 
                         iter = new Iterator<K>() {

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/09073386/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java b/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
index 7fa038c..c598e38 100644
--- a/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
+++ b/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
@@ -141,8 +141,6 @@ public class IgniteCacheTestSuite4 extends TestSuite {
         suite.addTestSuite(IgniteStartCacheInTransactionSelfTest.class);
         suite.addTestSuite(IgniteStartCacheInTransactionAtomicSelfTest.class);
 
-        suite.addTestSuite(IgniteCacheManyClientsTest.class);
-
         return suite;
     }
 }


[25/50] incubator-ignite git commit: ignite-1009-v4 decided to completely remove check for store on clients

Posted by vo...@apache.org.
ignite-1009-v4 decided to completely remove check for store on clients


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

Branch: refs/heads/ignite-gg-10411
Commit: 7f97ec757c9948628678f311ece52978fd53eb5a
Parents: b087aca
Author: sboikov <sb...@gridgain.com>
Authored: Fri Jun 12 14:12:28 2015 +0300
Committer: sboikov <sb...@gridgain.com>
Committed: Fri Jun 12 16:15:51 2015 +0300

----------------------------------------------------------------------
 .../processors/cache/GridCacheProcessor.java    |  11 +-
 .../dht/GridDhtTransactionalCacheAdapter.java   |   2 +-
 .../cache/transactions/IgniteTxHandler.java     |   2 +-
 .../transactions/IgniteTxLocalAdapter.java      |   6 +-
 .../cache/CacheClientStoreSelfTest.java         | 228 +++++++++++++
 ...acheReadOnlyTransactionalClientSelfTest.java | 327 -------------------
 ...CacheClientWriteBehindStoreAbstractTest.java | 104 ++++++
 ...teCacheClientWriteBehindStoreAtomicTest.java |  38 +++
 .../IgnteCacheClientWriteBehindStoreTxTest.java |  32 ++
 .../testsuites/IgniteCacheTestSuite4.java       |   2 +-
 .../IgniteCacheWriteBehindTestSuite.java        |   2 +
 11 files changed, 413 insertions(+), 341 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/7f97ec75/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProcessor.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProcessor.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProcessor.java
index 4fdec33..4428b0f 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProcessor.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProcessor.java
@@ -2278,16 +2278,7 @@ public class GridCacheProcessor extends GridProcessorAdapter {
             CU.checkAttributeMismatch(log, rmtAttr.cacheName(), rmt, "cachePreloadMode",
                 "Cache preload mode", locAttr.cacheRebalanceMode(), rmtAttr.cacheRebalanceMode(), true);
 
-            boolean checkStore;
-
-            if (!isLocAff && isRmtAff && locCfg.getAtomicityMode() == TRANSACTIONAL) {
-                checkStore = locAttr.storeFactoryClassName() != null;
-
-                if (locAttr.storeFactoryClassName() == null && rmtAttr.storeFactoryClassName() != null)
-                    desc.updatesAllowed(false);
-            }
-            else
-                checkStore = isLocAff && isRmtAff;
+            boolean checkStore = isLocAff && isRmtAff;
 
             if (checkStore)
                 CU.checkAttributeMismatch(log, rmtAttr.cacheName(), rmt, "storeFactory", "Store factory",

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/7f97ec75/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTransactionalCacheAdapter.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTransactionalCacheAdapter.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTransactionalCacheAdapter.java
index 703daf9..4f081bf 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTransactionalCacheAdapter.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTransactionalCacheAdapter.java
@@ -859,7 +859,7 @@ public abstract class GridDhtTransactionalCacheAdapter<K, V> extends GridDhtCach
                                         req.isolation(),
                                         req.timeout(),
                                         req.isInvalidate(),
-                                        false,
+                                        true,
                                         req.txSize(),
                                         null,
                                         req.subjectId(),

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/7f97ec75/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 e6d71aa..e16f7bf 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
@@ -325,7 +325,7 @@ public class IgniteTxHandler {
                     req.isolation(),
                     req.timeout(),
                     req.isInvalidate(),
-                    false,
+                    true,
                     req.txSize(),
                     req.transactionNodes(),
                     req.subjectId(),

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/7f97ec75/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxLocalAdapter.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxLocalAdapter.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxLocalAdapter.java
index 8b5eaec..bc6308b 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxLocalAdapter.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxLocalAdapter.java
@@ -503,7 +503,11 @@ public abstract class IgniteTxLocalAdapter extends IgniteTxAdapter
                     boolean skipNear = near() && isWriteToStoreFromDht;
 
                     for (IgniteTxEntry e : writeEntries) {
-                        if ((skipNear && e.cached().isNear()) || e.skipStore())
+                        boolean skip = (skipNear && e.cached().isNear()) ||
+                            e.skipStore() ||
+                            (e.context().store().isLocal() && !e.context().affinityNode());
+
+                        if (skip)
                             continue;
 
                         boolean intercept = e.context().config().getInterceptor() != null;

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/7f97ec75/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheClientStoreSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheClientStoreSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheClientStoreSelfTest.java
new file mode 100644
index 0000000..44b27be
--- /dev/null
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheClientStoreSelfTest.java
@@ -0,0 +1,228 @@
+/*
+ * 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.processors.cache;
+
+import org.apache.ignite.*;
+import org.apache.ignite.cache.*;
+import org.apache.ignite.cache.store.*;
+import org.apache.ignite.configuration.*;
+import org.apache.ignite.internal.util.typedef.*;
+import org.apache.ignite.spi.discovery.tcp.*;
+import org.apache.ignite.spi.discovery.tcp.ipfinder.*;
+import org.apache.ignite.spi.discovery.tcp.ipfinder.vm.*;
+import org.apache.ignite.testframework.junits.common.*;
+
+import javax.cache.configuration.*;
+import javax.cache.processor.*;
+
+import static org.apache.ignite.IgniteSystemProperties.*;
+
+/**
+ * Tests for cache client without store.
+ */
+public class CacheClientStoreSelfTest extends GridCommonAbstractTest {
+    /** */
+    private static final TcpDiscoveryIpFinder IP_FINDER = new TcpDiscoveryVmIpFinder(true);
+
+    /** */
+    private static final String CACHE_NAME = "test-cache";
+
+    /** */
+    private boolean client;
+
+    /** */
+    private boolean nearEnabled;
+
+    /** */
+    private Factory<CacheStore> factory;
+
+    /** {@inheritDoc} */
+    @Override protected IgniteConfiguration getConfiguration(String gridName) throws Exception {
+        IgniteConfiguration cfg = super.getConfiguration(gridName);
+
+        cfg.setClientMode(client);
+
+        CacheConfiguration cc = new CacheConfiguration();
+
+        cc.setName(CACHE_NAME);
+        cc.setAtomicityMode(CacheAtomicityMode.TRANSACTIONAL);
+        cc.setCacheStoreFactory(factory);
+
+        if (client && nearEnabled)
+            cc.setNearConfiguration(new NearCacheConfiguration());
+
+        cfg.setCacheConfiguration(cc);
+
+        TcpDiscoverySpi disco = new TcpDiscoverySpi();
+
+        disco.setIpFinder(IP_FINDER);
+
+        cfg.setDiscoverySpi(disco);
+
+        return cfg;
+    }
+
+    /** {@inheritDoc} */
+    @Override protected void beforeTestsStarted() throws Exception {
+        client = false;
+        factory = new Factory1();
+
+        startGrids(2);
+    }
+
+    /** {@inheritDoc} */
+    @Override protected void afterTestsStopped() throws Exception {
+        stopAllGrids();
+    }
+
+    /** {@inheritDoc} */
+    @Override protected void afterTest() throws Exception {
+        stopGrid();
+    }
+
+    /**
+     * @throws Exception If failed.
+     */
+    public void testCorrectStore() throws Exception {
+        client = true;
+        nearEnabled = false;
+        factory = new Factory1();
+
+        Ignite ignite = startGrid();
+
+        IgniteCache cache = ignite.cache(CACHE_NAME);
+
+        cache.get(0);
+        cache.getAll(F.asSet(0, 1));
+        cache.getAndPut(0, 0);
+        cache.getAndPutIfAbsent(0, 0);
+        cache.getAndRemove(0);
+        cache.getAndReplace(0, 0);
+        cache.put(0, 0);
+        cache.putAll(F.asMap(0, 0, 1, 1));
+        cache.putIfAbsent(0, 0);
+        cache.remove(0);
+        cache.remove(0, 0);
+        cache.removeAll(F.asSet(0, 1));
+        cache.removeAll();
+        cache.invoke(0, new EP());
+        cache.invokeAll(F.asSet(0, 1), new EP());
+    }
+
+    /**
+     * @throws Exception If failed.
+     */
+    public void testInvalidStore() throws Exception {
+        client = true;
+        nearEnabled = false;
+        factory = new Factory2();
+
+        startGrid();
+    }
+
+    /**
+     * @throws Exception If failed.
+     */
+    public void testDisabledConsistencyCheck() throws Exception {
+        client = false;
+        nearEnabled = false;
+        factory = new Factory2();
+
+        System.setProperty(IGNITE_SKIP_CONFIGURATION_CONSISTENCY_CHECK, "true");
+
+        startGrid("client-1");
+
+        factory = new Factory1();
+
+        System.clearProperty(IGNITE_SKIP_CONFIGURATION_CONSISTENCY_CHECK);
+
+        startGrid("client-2");
+    }
+
+    /**
+     * @throws Exception If failed.
+     */
+    public void testNoStoreNearDisabled() throws Exception {
+        nearEnabled = false;
+
+        doTestNoStore();
+    }
+
+    /**
+     * @throws Exception If failed.
+     */
+    public void testNoStoreNearEnabled() throws Exception {
+        nearEnabled = true;
+
+        doTestNoStore();
+    }
+
+    /**
+     * @throws Exception If failed.
+     */
+    private void doTestNoStore() throws Exception {
+        client = true;
+        factory = null;
+
+        Ignite ignite = startGrid();
+
+        IgniteCache cache = ignite.cache(CACHE_NAME);
+
+        cache.get(0);
+        cache.getAll(F.asSet(0, 1));
+        cache.getAndPut(0, 0);
+        cache.getAndPutIfAbsent(0, 0);
+        cache.getAndRemove(0);
+        cache.getAndReplace(0, 0);
+        cache.put(0, 0);
+        cache.putAll(F.asMap(0, 0, 1, 1));
+        cache.putIfAbsent(0, 0);
+        cache.remove(0);
+        cache.remove(0, 0);
+        cache.removeAll(F.asSet(0, 1));
+        cache.removeAll();
+        cache.invoke(0, new EP());
+        cache.invokeAll(F.asSet(0, 1), new EP());
+    }
+
+    /**
+     */
+    private static class Factory1 implements Factory<CacheStore> {
+        /** {@inheritDoc} */
+        @Override public CacheStore create() {
+            return null;
+        }
+    }
+
+    /**
+     */
+    private static class Factory2 implements Factory<CacheStore> {
+        /** {@inheritDoc} */
+        @Override public CacheStore create() {
+            return null;
+        }
+    }
+
+    /**
+     */
+    private static class EP implements CacheEntryProcessor {
+        @Override public Object process(MutableEntry entry, Object... arguments) {
+            return null;
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/7f97ec75/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheReadOnlyTransactionalClientSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheReadOnlyTransactionalClientSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheReadOnlyTransactionalClientSelfTest.java
deleted file mode 100644
index f2c38e1..0000000
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheReadOnlyTransactionalClientSelfTest.java
+++ /dev/null
@@ -1,327 +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.processors.cache;
-
-import org.apache.ignite.*;
-import org.apache.ignite.cache.*;
-import org.apache.ignite.cache.store.*;
-import org.apache.ignite.configuration.*;
-import org.apache.ignite.internal.util.typedef.*;
-import org.apache.ignite.spi.discovery.tcp.*;
-import org.apache.ignite.spi.discovery.tcp.ipfinder.*;
-import org.apache.ignite.spi.discovery.tcp.ipfinder.vm.*;
-import org.apache.ignite.testframework.junits.common.*;
-
-import javax.cache.*;
-import javax.cache.configuration.*;
-import javax.cache.processor.*;
-
-import static org.apache.ignite.IgniteSystemProperties.*;
-
-/**
- * Tests for read-only transactional cache client.
- */
-public class CacheReadOnlyTransactionalClientSelfTest extends GridCommonAbstractTest {
-    /** */
-    private static final TcpDiscoveryIpFinder IP_FINDER = new TcpDiscoveryVmIpFinder(true);
-
-    /** */
-    private static final String CACHE_NAME = "test-cache";
-
-    /** */
-    private boolean client;
-
-    /** */
-    private boolean nearEnabled;
-
-    /** */
-    private Factory<CacheStore> factory;
-
-    /** {@inheritDoc} */
-    @Override protected IgniteConfiguration getConfiguration(String gridName) throws Exception {
-        IgniteConfiguration cfg = super.getConfiguration(gridName);
-
-        cfg.setClientMode(client);
-
-        CacheConfiguration cc = new CacheConfiguration();
-
-        cc.setName(CACHE_NAME);
-        cc.setAtomicityMode(CacheAtomicityMode.TRANSACTIONAL);
-        cc.setCacheStoreFactory(factory);
-
-        if (client && nearEnabled)
-            cc.setNearConfiguration(new NearCacheConfiguration());
-
-        cfg.setCacheConfiguration(cc);
-
-        TcpDiscoverySpi disco = new TcpDiscoverySpi();
-
-        disco.setIpFinder(IP_FINDER);
-
-        cfg.setDiscoverySpi(disco);
-
-        return cfg;
-    }
-
-    /** {@inheritDoc} */
-    @Override protected void beforeTestsStarted() throws Exception {
-        client = false;
-        factory = new Factory1();
-
-        startGrids(2);
-    }
-
-    /** {@inheritDoc} */
-    @Override protected void afterTestsStopped() throws Exception {
-        stopAllGrids();
-    }
-
-    /** {@inheritDoc} */
-    @Override protected void afterTest() throws Exception {
-        stopGrid();
-    }
-
-    /**
-     * @throws Exception If failed.
-     */
-    public void testCorrectStore() throws Exception {
-        client = true;
-        nearEnabled = false;
-        factory = new Factory1();
-
-        Ignite ignite = startGrid();
-
-        IgniteCache cache = ignite.cache(CACHE_NAME);
-
-        cache.get(0);
-        cache.getAll(F.asSet(0, 1));
-        cache.getAndPut(0, 0);
-        cache.getAndPutIfAbsent(0, 0);
-        cache.getAndRemove(0);
-        cache.getAndReplace(0, 0);
-        cache.put(0, 0);
-        cache.putAll(F.asMap(0, 0, 1, 1));
-        cache.putIfAbsent(0, 0);
-        cache.remove(0);
-        cache.remove(0, 0);
-        cache.removeAll(F.asSet(0, 1));
-        cache.removeAll();
-        cache.invoke(0, new EP());
-        cache.invokeAll(F.asSet(0, 1), new EP());
-    }
-
-    /**
-     * @throws Exception If failed.
-     */
-    public void testInvalidStore() throws Exception {
-        client = true;
-        nearEnabled = false;
-        factory = new Factory2();
-
-        try {
-            startGrid();
-
-            assert false : "Exception was not thrown.";
-        }
-        catch (Exception e) {
-            assert e.getMessage().startsWith("Store factory mismatch") : e.getMessage();
-        }
-    }
-
-    /**
-     * @throws Exception If failed.
-     */
-    public void testDisabledConsistencyCheck() throws Exception {
-        client = false;
-        nearEnabled = false;
-        factory = new Factory2();
-
-        System.setProperty(IGNITE_SKIP_CONFIGURATION_CONSISTENCY_CHECK, "true");
-
-        startGrid("client-1");
-
-        factory = new Factory1();
-
-        System.clearProperty(IGNITE_SKIP_CONFIGURATION_CONSISTENCY_CHECK);
-
-        startGrid("client-2");
-    }
-
-    /**
-     * @throws Exception If failed.
-     */
-    public void testNoStoreNearDisabled() throws Exception {
-        nearEnabled = false;
-
-        doTestNoStore();
-    }
-
-    /**
-     * @throws Exception If failed.
-     */
-    public void testNoStoreNearEnabled() throws Exception {
-        nearEnabled = true;
-
-        doTestNoStore();
-    }
-
-    /**
-     * @throws Exception If failed.
-     */
-    private void doTestNoStore() throws Exception {
-        client = true;
-        factory = null;
-
-        Ignite ignite = startGrid();
-
-        IgniteCache cache = ignite.cache(CACHE_NAME);
-
-        cache.get(0);
-        cache.getAll(F.asSet(0, 1));
-
-        try {
-            cache.getAndPut(0, 0);
-        }
-        catch (CacheException e) {
-            assert e.getMessage().startsWith("Updates are not allowed for transactional cache: " + CACHE_NAME + ".") :
-                e.getMessage();
-        }
-
-        try {
-            cache.getAndPutIfAbsent(0, 0);
-        }
-        catch (CacheException e) {
-            assert e.getMessage().startsWith("Updates are not allowed for transactional cache: " + CACHE_NAME + ".") :
-                e.getMessage();
-        }
-
-        try {
-            cache.getAndRemove(0);
-        }
-        catch (CacheException e) {
-            assert e.getMessage().startsWith("Updates are not allowed for transactional cache: " + CACHE_NAME + ".") :
-                e.getMessage();
-        }
-
-        try {
-            cache.getAndReplace(0, 0);
-        }
-        catch (CacheException e) {
-            assert e.getMessage().startsWith("Updates are not allowed for transactional cache: " + CACHE_NAME + ".") :
-                e.getMessage();
-        }
-
-        try {
-            cache.put(0, 0);
-        }
-        catch (CacheException e) {
-            assert e.getMessage().startsWith("Updates are not allowed for transactional cache: " + CACHE_NAME + ".") :
-                e.getMessage();
-        }
-
-        try {
-            cache.putAll(F.asMap(0, 0, 1, 1));
-        }
-        catch (CacheException e) {
-            assert e.getMessage().startsWith("Updates are not allowed for transactional cache: " + CACHE_NAME + ".") :
-                e.getMessage();
-        }
-
-        try {
-            cache.putIfAbsent(0, 0);
-        }
-        catch (CacheException e) {
-            assert e.getMessage().startsWith("Updates are not allowed for transactional cache: " + CACHE_NAME + ".") :
-                e.getMessage();
-        }
-
-        try {
-            cache.remove(0);
-        }
-        catch (CacheException e) {
-            assert e.getMessage().startsWith("Updates are not allowed for transactional cache: " + CACHE_NAME + ".") :
-                e.getMessage();
-        }
-
-        try {
-            cache.remove(0, 0);
-        }
-        catch (CacheException e) {
-            assert e.getMessage().startsWith("Updates are not allowed for transactional cache: " + CACHE_NAME + ".") :
-                e.getMessage();
-        }
-
-        try {
-            cache.removeAll(F.asSet(0, 1));
-        }
-        catch (CacheException e) {
-            assert e.getMessage().startsWith("Updates are not allowed for transactional cache: " + CACHE_NAME + ".") :
-                e.getMessage();
-        }
-
-        try {
-            cache.removeAll();
-        }
-        catch (CacheException e) {
-            assert e.getMessage().startsWith("Updates are not allowed for transactional cache: " + CACHE_NAME + ".") :
-                e.getMessage();
-        }
-
-        try {
-            cache.invoke(0, new EP());
-        }
-        catch (CacheException e) {
-            assert e.getMessage().startsWith("Updates are not allowed for transactional cache: " + CACHE_NAME + ".") :
-                e.getMessage();
-        }
-
-        try {
-            cache.invokeAll(F.asSet(0, 1), new EP());
-        }
-        catch (CacheException e) {
-            assert e.getMessage().startsWith("Updates are not allowed for transactional cache: " + CACHE_NAME + ".") :
-                e.getMessage();
-        }
-    }
-
-    /**
-     */
-    private static class Factory1 implements Factory<CacheStore> {
-        /** {@inheritDoc} */
-        @Override public CacheStore create() {
-            return null;
-        }
-    }
-
-    /**
-     */
-    private static class Factory2 implements Factory<CacheStore> {
-        /** {@inheritDoc} */
-        @Override public CacheStore create() {
-            return null;
-        }
-    }
-
-    /**
-     */
-    private static class EP implements CacheEntryProcessor {
-        @Override public Object process(MutableEntry entry, Object... arguments) {
-            return null;
-        }
-    }
-}

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/7f97ec75/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/store/IgnteCacheClientWriteBehindStoreAbstractTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/store/IgnteCacheClientWriteBehindStoreAbstractTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/store/IgnteCacheClientWriteBehindStoreAbstractTest.java
new file mode 100644
index 0000000..f7c150d
--- /dev/null
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/store/IgnteCacheClientWriteBehindStoreAbstractTest.java
@@ -0,0 +1,104 @@
+/*
+ * 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.processors.cache.store;
+
+import org.apache.ignite.*;
+import org.apache.ignite.cache.*;
+import org.apache.ignite.cache.store.*;
+import org.apache.ignite.configuration.*;
+import org.apache.ignite.internal.processors.cache.*;
+import org.apache.ignite.internal.util.lang.*;
+import org.apache.ignite.testframework.*;
+
+import javax.cache.configuration.*;
+
+/**
+ * Tests that write behind store is updated if client does not have store.
+ */
+public abstract class IgnteCacheClientWriteBehindStoreAbstractTest extends IgniteCacheAbstractTest {
+    /** {@inheritDoc} */
+    @Override protected int gridCount() {
+        return 3;
+    }
+
+    /** {@inheritDoc} */
+    @Override protected CacheMode cacheMode() {
+        return CacheMode.PARTITIONED;
+    }
+
+    /** {@inheritDoc} */
+    @Override protected NearCacheConfiguration nearConfiguration() {
+        return null;
+    }
+
+    /** {@inheritDoc} */
+    @Override protected CacheConfiguration cacheConfiguration(String gridName) throws Exception {
+        CacheConfiguration ccfg = super.cacheConfiguration(gridName);
+
+        ccfg.setWriteBehindEnabled(true);
+        ccfg.setWriteBehindBatchSize(10);
+
+        if (getTestGridName(2).equals(gridName)) {
+            ccfg.setCacheStoreFactory(null);
+            ccfg.setWriteThrough(false);
+            ccfg.setReadThrough(false);
+            ccfg.setWriteBehindEnabled(false);
+        }
+
+        return ccfg;
+    }
+
+    /** {@inheritDoc} */
+    @Override protected IgniteConfiguration getConfiguration(String gridName) throws Exception {
+        IgniteConfiguration cfg = super.getConfiguration(gridName);
+
+        if (getTestGridName(2).equals(gridName))
+            cfg.setClientMode(true);
+
+        return cfg;
+    }
+
+    /** {@inheritDoc} */
+    @Override protected Factory<CacheStore> cacheStoreFactory() {
+        return new TestStoreFactory();
+    }
+
+    /**
+     * @throws Exception If failed.
+     */
+    public void testClientWithoutStore() throws Exception {
+        Ignite client = grid(2);
+
+        assertTrue(client.configuration().isClientMode());
+
+        IgniteCache<Integer, Integer> cache = client.cache(null);
+
+        assertNull(cache.getConfiguration(CacheConfiguration.class).getCacheStoreFactory());
+
+        for (int i = 0; i < 1000; i++)
+            cache.put(i, i);
+
+        GridTestUtils.waitForCondition(new GridAbsPredicate() {
+            @Override public boolean apply() {
+                return storeMap.size() == 1000;
+            }
+        }, 5000);
+
+        assertEquals(1000, storeMap.size());
+    }
+}

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/7f97ec75/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/store/IgnteCacheClientWriteBehindStoreAtomicTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/store/IgnteCacheClientWriteBehindStoreAtomicTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/store/IgnteCacheClientWriteBehindStoreAtomicTest.java
new file mode 100644
index 0000000..72ed3d6
--- /dev/null
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/store/IgnteCacheClientWriteBehindStoreAtomicTest.java
@@ -0,0 +1,38 @@
+/*
+ * 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.processors.cache.store;
+
+import org.apache.ignite.cache.*;
+
+import static org.apache.ignite.cache.CacheAtomicWriteOrderMode.*;
+import static org.apache.ignite.cache.CacheAtomicityMode.*;
+
+/**
+ *
+ */
+public class IgnteCacheClientWriteBehindStoreAtomicTest extends IgnteCacheClientWriteBehindStoreAbstractTest {
+    /** {@inheritDoc} */
+    @Override protected CacheAtomicityMode atomicityMode() {
+        return ATOMIC;
+    }
+
+    /** {@inheritDoc} */
+    @Override protected CacheAtomicWriteOrderMode atomicWriteOrderMode() {
+        return CLOCK;
+    }
+}

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/7f97ec75/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/store/IgnteCacheClientWriteBehindStoreTxTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/store/IgnteCacheClientWriteBehindStoreTxTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/store/IgnteCacheClientWriteBehindStoreTxTest.java
new file mode 100644
index 0000000..a5ced98
--- /dev/null
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/store/IgnteCacheClientWriteBehindStoreTxTest.java
@@ -0,0 +1,32 @@
+/*
+ * 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.processors.cache.store;
+
+import org.apache.ignite.cache.*;
+
+import static org.apache.ignite.cache.CacheAtomicityMode.*;
+
+/**
+ *
+ */
+public class IgnteCacheClientWriteBehindStoreTxTest extends IgnteCacheClientWriteBehindStoreAbstractTest {
+    /** {@inheritDoc} */
+    @Override protected CacheAtomicityMode atomicityMode() {
+        return TRANSACTIONAL;
+    }
+}

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/7f97ec75/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java b/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
index c598e38..83a30bd 100644
--- a/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
+++ b/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java
@@ -134,7 +134,7 @@ public class IgniteCacheTestSuite4 extends TestSuite {
 
         suite.addTestSuite(CacheJdbcStoreSessionListenerSelfTest.class);
 
-        suite.addTestSuite(CacheReadOnlyTransactionalClientSelfTest.class);
+        suite.addTestSuite(CacheClientStoreSelfTest.class);
 
         suite.addTestSuite(IgniteCacheManyClientsTest.class);
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/7f97ec75/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheWriteBehindTestSuite.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheWriteBehindTestSuite.java b/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheWriteBehindTestSuite.java
index 529b227..5abc8b2 100644
--- a/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheWriteBehindTestSuite.java
+++ b/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheWriteBehindTestSuite.java
@@ -40,6 +40,8 @@ public class IgniteCacheWriteBehindTestSuite extends TestSuite {
         suite.addTest(new TestSuite(GridCacheWriteBehindStorePartitionedTest.class));
         suite.addTest(new TestSuite(GridCacheWriteBehindStorePartitionedMultiNodeSelfTest.class));
         suite.addTest(new TestSuite(GridCachePartitionedWritesTest.class));
+        suite.addTest(new TestSuite(IgnteCacheClientWriteBehindStoreAtomicTest.class));
+        suite.addTest(new TestSuite(IgnteCacheClientWriteBehindStoreTxTest.class));
 
         return suite;
     }


[03/50] incubator-ignite git commit: GG-10406

Posted by vo...@apache.org.
GG-10406


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

Branch: refs/heads/ignite-gg-10411
Commit: f129d08c6855ca6e720ebb3bb1ea76357f54aef6
Parents: 79ae323
Author: avinogradov <av...@gridgain.com>
Authored: Tue Jun 9 15:11:27 2015 +0300
Committer: avinogradov <av...@gridgain.com>
Committed: Tue Jun 9 15:11:27 2015 +0300

----------------------------------------------------------------------
 modules/spark-2.10/README.txt | 4 ++++
 1 file changed, 4 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/f129d08c/modules/spark-2.10/README.txt
----------------------------------------------------------------------
diff --git a/modules/spark-2.10/README.txt b/modules/spark-2.10/README.txt
new file mode 100644
index 0000000..29d3930
--- /dev/null
+++ b/modules/spark-2.10/README.txt
@@ -0,0 +1,4 @@
+Apache Ignite Spark Module
+---------------------------
+
+Apache Ignite Spark module to be build with Scala 2.10.