ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sboi...@apache.org
Subject [40/50] [abbrv] ignite git commit: Merge master into ignite-gg-12163
Date Mon, 22 May 2017 15:13:08 GMT
Merge master into ignite-gg-12163


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

Branch: refs/heads/ignite-5075-pds
Commit: e809458e70cac3e7e79d9baf03d91f57a4fac04f
Parents: b0a5366 3b7e166
Author: Alexey Goncharuk <alexey.goncharuk@gmail.com>
Authored: Fri May 19 18:56:47 2017 +0300
Committer: Alexey Goncharuk <alexey.goncharuk@gmail.com>
Committed: Fri May 19 18:56:47 2017 +0300

----------------------------------------------------------------------
 assembly/LICENSE_FABRIC                         |    2 +-
 assembly/LICENSE_HADOOP                         |    2 +-
 examples/pom.xml                                |    5 +-
 .../DistributedRegressionExample.java           |  149 ++
 modules/aop/pom.xml                             |    2 +-
 modules/apache-license-gen/pom.xml              |    2 +-
 modules/aws/pom.xml                             |    2 +-
 modules/benchmarks/pom.xml                      |    2 +-
 modules/camel/pom.xml                           |    2 +-
 modules/cassandra/pom.xml                       |    2 +-
 modules/cassandra/serializers/pom.xml           |    4 +-
 modules/cassandra/store/pom.xml                 |    4 +-
 .../store/cassandra/CassandraCacheStore.java    |   16 +-
 .../session/LoadCacheCustomQueryWorker.java     |   26 +-
 .../ignite/tests/IgnitePersistentStoreTest.java |   30 +-
 .../tests/persistence/blob/ignite-config.xml    |    4 +-
 .../tests/persistence/pojo/ignite-config.xml    |    4 +-
 .../persistence/primitive/ignite-config.xml     |    4 +-
 .../primitive/ignite-remote-server-config.xml   |    4 +-
 modules/clients/pom.xml                         |    2 +-
 .../ClientAbstractMultiNodeSelfTest.java        |    3 +-
 .../processors/rest/TestMemcacheClient.java     |    2 +-
 modules/cloud/pom.xml                           |    2 +-
 modules/codegen/pom.xml                         |    2 +-
 modules/core/pom.xml                            |    2 +-
 .../org/apache/ignite/IgniteJdbcDriver.java     |   69 +-
 .../apache/ignite/IgniteSystemProperties.java   |    8 +
 .../rendezvous/RendezvousAffinityFunction.java  |   20 +-
 .../store/jdbc/CacheAbstractJdbcStore.java      |   71 +-
 .../ignite/configuration/TopologyValidator.java |   10 +-
 .../internal/ComputeTaskInternalFuture.java     |    3 -
 .../apache/ignite/internal/IgniteKernal.java    |   14 +
 .../internal/IgniteNeedReconnectException.java  |    2 +-
 .../client/impl/GridClientDataImpl.java         |    3 +-
 .../stream/v2/DirectByteBufferStreamImplV2.java |   27 +-
 .../internal/executor/GridExecutorService.java  |    3 +-
 .../internal/jdbc/JdbcDriverPropertyInfo.java   |   37 +
 .../managers/communication/GridIoManager.java   |  242 ++-
 .../deployment/GridDeploymentClassLoader.java   |    3 +-
 .../discovery/GridDiscoveryManager.java         |   19 +-
 .../affinity/AffinityTopologyVersion.java       |    9 +
 .../affinity/GridAffinityAssignmentCache.java   |    3 -
 .../affinity/GridAffinityProcessor.java         |    3 +-
 .../cache/CacheAffinitySharedManager.java       |  286 ++--
 .../CacheClientReconnectDiscoveryData.java      |  133 ++
 .../internal/processors/cache/CacheData.java    |  157 ++
 .../cache/CacheJoinNodeDiscoveryData.java       |  147 ++
 .../cache/CacheNodeCommonDiscoveryData.java     |   82 +
 .../cache/CacheStoreBalancingWrapper.java       |    3 -
 .../processors/cache/ClusterCachesInfo.java     |  913 +++++++++++
 .../cache/DynamicCacheChangeBatch.java          |   83 +-
 .../cache/DynamicCacheChangeRequest.java        |  102 +-
 .../cache/DynamicCacheDescriptor.java           |  171 +--
 .../processors/cache/ExchangeActions.java       |  338 +++++
 .../processors/cache/GridCacheAdapter.java      |  224 ++-
 .../cache/GridCacheAffinityManager.java         |    2 +-
 .../cache/GridCacheConcurrentMap.java           |    9 +-
 .../cache/GridCacheConcurrentMapImpl.java       |   35 +-
 .../processors/cache/GridCacheContext.java      |   67 +-
 .../cache/GridCacheDeploymentManager.java       |    2 +-
 .../processors/cache/GridCacheEntryInfo.java    |   68 +-
 .../processors/cache/GridCacheEventManager.java |   32 +
 .../cache/GridCacheFutureAdapter.java           |    1 +
 .../processors/cache/GridCacheLogger.java       |    2 +-
 .../processors/cache/GridCacheMapEntry.java     |   14 +-
 .../cache/GridCacheMapEntryFactory.java         |    6 +-
 .../cache/GridCacheMultiTxFuture.java           |    3 -
 .../processors/cache/GridCacheMvccManager.java  |    3 -
 .../GridCachePartitionExchangeManager.java      |   57 +-
 .../processors/cache/GridCacheProcessor.java    | 1436 +++++-------------
 .../processors/cache/GridCacheProxyImpl.java    |   60 -
 .../cache/GridCacheSharedContext.java           |   17 +-
 .../processors/cache/GridCacheUtils.java        |  146 +-
 .../processors/cache/GridNoStorageCacheMap.java |   15 +-
 .../cache/IgniteCacheOffheapManager.java        |    7 +
 .../cache/IgniteCacheOffheapManagerImpl.java    |   17 +
 .../processors/cache/IgniteCacheProxy.java      |   41 +-
 .../processors/cache/IgniteInternalCache.java   |   61 -
 .../IgniteCacheDatabaseSharedManager.java       |   14 +-
 .../cache/database/MemoryMetricsImpl.java       |    8 +-
 .../cache/database/freelist/FreeListImpl.java   |    3 +-
 .../cache/database/freelist/PagesList.java      |    3 +-
 .../cache/database/tree/BPlusTree.java          |    6 +-
 .../cache/database/tree/util/PageHandler.java   |    3 +-
 .../distributed/GridDistributedCacheEntry.java  |    8 +-
 .../dht/GridCachePartitionedConcurrentMap.java  |   23 +-
 .../dht/GridClientPartitionTopology.java        |    2 +-
 .../dht/GridDhtAffinityAssignmentRequest.java   |   36 +-
 .../dht/GridDhtAffinityAssignmentResponse.java  |   36 +-
 .../dht/GridDhtAssignmentFetchFuture.java       |   62 +-
 .../distributed/dht/GridDhtCacheAdapter.java    |  173 +--
 .../distributed/dht/GridDhtCacheEntry.java      |    8 +-
 .../distributed/dht/GridDhtEmbeddedFuture.java  |    3 -
 .../distributed/dht/GridDhtGetSingleFuture.java |    3 -
 .../distributed/dht/GridDhtLocalPartition.java  |    8 +-
 .../dht/GridDhtPartitionTopologyImpl.java       |   12 +-
 .../distributed/dht/GridDhtTxFinishFuture.java  |    3 -
 .../dht/GridPartitionedGetFuture.java           |  158 +-
 .../dht/GridPartitionedSingleGetFuture.java     |  141 +-
 .../GridDhtAtomicAbstractUpdateRequest.java     |   17 +
 .../dht/atomic/GridDhtAtomicCache.java          |  226 +--
 .../dht/atomic/GridDhtAtomicCacheEntry.java     |   11 +-
 .../dht/atomic/GridDhtAtomicUpdateRequest.java  |    7 +-
 .../dht/colocated/GridDhtColocatedCache.java    |  222 +--
 .../colocated/GridDhtColocatedCacheEntry.java   |   11 +-
 .../colocated/GridDhtDetachedCacheEntry.java    |   10 +-
 .../dht/preloader/GridDhtForceKeysFuture.java   |    7 +-
 .../dht/preloader/GridDhtPartitionDemander.java |   13 +-
 .../GridDhtPartitionSupplyMessage.java          |   30 +-
 .../GridDhtPartitionsExchangeFuture.java        |  153 +-
 .../dht/preloader/GridDhtPreloader.java         |    4 +-
 .../distributed/near/GridNearCacheAdapter.java  |   23 +-
 .../distributed/near/GridNearCacheEntry.java    |    8 +-
 .../distributed/near/GridNearGetFuture.java     |    3 -
 .../distributed/near/GridNearLockFuture.java    |    3 -
 .../cache/distributed/near/GridNearTxLocal.java |    7 +-
 .../processors/cache/local/GridLocalCache.java  |   37 +-
 .../cache/local/GridLocalCacheEntry.java        |    8 +-
 .../cache/local/GridLocalLockFuture.java        |   41 +-
 .../local/atomic/GridLocalAtomicCache.java      |  188 ++-
 .../cache/query/GridCacheQueryManager.java      |   21 +-
 .../continuous/CacheContinuousQueryHandler.java |   42 +-
 .../continuous/CacheContinuousQueryManager.java |   11 +-
 .../store/GridCacheStoreManagerAdapter.java     |    4 +-
 .../cluster/GridClusterStateProcessor.java      |   26 +-
 .../continuous/GridContinuousProcessor.java     |    3 -
 .../datastreamer/DataStreamerFuture.java        |    3 -
 .../GridAtomicCacheQueueImpl.java               |    7 +-
 .../GridCacheAtomicSequenceImpl.java            |  101 +-
 .../processors/hadoop/HadoopClasspathUtils.java |    3 +-
 .../processors/igfs/IgfsDataManager.java        |    3 -
 .../jobmetrics/GridJobMetricsProcessor.java     |    4 +-
 .../marshaller/MarshallerMappingTransport.java  |    3 -
 .../internal/processors/odbc/IgniteTypes.java   |   69 -
 .../processors/odbc/OdbcBufferedParser.java     |   81 -
 .../processors/odbc/OdbcColumnMeta.java         |  110 --
 .../processors/odbc/OdbcHandshakeRequest.java   |   83 -
 .../processors/odbc/OdbcHandshakeResult.java    |   73 -
 .../processors/odbc/OdbcMessageParser.java      |  320 ----
 .../processors/odbc/OdbcNioListener.java        |  153 +-
 .../processors/odbc/OdbcNioServerBuffer.java    |  114 --
 .../internal/processors/odbc/OdbcProcessor.java |    2 +-
 .../processors/odbc/OdbcProtocolVersion.java    |  125 --
 .../processors/odbc/OdbcQueryCloseRequest.java  |   49 -
 .../processors/odbc/OdbcQueryCloseResult.java   |   40 -
 .../odbc/OdbcQueryExecuteRequest.java           |   78 -
 .../processors/odbc/OdbcQueryExecuteResult.java |   54 -
 .../processors/odbc/OdbcQueryFetchRequest.java  |   61 -
 .../processors/odbc/OdbcQueryFetchResult.java   |   66 -
 .../odbc/OdbcQueryGetColumnsMetaRequest.java    |    4 +-
 .../odbc/OdbcQueryGetColumnsMetaResult.java     |    6 +-
 .../odbc/OdbcQueryGetParamsMetaRequest.java     |    4 +-
 .../odbc/OdbcQueryGetTablesMetaRequest.java     |    4 +-
 .../internal/processors/odbc/OdbcRequest.java   |   61 -
 .../processors/odbc/OdbcRequestHandler.java     |  532 -------
 .../internal/processors/odbc/OdbcResponse.java  |   96 --
 .../internal/processors/odbc/OdbcUtils.java     |   30 +-
 .../odbc/SqlListenerBufferedParser.java         |   81 +
 .../processors/odbc/SqlListenerColumnMeta.java  |  110 ++
 .../odbc/SqlListenerConnectionContext.java      |   56 +
 .../processors/odbc/SqlListenerDataTypes.java   |   69 +
 .../odbc/SqlListenerMessageParser.java          |   39 +
 .../odbc/SqlListenerNioServerBuffer.java        |  114 ++
 .../odbc/SqlListenerProtocolVersion.java        |  116 ++
 .../odbc/SqlListenerQueryCloseRequest.java      |   49 +
 .../odbc/SqlListenerQueryCloseResult.java       |   40 +
 .../odbc/SqlListenerQueryExecuteRequest.java    |   78 +
 .../odbc/SqlListenerQueryExecuteResult.java     |   54 +
 .../odbc/SqlListenerQueryFetchRequest.java      |   61 +
 .../odbc/SqlListenerQueryFetchResult.java       |   66 +
 .../processors/odbc/SqlListenerRequest.java     |   78 +
 .../odbc/SqlListenerRequestHandler.java         |   31 +
 .../processors/odbc/SqlListenerResponse.java    |   96 ++
 .../odbc/escape/OdbcEscapeParseResult.java      |   73 -
 .../processors/odbc/escape/OdbcEscapeToken.java |   61 -
 .../processors/odbc/escape/OdbcEscapeType.java  |  112 --
 .../processors/odbc/escape/OdbcEscapeUtils.java |  440 ------
 .../processors/odbc/odbc/OdbcMessageParser.java |  279 ++++
 .../odbc/odbc/OdbcRequestHandler.java           |  513 +++++++
 .../odbc/odbc/escape/OdbcEscapeParseResult.java |   73 +
 .../odbc/odbc/escape/OdbcEscapeToken.java       |   61 +
 .../odbc/odbc/escape/OdbcEscapeType.java        |  112 ++
 .../odbc/odbc/escape/OdbcEscapeUtils.java       |  441 ++++++
 .../platform/cluster/PlatformClusterGroup.java  |   20 +
 .../utils/PlatformConfigurationUtils.java       |    4 +-
 .../processors/query/GridQueryIndexing.java     |   36 +-
 .../processors/query/GridQueryProcessor.java    |  132 +-
 .../processors/security/SecurityContext.java    |    9 +
 .../service/GridServiceDeploymentFuture.java    |    3 -
 .../service/GridServiceProcessor.java           |   11 +
 .../ignite/internal/util/IgniteUtils.java       |   49 +-
 .../util/future/GridEmbeddedFuture.java         |    3 -
 .../internal/util/gridify/GridifyUtils.java     |    6 +-
 .../util/nio/GridNioEmbeddedFuture.java         |    3 -
 .../internal/util/nio/GridNioFutureImpl.java    |    3 -
 .../ignite/internal/util/nio/GridNioServer.java |    3 -
 .../offheap/unsafe/GridOffHeapSnapTreeMap.java  |    3 +-
 .../internal/util/worker/GridWorkerFuture.java  |    3 -
 .../node/VisorAffinityTopologyVersion.java      |   87 ++
 .../visor/node/VisorNodeDataCollectorJob.java   |    6 +
 .../node/VisorNodeDataCollectorJobResult.java   |   38 +
 .../visor/node/VisorNodeDataCollectorTask.java  |    4 +
 .../node/VisorNodeDataCollectorTaskResult.java  |   28 +-
 .../org/apache/ignite/mxbean/IgniteMXBean.java  |   44 +
 .../security/SecurityBasicPermissionSet.java    |   96 +-
 .../plugin/security/SecurityPermission.java     |   13 +-
 .../plugin/security/SecurityPermissionSet.java  |    8 +
 .../security/SecurityPermissionSetBuilder.java  |   36 +-
 .../org/apache/ignite/spi/IgniteSpiAdapter.java |    2 +-
 .../communication/tcp/TcpCommunicationSpi.java  |   20 +-
 .../ignite/spi/discovery/DiscoveryDataBag.java  |   18 +-
 .../ignite/spi/discovery/tcp/ClientImpl.java    |   41 +-
 .../ignite/spi/discovery/tcp/ServerImpl.java    |   61 +-
 .../spi/discovery/tcp/TcpDiscoveryImpl.java     |    7 +-
 .../spi/discovery/tcp/TcpDiscoverySpi.java      |   15 +-
 .../spi/discovery/tcp/TcpDiscoverySpiMBean.java |   22 +
 .../TcpDiscoveryRingLatencyCheckMessage.java    |   77 +
 .../resources/META-INF/classnames.properties    |    2 +-
 .../core/src/main/resources/ignite.properties   |    2 +-
 .../core/src/test/config/examples.properties    |    1 +
 ...ityFunctionBackupFilterAbstractSelfTest.java |   13 +-
 .../local/LocalAffinityFunctionTest.java        |    6 +-
 .../store/GridCacheBalancingStoreSelfTest.java  |   32 +-
 .../CacheJdbcPojoStoreAbstractSelfTest.java     |   49 +
 .../internal/ClusterNodeMetricsSelfTest.java    |    3 +-
 .../ComputeJobCancelWithServiceSelfTest.java    |    3 +-
 .../internal/GridNodeMetricsLogSelfTest.java    |   13 +-
 .../IgniteComputeEmptyClusterGroupTest.java     |    6 +-
 .../MarshallerContextLockingSelfTest.java       |    3 +-
 .../pagemem/impl/PageMemoryNoLoadSelfTest.java  |    3 +-
 .../processors/cache/CacheGetFromJobTest.java   |    5 +
 .../GridCacheAbstractLocalStoreSelfTest.java    |   41 +-
 .../processors/cache/GridCacheLeakTest.java     |    4 +-
 .../cache/GridCacheP2PUndeploySelfTest.java     |   12 -
 .../cache/IgniteCacheContainsKeyAtomicTest.java |  103 ++
 .../cache/IgniteCacheNoSyncForGetTest.java      |  395 +++++
 ...gniteCacheP2pUnmarshallingNearErrorTest.java |    6 +-
 .../processors/cache/IgniteCacheStartTest.java  |  191 +++
 .../cache/IgniteDynamicCacheStartSelfTest.java  |    2 +-
 ...niteTopologyValidatorGridSplitCacheTest.java |    8 +-
 .../GridCacheBinaryObjectsAbstractSelfTest.java |    3 +-
 .../IgniteCountDownLatchAbstractSelfTest.java   |    3 +-
 .../IgniteDataStructureUniqueNameTest.java      |    3 +-
 .../CacheDiscoveryDataConcurrentJoinTest.java   |  198 +++
 .../CacheLateAffinityAssignmentTest.java        |    4 +-
 .../cache/distributed/CacheStartOnJoinTest.java |  260 ++++
 .../IgniteCacheTxIteratorSelfTest.java          |   21 +-
 .../IgniteCrossCacheTxStoreSelfTest.java        |   12 +-
 ...ePartitionedBasicStoreMultiNodeSelfTest.java |   22 +-
 .../GridCachePartitionedFullApiSelfTest.java    |   18 -
 .../cache/eviction/EvictionAbstractTest.java    |   13 +-
 .../IgniteCacheClientNearCacheExpiryTest.java   |    2 +-
 .../IgniteCacheExpiryPolicyAbstractTest.java    |   15 +-
 ...eContinuousQueryReplicatedTxOneNodeTest.java |    3 +-
 ...heWriteBehindStoreMultithreadedSelfTest.java |    3 +-
 ...gniteComputeConfigVariationsFullApiTest.java |   84 +-
 .../processors/database/BPlusTreeSelfTest.java  |   75 +
 .../database/IgniteDbDynamicCacheSelfTest.java  |    2 +
 .../database/MetadataStorageSelfTest.java       |    3 +-
 ...gfsSecondaryFileSystemInjectionSelfTest.java |    6 +-
 .../processors/igfs/IgfsSizeSelfTest.java       |    2 +-
 .../odbc/OdbcEscapeSequenceSelfTest.java        |    2 +-
 .../GridServiceProcessorAbstractSelfTest.java   |    3 +-
 ...GridUnsafeDataOutputArraySizingSelfTest.java |    4 +-
 .../IpcSharedMemoryBenchmarkReader.java         |    3 +-
 .../offheap/GridOffHeapMapAbstractSelfTest.java |    3 +-
 .../unsafe/GridUnsafeMemorySelfTest.java        |    3 +-
 .../loadtests/hashmap/GridCacheTestContext.java |    4 +
 .../loadtests/hashmap/GridHashMapLoadTest.java  |    4 +-
 .../marshaller/GridMarshallerAbstractTest.java  |    6 +-
 .../ignite/messaging/GridMessagingSelfTest.java |    4 +-
 .../SecurityPermissionSetBuilderTest.java       |   83 +-
 .../TcpCommunicationSpiFaultyClientTest.java    |    3 +-
 .../testframework/junits/GridAbstractTest.java  |   12 +
 .../junits/spi/GridSpiAbstractTest.java         |    5 +
 .../testsuites/IgniteCacheTestSuite2.java       |    3 +
 .../testsuites/IgniteCacheTestSuite3.java       |    2 +-
 .../testsuites/IgniteCacheTestSuite4.java       |    9 +
 .../IgniteTopologyValidatorTestSuit.java        |   44 -
 .../IgniteTopologyValidatorTestSuite.java       |   50 +
 modules/docker/2.0.0/Dockerfile                 |   46 +
 modules/docker/2.0.0/run.sh                     |   51 +
 modules/docker/Dockerfile                       |    2 +-
 modules/extdata/p2p/pom.xml                     |    2 +-
 .../tests/p2p/P2PTestTaskExternalPath2.java     |    4 +-
 .../extdata/uri/modules/uri-dependency/pom.xml  |    2 +-
 modules/extdata/uri/pom.xml                     |    2 +-
 modules/flink/pom.xml                           |    2 +-
 .../sink/flink/FlinkIgniteSinkSelfTest.java     |    9 +-
 modules/flume/pom.xml                           |    2 +-
 modules/gce/pom.xml                             |    2 +-
 modules/geospatial/pom.xml                      |    2 +-
 modules/hadoop/pom.xml                          |    4 +-
 .../hadoop/impl/igfs/HadoopIgfsFuture.java      |    3 -
 .../hadoop/jobtracker/HadoopJobTracker.java     |   20 +-
 .../external/HadoopExternalTaskExecutor.java    |    3 -
 .../HadoopIgfs20FileSystemAbstractSelfTest.java |    3 +-
 .../IgniteHadoopFileSystemAbstractSelfTest.java |    6 +-
 .../taskexecutor/HadoopExecutorServiceTest.java |    3 +-
 modules/hibernate-4.2/pom.xml                   |    2 +-
 .../cache/hibernate/HibernateKeyWrapper.java    |    7 +
 .../HibernateL2CacheStrategySelfTest.java       |  597 ++++++++
 .../testsuites/IgniteHibernateTestSuite.java    |    2 +
 modules/hibernate-5.1/pom.xml                   |    2 +-
 .../hibernate/HibernateL2CacheSelfTest.java     |    2 +-
 .../HibernateL2CacheStrategySelfTest.java       |  569 +++++++
 .../testsuites/IgniteHibernate5TestSuite.java   |    2 +
 modules/hibernate-core/pom.xml                  |   10 +-
 .../cache/hibernate/HibernateCacheProxy.java    |   25 -
 modules/indexing/pom.xml                        |    2 +-
 .../query/h2/DmlStatementsProcessor.java        |   13 +-
 .../processors/query/h2/IgniteH2Indexing.java   |   20 +-
 .../query/h2/sql/GridSqlQuerySplitter.java      |    7 +-
 .../query/h2/twostep/GridMapQueryExecutor.java  |    4 +-
 .../query/h2/twostep/GridMergeIndexSorted.java  |    3 +
 .../cache/GridCacheCrossCacheQuerySelfTest.java |   12 +-
 .../GridCacheQueryIndexDisabledSelfTest.java    |    4 +-
 ...niteCacheAbstractInsertSqlQuerySelfTest.java |    3 +-
 .../IgniteCacheInsertSqlQuerySelfTest.java      |   22 +
 ...butedPartitionQueryNodeRestartsSelfTest.java |    6 +-
 .../query/IgniteSqlSplitterSelfTest.java        |   98 ++
 modules/jcl/pom.xml                             |    2 +-
 modules/jms11/pom.xml                           |    2 +-
 modules/jta/pom.xml                             |    2 +-
 modules/kafka/pom.xml                           |    2 +-
 .../kafka/connect/IgniteSinkConnectorTest.java  |    3 +-
 .../connect/IgniteSourceConnectorTest.java      |    3 +-
 modules/kubernetes/pom.xml                      |    2 +-
 modules/log4j/pom.xml                           |    2 +-
 modules/log4j2/pom.xml                          |    2 +-
 .../log4j2/GridLog4j2InitializedTest.java       |    3 +-
 .../log4j2/GridLog4j2LoggingFileTest.java       |    3 +-
 modules/mesos/pom.xml                           |    2 +-
 .../apache/ignite/mesos/IgniteFramework.java    |  111 +-
 .../org/apache/ignite/mesos/IgniteTask.java     |    3 +-
 .../ignite/mesos/IgniteSchedulerSelfTest.java   |   39 +-
 modules/ml/pom.xml                              |    6 +-
 .../org/apache/ignite/ml/math/Precision.java    |  588 +++++++
 .../java/org/apache/ignite/ml/math/Tracer.java  |   22 +-
 .../decompositions/CholeskyDecomposition.java   |    6 +-
 .../math/decompositions/EigenDecomposition.java |    6 +-
 .../ml/math/decompositions/LUDecomposition.java |    9 +-
 .../ml/math/decompositions/QRDecomposition.java |   70 +-
 .../SingularValueDecomposition.java             |    5 +-
 .../math/exceptions/CardinalityException.java   |    6 +-
 .../exceptions/InsufficientDataException.java   |   44 +
 .../exceptions/MathArithmeticException.java     |   47 +
 .../MathIllegalArgumentException.java           |   37 +
 .../math/exceptions/MathRuntimeException.java   |   47 +
 .../ml/math/exceptions/NoDataException.java     |   45 +
 .../NonPositiveDefiniteMatrixException.java     |    8 +-
 .../exceptions/NonSquareMatrixException.java    |   33 +
 .../math/exceptions/NullArgumentException.java  |   27 +
 .../exceptions/SingularMatrixException.java     |    9 +-
 .../ignite/ml/math/functions/Functions.java     |    5 +
 .../apache/ignite/ml/math/impls/CacheUtils.java |  111 +-
 .../ml/math/impls/matrix/AbstractMatrix.java    |    5 +
 .../impls/matrix/DenseLocalOffHeapMatrix.java   |    5 -
 .../impls/matrix/SparseDistributedMatrix.java   |   16 +-
 .../matrix/SparseDistributedMatrixStorage.java  |   89 +-
 .../math/impls/vector/SingleElementVector.java  |  103 +-
 .../apache/ignite/ml/math/util/MatrixUtil.java  |  122 ++
 .../AbstractMultipleLinearRegression.java       |  358 +++++
 .../regressions/MultipleLinearRegression.java   |   71 +
 .../OLSMultipleLinearRegression.java            |  272 ++++
 .../regressions/RegressionsErrorMessages.java   |   28 +
 .../ignite/ml/regressions/package-info.java     |   22 +
 .../ignite/ml/math/d3-matrix-template.html      |   17 +-
 .../ignite/ml/math/d3-vector-template.html      |   15 +-
 .../org/apache/ignite/ml/IgniteMLTestSuite.java |   35 +
 .../java/org/apache/ignite/ml/TestUtils.java    |  248 +++
 .../apache/ignite/ml/math/ExternalizeTest.java  |    1 +
 .../ml/math/MathImplDistributedTestSuite.java   |    2 +-
 .../ignite/ml/math/MathImplLocalTestSuite.java  |    4 +-
 .../ignite/ml/math/MathImplMainTestSuite.java   |    5 +-
 .../CholeskyDecompositionTest.java              |    6 +-
 .../decompositions/LUDecompositionTest.java     |    6 +-
 .../decompositions/QRDecompositionTest.java     |    6 +-
 .../SingularValueDecompositionTest.java         |    6 +-
 .../matrix/SparseDistributedMatrixTest.java     |   67 +-
 .../AbstractMultipleLinearRegressionTest.java   |  164 ++
 .../OLSMultipleLinearRegressionTest.java        |  819 ++++++++++
 .../ml/regressions/RegressionsTestSuite.java    |   32 +
 modules/mqtt/pom.xml                            |    2 +-
 modules/osgi-karaf/pom.xml                      |    2 +-
 modules/osgi-paxlogging/pom.xml                 |    2 +-
 modules/osgi/pom.xml                            |    2 +-
 .../pagemem/PageMemoryImplReloadSelfTest.java   |  371 -----
 .../ignite/impl/binary/binary_type_manager.h    |    6 +-
 .../src/impl/binary/binary_type_manager.cpp     |   83 +-
 modules/platforms/cpp/common/configure.ac       |    2 +-
 .../platforms/cpp/common/include/Makefile.am    |    5 +-
 .../cpp/common/include/ignite/common/promise.h  |  201 +++
 .../common/include/ignite/common/shared_state.h |  331 ++++
 .../cpp/common/include/ignite/future.h          |  236 +++
 .../cpp/common/include/ignite/ignite_error.h    |    3 +
 .../linux/include/ignite/common/concurrent_os.h |  234 ++-
 .../win/include/ignite/common/concurrent_os.h   |  169 ++-
 .../common/os/win/src/common/concurrent_os.cpp  |   26 +-
 .../cpp/common/project/vs/common.vcxproj        |    3 +
 .../common/project/vs/common.vcxproj.filters    |    9 +
 modules/platforms/cpp/configure.ac              |    2 +-
 modules/platforms/cpp/configure.acrel           |    2 +-
 modules/platforms/cpp/core-test/Makefile.am     |    1 +
 modules/platforms/cpp/core-test/configure.ac    |    2 +-
 .../cpp/core-test/project/vs/core-test.vcxproj  |    1 +
 .../project/vs/core-test.vcxproj.filters        |    4 +
 .../cpp/core-test/src/cache_query_test.cpp      |   22 +
 .../cpp/core-test/src/concurrent_test.cpp       |   47 +
 .../platforms/cpp/core-test/src/future_test.cpp |  474 ++++++
 modules/platforms/cpp/core/configure.ac         |    2 +-
 .../core/include/ignite/cache/query/query_sql.h |    8 +
 .../ignite/cache/query/query_sql_fields.h       |   10 +-
 modules/platforms/cpp/examples/configure.ac     |    2 +-
 .../putget-example/config/example-cache.xml     |   10 +-
 .../project/vs/putget-example.vcxproj           |    3 +
 .../project/vs/putget-example.vcxproj.filters   |    8 +
 .../putget-example/src/putget_example.cpp       |    2 +-
 .../project/vs/query-example.vcxproj            |    3 +
 .../project/vs/query-example.vcxproj.filters    |    8 +
 .../query-example/src/query_example.cpp         |    6 +-
 modules/platforms/cpp/ignite/configure.ac       |    2 +-
 .../cpp/odbc-test/project/vs/odbc-test.vcxproj  |    1 +
 .../project/vs/odbc-test.vcxproj.filters        |    4 +
 .../cpp/odbc-test/src/configuration_test.cpp    |   40 +-
 .../cpp/odbc-test/src/queries_test.cpp          |   62 +-
 .../cpp/odbc/include/ignite/odbc/message.h      |   45 +-
 .../odbc/include/ignite/odbc/protocol_version.h |  103 +-
 .../cpp/odbc/install/ignite-odbc-amd64.wxs      |    2 +-
 .../cpp/odbc/install/ignite-odbc-x86.wxs        |    2 +-
 .../src/system/ui/dsn_configuration_window.cpp  |   42 +-
 modules/platforms/cpp/odbc/src/connection.cpp   |   35 +-
 .../platforms/cpp/odbc/src/protocol_version.cpp |  138 +-
 .../Properties/AssemblyInfo.cs                  |    6 +-
 .../Properties/AssemblyInfo.cs                  |    6 +-
 .../Properties/AssemblyInfo.cs                  |    6 +-
 .../Properties/AssemblyInfo.cs                  |    6 +-
 .../Properties/AssemblyInfo.cs                  |    6 +-
 .../Apache.Ignite.Core.Tests.csproj             |    4 +
 .../Binary/BinaryBuilderSelfTest.cs             |   21 +-
 .../Binary/BinaryDateTimeTest.cs                |  204 +++
 .../Binary/BinaryDynamicRegistrationTest.cs     |   40 +
 .../Binary/BinaryNameMapperTest.cs              |    7 +
 .../Binary/BinarySelfTest.cs                    |   35 +-
 .../Binary/EnumsTest.cs                         |  276 ++++
 .../Binary/TypeNameParserTest.cs                |   93 +-
 .../Binary/TypeResolverTest.cs                  |  104 ++
 .../Cache/MemoryMetricsTest.cs                  |  134 ++
 .../Cache/Query/CacheLinqTest.cs                |    2 +-
 .../Cache/Query/CacheQueriesTest.cs             |    5 +-
 .../Compute/BinarizableClosureTaskTest.cs       |   10 +-
 .../Compute/ComputeApiTest.cs                   |   28 +-
 .../Compute/FailoverTaskSelfTest.cs             |   46 +-
 .../Compute/IgniteExceptionTaskSelfTest.cs      |  105 +-
 .../Compute/SerializableClosureTaskTest.cs      |   30 +-
 .../Apache.Ignite.Core.Tests/DeploymentTest.cs  |    1 +
 .../Examples/ExamplesTest.cs                    |    5 +-
 .../IgniteConfigurationSerializerTest.cs        |    6 +-
 .../IgniteConfigurationTest.cs                  |    4 +-
 .../IgniteStartStopTest.cs                      |    2 +
 .../Log/CustomLoggerTest.cs                     |    3 +-
 .../Properties/AssemblyInfo.cs                  |    6 +-
 .../Apache.Ignite.Core.csproj                   |    3 +
 .../Binary/BinaryBasicNameMapper.cs             |    6 +-
 .../Binary/BinaryReflectiveSerializer.cs        |   44 +-
 .../Binary/TimestampAttribute.cs                |   40 +
 .../Configuration/MemoryPolicyConfiguration.cs  |    9 +
 .../Apache.Ignite.Core/Cache/IMemoryMetrics.cs  |   55 +
 .../Compute/ComputeTaskAdapter.cs               |    4 +-
 .../dotnet/Apache.Ignite.Core/IIgnite.cs        |    7 +
 .../IgniteConfigurationSection.xsd              |    5 +
 .../dotnet/Apache.Ignite.Core/Ignition.cs       |   16 +-
 .../Impl/Binary/BinaryEnum.cs                   |   22 +-
 .../Impl/Binary/BinaryObject.cs                 |    2 +-
 .../Impl/Binary/BinaryProcessor.cs              |   16 +-
 .../Impl/Binary/BinaryReader.cs                 |    6 +-
 .../Impl/Binary/BinaryReflectiveActions.cs      |   97 +-
 .../BinaryReflectiveSerializerInternal.cs       |   19 +-
 .../Impl/Binary/BinarySystemHandlers.cs         |  271 ++--
 .../Impl/Binary/BinaryUtils.cs                  |   43 +-
 .../Impl/Binary/BinaryWriter.cs                 |   48 +-
 .../Binary/DeserializationCallbackProcessor.cs  |   11 +
 .../Impl/Binary/Marshaller.cs                   |   18 +-
 .../Impl/Binary/SerializableSerializer.cs       |   10 +-
 .../Impl/Binary/TypeNameParser.cs               |   31 +-
 .../Impl/Binary/TypeResolver.cs                 |  115 +-
 .../Impl/Cache/MemoryMetrics.cs                 |   62 +
 .../Impl/Cluster/ClusterGroupImpl.cs            |   27 +-
 .../Closure/ComputeAbstractClosureTask.cs       |    3 +-
 .../Apache.Ignite.Core/Impl/Compute/Compute.cs  |   17 +
 .../Impl/Compute/ComputeJobHolder.cs            |    3 +-
 .../Impl/Compute/ComputeTaskHolder.cs           |    8 +-
 .../dotnet/Apache.Ignite.Core/Impl/Ignite.cs    |    6 +
 .../Impl/Memory/PlatformMemoryStream.cs         |    2 +-
 .../Properties/AssemblyInfo.cs                  |    6 +-
 .../Properties/AssemblyInfo.cs                  |    6 +-
 .../Properties/AssemblyInfo.cs                  |    6 +-
 .../Properties/AssemblyInfo.cs                  |    6 +-
 .../Properties/AssemblyInfo.cs                  |    6 +-
 .../Properties/AssemblyInfo.cs                  |    6 +-
 .../Apache.Ignite/Properties/AssemblyInfo.cs    |    6 +-
 .../Properties/AssemblyInfo.cs                  |    6 +-
 .../Properties/AssemblyInfo.cs                  |    6 +-
 modules/rest-http/pom.xml                       |    2 +-
 modules/rocketmq/pom.xml                        |    2 +-
 modules/scalar-2.10/pom.xml                     |    2 +-
 modules/scalar/pom.xml                          |    2 +-
 modules/schedule/pom.xml                        |    2 +-
 .../processors/schedule/ScheduleFutureImpl.java |    2 +-
 modules/slf4j/pom.xml                           |    2 +-
 modules/spark-2.10/pom.xml                      |    2 +-
 modules/spark/pom.xml                           |    2 +-
 modules/spring-data/pom.xml                     |    5 +-
 modules/spring/pom.xml                          |    2 +-
 .../spring/SpringTransactionManager.java        |   32 +-
 .../jdbc/CacheJdbcPojoStoreFactorySelfTest.java |    2 +-
 .../internal/IgniteDynamicCacheConfigTest.java  |    4 +-
 .../GridSpringTransactionManagerSelfTest.java   |   42 +-
 modules/ssh/pom.xml                             |    2 +-
 modules/storm/pom.xml                           |    2 +-
 modules/tools/pom.xml                           |    2 +-
 modules/twitter/pom.xml                         |    2 +-
 modules/urideploy/pom.xml                       |    2 +-
 .../spi/deployment/uri/UriDeploymentSpi.java    |    6 +-
 .../scanners/http/UriDeploymentHttpScanner.java |    3 +-
 .../uri/GridUriDeploymentMd5CheckSelfTest.java  |    9 +-
 modules/visor-console-2.10/pom.xml              |    2 +-
 modules/visor-console/pom.xml                   |    2 +-
 modules/visor-plugins/pom.xml                   |    2 +-
 .../web-console/backend/app/agentsHandler.js    |   28 +-
 .../web-console/backend/app/browsersHandler.js  |   28 +-
 modules/web-console/backend/app/mongo.js        |    1 +
 modules/web-console/frontend/app/app.config.js  |    4 +-
 modules/web-console/frontend/app/app.js         |   17 +-
 .../activities-user-dialog.tpl.pug              |   34 +-
 .../cluster-select/cluster-select.pug           |    5 +-
 .../cluster-select/cluster-select.scss          |   30 +
 .../app/components/cluster-select/index.js      |    1 +
 .../app/components/ignite-icon/directive.js     |   67 +
 .../app/components/ignite-icon/index.js         |   25 +
 .../app/components/ignite-icon/style.scss       |   21 +
 .../list-of-registered-users.tpl.pug            |    6 +-
 .../components/web-console-footer/component.js  |   23 +
 .../app/components/web-console-footer/index.js  |   23 +
 .../components/web-console-footer/style.scss    |   55 +
 .../components/web-console-footer/template.pug  |   19 +
 .../components/web-console-header/component.js  |   47 +
 .../app/components/web-console-header/index.js  |   23 +
 .../components/web-console-header/style.scss    |  158 ++
 .../components/web-console-header/template.pug  |   34 +
 .../frontend/app/filters/byName.filter.js       |    4 +-
 .../app/filters/domainsValidation.filter.js     |    4 +-
 .../frontend/app/filters/duration.filter.js     |    4 +-
 .../frontend/app/filters/hasPojo.filter.js      |    4 +-
 .../app/helpers/jade/form/form-field-text.pug   |   55 +-
 .../frontend/app/helpers/jade/mixins.pug        |   30 +-
 .../app/modules/agent/AgentManager.service.js   |  201 ++-
 .../app/modules/branding/branding.provider.js   |    2 +-
 .../modules/branding/header-title.directive.js  |    6 +-
 .../branding/powered-by-apache.directive.js     |    3 +-
 .../generator/ConfigurationGenerator.js         |    3 +-
 .../generator/Properties.service.js             |   63 +-
 .../frontend/app/modules/demo/Demo.module.js    |    2 +-
 .../frontend/app/modules/sql/sql.controller.js  |   12 +-
 .../states/configuration/domains/general.pug    |    4 +-
 .../states/configuration/domains/query.pug      |    2 +
 .../states/configuration/igfs/secondary.pug     |    2 +-
 .../configuration/summary/summary.controller.js |    2 +-
 .../frontend/app/modules/states/signin.state.js |    2 +
 .../frontend/app/primitives/btn/index.scss      |  245 ++-
 .../app/primitives/datepicker/index.pug         |    2 +-
 .../frontend/app/primitives/dropdown/index.pug  |    7 +-
 .../frontend/app/primitives/dropdown/index.scss |   88 +-
 .../frontend/app/primitives/index.js            |    2 +
 .../frontend/app/primitives/modal/index.scss    |  182 +++
 .../frontend/app/primitives/table/index.scss    |   91 ++
 .../app/primitives/ui-grid-settings/index.scss  |   30 +-
 .../frontend/app/primitives/ui-grid/index.scss  |    6 +-
 .../frontend/controllers/domains-controller.js  |   28 +-
 .../frontend/gulpfile.babel.js/paths.js         |    2 +
 .../frontend/gulpfile.babel.js/tasks/bundle.js  |    2 +-
 .../gulpfile.babel.js/webpack/common.js         |   10 +-
 .../webpack/environments/development.js         |    5 +-
 modules/web-console/frontend/package.json       |    2 +
 .../frontend/public/images/icons/clock.svg      |    1 +
 .../frontend/public/images/icons/cross.svg      |    2 +-
 .../frontend/public/images/icons/csv.svg        |    1 +
 .../frontend/public/images/icons/download.svg   |    2 +
 .../frontend/public/images/icons/export.svg     |    1 -
 .../frontend/public/images/icons/gear.svg       |    2 +-
 .../frontend/public/images/icons/index.js       |   23 +
 .../frontend/public/images/icons/manual.svg     |    1 +
 .../frontend/public/images/ignite-logo.png      |  Bin 1982 -> 0 bytes
 .../frontend/public/images/ignite-logo.svg      |   17 +
 .../frontend/public/images/ignite-logo@2x.png   |  Bin 3325 -> 0 bytes
 .../stylesheets/_bootstrap-variables.scss       |    4 +-
 .../frontend/public/stylesheets/style.scss      |  173 +--
 .../frontend/public/stylesheets/variables.scss  |    7 +
 .../frontend/test/karma.conf.babel.js           |    6 +
 modules/web-console/frontend/views/403.tpl.pug  |    8 +-
 modules/web-console/frontend/views/404.tpl.pug  |    8 +-
 modules/web-console/frontend/views/base.pug     |    8 +-
 modules/web-console/frontend/views/base2.pug    |    8 +-
 .../views/configuration/domains-import.tpl.pug  |   11 +-
 .../frontend/views/includes/footer.pug          |   23 -
 .../frontend/views/includes/header-left.pug     |   64 +
 .../frontend/views/includes/header-right.pug    |   40 +
 .../frontend/views/includes/header.pug          |   57 -
 modules/web-console/frontend/views/index.pug    |    3 +-
 .../web-console/frontend/views/reset.tpl.pug    |   12 +-
 .../web-console/frontend/views/signin.tpl.pug   |   14 +-
 modules/web-console/pom.xml                     |    2 +-
 modules/web-console/web-agent/pom.xml           |    2 +-
 .../console/agent/handlers/ClusterListener.java |   92 +-
 .../console/agent/handlers/DemoListener.java    |    2 +-
 .../console/agent/handlers/RestListener.java    |    7 +
 .../ignite/console/agent/rest/RestExecutor.java |   21 +-
 modules/web/ignite-appserver-test/pom.xml       |    2 +-
 modules/web/ignite-websphere-test/pom.xml       |    2 +-
 modules/web/pom.xml                             |    2 +-
 modules/yardstick/pom.xml                       |    2 +-
 .../cache/IgniteGetFromComputeBenchmark.java    |  167 ++
 modules/yarn/pom.xml                            |    2 +-
 modules/zeromq/pom.xml                          |    2 +-
 modules/zookeeper/pom.xml                       |    2 +-
 parent/pom.xml                                  |    3 +-
 pom.xml                                         |   11 +-
 627 files changed, 20287 insertions(+), 8771 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/IgniteSystemProperties.java
----------------------------------------------------------------------
diff --cc modules/core/src/main/java/org/apache/ignite/IgniteSystemProperties.java
index 3746c3f,d48b1c7..3842d9b
--- a/modules/core/src/main/java/org/apache/ignite/IgniteSystemProperties.java
+++ b/modules/core/src/main/java/org/apache/ignite/IgniteSystemProperties.java
@@@ -591,22 -591,9 +596,25 @@@ public final class IgniteSystemProperti
      /** Cache start size for on-heap maps. Defaults to 4096. */
      public static final String IGNITE_CACHE_START_SIZE = "IGNITE_CACHE_START_SIZE";
  
+     /** */
+     public static final String IGNITE_START_CACHES_ON_JOIN = "IGNITE_START_CACHES_ON_JOIN";
+ 
 +    /**
 +     * Skip CRC calculation flag.
 +     */
 +    public static final String IGNITE_PDS_SKIP_CRC = "IGNITE_PDS_SKIP_CRC";
 +
 +    /**
 +     * WAL rebalance threshold.
 +     */
 +    public static final String IGNITE_PDS_PARTITION_DESTROY_CHECKPOINT_DELAY =
 +        "IGNITE_PDS_PARTITION_DESTROY_CHECKPOINT_DELAY";
 +
 +    /**
 +     * WAL rebalance threshold.
 +     */
 +     public static final String IGNITE_WAL_REBALANCE_THRESHOLD = "IGNITE_WAL_REBALANCE_THRESHOLD";
 +
      /** Returns true for system properties only avoiding sending sensitive information. */
      private static final IgnitePredicate<Map.Entry<String, String>> PROPS_FILTER = new IgnitePredicate<Map.Entry<String, String>>() {
          @Override public boolean apply(final Map.Entry<String, String> entry) {

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

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheAffinitySharedManager.java
----------------------------------------------------------------------
diff --cc modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheAffinitySharedManager.java
index 581cd3b,cec42a8..6601591
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheAffinitySharedManager.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheAffinitySharedManager.java
@@@ -691,9 -715,7 +720,8 @@@ public class CacheAffinitySharedManager
       * @param nodeId Node ID.
       * @param res Response.
       */
-     private void processAffinityAssignmentResponse(Integer cacheId, UUID nodeId,
 -    private void processAffinityAssignmentResponse(UUID nodeId, GridDhtAffinityAssignmentResponse res) {
++    private void processAffinityAssignmentResponse(UUID nodeId,
 +        GridDhtAffinityAssignmentResponse res) {
          if (log.isDebugEnabled())
              log.debug("Processing affinity assignment response [node=" + nodeId + ", res=" + res + ']');
  

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/DynamicCacheChangeRequest.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheContext.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCachePartitionExchangeManager.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProcessor.java
----------------------------------------------------------------------
diff --cc modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProcessor.java
index 047d683,06ad62d..3f26871
--- 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
@@@ -958,38 -899,20 +901,20 @@@ public class GridCacheProcessor extend
      }
  
      /**
-      *
+      * @throws IgniteCheckedException if check failed.
       */
      private void checkConsistency() throws IgniteCheckedException {
-         if (!ctx.config().isDaemon() && !getBoolean(IGNITE_SKIP_CONFIGURATION_CONSISTENCY_CHECK)) {
-             for (ClusterNode n : ctx.discovery().remoteNodes()) {
-                 if (Boolean.TRUE.equals(n.attribute(ATTR_CONSISTENCY_CHECK_SKIPPED)))
-                     continue;
- 
-                 checkTransactionConfiguration(n);
- 
-                 DeploymentMode locDepMode = ctx.config().getDeploymentMode();
-                 DeploymentMode rmtDepMode = n.attribute(IgniteNodeAttributes.ATTR_DEPLOYMENT_MODE);
- 
-                 CU.checkAttributeMismatch(
-                     log, null, n.id(), "deploymentMode", "Deployment mode",
-                     locDepMode, rmtDepMode, true);
- 
-                 for (DynamicCacheDescriptor desc : cacheDescriptors()) {
-                     CacheConfiguration rmtCfg = desc.remoteConfiguration(n.id());
- 
-                     if (rmtCfg != null) {
-                         CacheConfiguration locCfg = desc.cacheConfiguration();
+         for (ClusterNode n : ctx.discovery().remoteNodes()) {
 -            if (n.attribute(ATTR_CONSISTENCY_CHECK_SKIPPED))
++            if (Boolean.TRUE.equals(n.attribute(ATTR_CONSISTENCY_CHECK_SKIPPED)))
+                 continue;
  
-                         checkCache(locCfg, rmtCfg, n);
+             checkTransactionConfiguration(n);
  
-                         // Check plugin cache configurations.
-                         CachePluginManager pluginMgr = desc.pluginManager();
+             DeploymentMode locDepMode = ctx.config().getDeploymentMode();
+             DeploymentMode rmtDepMode = n.attribute(IgniteNodeAttributes.ATTR_DEPLOYMENT_MODE);
  
-                         pluginMgr.validateRemotes(rmtCfg, n);
-                     }
-                 }
-             }
+             CU.checkAttributeMismatch(log, null, n.id(), "deploymentMode", "Deployment mode",
+                 locDepMode, rmtDepMode, true);
          }
      }
  
@@@ -1909,59 -1794,52 +1806,59 @@@
       * @throws IgniteCheckedException If failed.
       */
      private void prepareCacheStart(
-         CacheConfiguration cfg,
-         NearCacheConfiguration nearCfg,
-         CacheType cacheType,
-         boolean clientStartOnly,
-         UUID initiatingNodeId,
-         IgniteUuid deploymentId,
-         AffinityTopologyVersion topVer,
+         CacheConfiguration startCfg,
+         @Nullable NearCacheConfiguration reqNearCfg,
+         DynamicCacheDescriptor desc,
+         AffinityTopologyVersion exchTopVer,
          @Nullable QuerySchema schema
      ) throws IgniteCheckedException {
-         CacheConfiguration ccfg = new CacheConfiguration(cfg);
+         assert !caches.containsKey(startCfg.getName()) : startCfg.getName();
  
-         IgnitePredicate nodeFilter = ccfg.getNodeFilter();
+         CacheConfiguration ccfg = new CacheConfiguration(startCfg);
  
-         ClusterNode locNode = ctx.discovery().localNode();
++        IgniteCacheProxy<?, ?> proxy = jCacheProxies.get(ccfg.getName());
 +
-         IgniteCacheProxy<?, ?> proxy = jCacheProxies.get(cfg.getName());
++        boolean proxyRestart = proxy != null && proxy.isRestarting() && !caches.containsKey(ccfg.getName());
 +
-         boolean affNodeStart = !clientStartOnly && CU.affinityNode(locNode, nodeFilter);
-         boolean clientNodeStart = locNode.id().equals(initiatingNodeId);
-         boolean proxyRestart = proxy != null && proxy.isRestarting() && !caches.containsKey(cfg.getName());
+         CacheObjectContext cacheObjCtx = ctx.cacheObjects().contextForCache(ccfg);
  
-         if (sharedCtx.cacheContext(CU.cacheId(cfg.getName())) != null)
-             return;
+         boolean affNode;
  
-         if (affNodeStart || clientNodeStart || proxyRestart || CU.isSystemCache(cfg.getName())) {
-             if (clientNodeStart && !affNodeStart) {
-                 if (nearCfg != null)
-                     ccfg.setNearConfiguration(nearCfg);
-                 else
-                     ccfg.setNearConfiguration(null);
-             }
+         if (ccfg.getCacheMode() == LOCAL) {
+             affNode = true;
  
-             CacheObjectContext cacheObjCtx = ctx.cacheObjects().contextForCache(ccfg);
+             ccfg.setNearConfiguration(null);
+         }
+         else if (CU.affinityNode(ctx.discovery().localNode(), ccfg.getNodeFilter()))
+             affNode = true;
+         else {
+             affNode = false;
  
-             GridCacheContext cacheCtx = createCache(ccfg, null, cacheType, cacheObjCtx, true);
+             ccfg.setNearConfiguration(reqNearCfg);
+         }
  
-             cacheCtx.startTopologyVersion(topVer);
+         GridCacheContext cacheCtx = createCache(ccfg,
+             null,
+             desc,
+             exchTopVer,
+             cacheObjCtx,
+             affNode,
+             true);
  
-             cacheCtx.dynamicDeploymentId(deploymentId);
+         cacheCtx.dynamicDeploymentId(desc.deploymentId());
  
-             GridCacheAdapter cache = cacheCtx.cache();
+         GridCacheAdapter cache = cacheCtx.cache();
  
-             sharedCtx.addCacheContext(cacheCtx);
+         sharedCtx.addCacheContext(cacheCtx);
  
-             caches.put(cacheCtx.name(), cache);
+         caches.put(cacheCtx.name(), cache);
  
-             startCache(cache, schema != null ? schema : new QuerySchema());
+         startCache(cache, schema != null ? schema : new QuerySchema());
  
-             onKernalStart(cache);
+         onKernalStart(cache);
 +
-             if (proxyRestart)
-                 proxy.onRestarted(cacheCtx, cache);
-         }
++        if (proxyRestart)
++            proxy.onRestarted(cacheCtx, cache);
      }
  
      /**
@@@ -2052,70 -1909,43 +1946,82 @@@
          for (GridCacheAdapter<?, ?> cache : caches.values()) {
              GridCacheContext<?, ?> cacheCtx = cache.context();
  
-             if (F.eq(cacheCtx.startTopologyVersion(), topVer)) {
+             if (cacheCtx.startTopologyVersion().equals(topVer)) {
 -                jCacheProxies.put(cacheCtx.name(), new IgniteCacheProxy(cache.context(), cache, null, false));
++                jCacheProxies.putIfAbsent(cacheCtx.name(), new IgniteCacheProxy(cache.context(), cache, null, false));
+ 
                  if (cacheCtx.preloader() != null)
                      cacheCtx.preloader().onInitialExchangeComplete(err);
- 
-                 String masked = cacheCtx.name();
- 
-                 jCacheProxies.putIfAbsent(masked, new IgniteCacheProxy(cache.context(), cache, null, false));
              }
          }
  
-         if (!F.isEmpty(reqs) && err == null) {
+         if (exchActions != null && err == null) {
 +            Collection<IgniteBiTuple<GridCacheContext, Boolean>> stopped = null;
 +
-             for (DynamicCacheChangeRequest req : reqs) {
-                 String masked = req.cacheName();
++            GridCacheContext<?, ?> stopCtx = null;
++            boolean destroy = false;
 +
-                 GridCacheContext<?, ?> stopCtx = null;
-                 boolean destroy = false;
+             for (ExchangeActions.ActionData action : exchActions.cacheStopRequests()) {
+                 stopGateway(action.request());
  
-                 if (req.stop()) {
-                     stopGateway(req);
 -                prepareCacheStop(action.request());
++                sharedCtx.database().checkpointReadLock();
 +
-                     sharedCtx.database().checkpointReadLock();
++                try {
++                    stopCtx = prepareCacheStop(action.request());
++                    destroy = action.request().destroy();
++                }
++                finally {
++                    sharedCtx.database().checkpointReadUnlock();
++                }
 +
-                     try {
-                         stopCtx = prepareCacheStop(req);
-                         destroy = req.destroy();
-                     }
-                     finally {
-                         sharedCtx.database().checkpointReadUnlock();
-                     }
++                if (stopCtx != null) {
++                    if (stopped == null)
++                        stopped = new ArrayList<>();
++
++                    stopped.add(F.<GridCacheContext, Boolean>t(stopCtx, destroy));
 +                }
-                 else if (req.close() && req.initiatingNodeId().equals(ctx.localNodeId())) {
-                     IgniteCacheProxy<?, ?> proxy = jCacheProxies.remove(masked);
+             }
  
-                     if (proxy != null) {
-                         if (proxy.context().affinityNode()) {
-                             GridCacheAdapter<?, ?> cache = caches.get(masked);
+             for (DynamicCacheChangeRequest req : exchActions.closeRequests(ctx.localNodeId())) {
+                 String cacheName = req.cacheName();
  
-                             if (cache != null)
-                                 jCacheProxies.putIfAbsent(masked, new IgniteCacheProxy(cache.context(), cache, null, false));
-                         }
-                         else {
-                             if (req.restart())
-                                 proxy.restart();
 -                IgniteCacheProxy<?, ?> proxy = jCacheProxies.get(cacheName);
++                IgniteCacheProxy<?, ?> proxy = jCacheProxies.remove(cacheName);
+ 
+                 if (proxy != null) {
+                     if (proxy.context().affinityNode()) {
+                         GridCacheAdapter<?, ?> cache = caches.get(cacheName);
+ 
+                         assert cache != null : cacheName;
+ 
 -                        jCacheProxies.put(cacheName, new IgniteCacheProxy(cache.context(), cache, null, false));
++                        jCacheProxies.putIfAbsent(cacheName, new IgniteCacheProxy(cache.context(), cache, null, false));
+                     }
+                     else {
 -                        jCacheProxies.remove(cacheName);
++                        if (req.restart())
++                            proxy.restart();
  
-                             proxy.context().gate().onStopped();
+                         proxy.context().gate().onStopped();
  
 -                        prepareCacheStop(req);
++                        sharedCtx.database().checkpointReadLock();
++
++                        try {
 +                            stopCtx = prepareCacheStop(req);
 +                            destroy = req.destroy();
 +                        }
++                        finally {
++                            sharedCtx.database().checkpointReadUnlock();
++                        }
                      }
                  }
 +
 +                if (stopCtx != null) {
 +                    if (stopped == null)
 +                        stopped = new ArrayList<>();
 +
 +                    stopped.add(F.<GridCacheContext, Boolean>t(stopCtx, destroy));
 +                }
              }
 +
 +            if (stopped != null && !sharedCtx.kernalContext().clientNode())
 +                sharedCtx.database().onCachesStopped(stopped);
          }
      }
  
@@@ -2757,14 -2319,9 +2407,13 @@@
          if (checkThreadTx)
              checkEmptyTransactions();
  
-         DynamicCacheChangeRequest t = new DynamicCacheChangeRequest(UUID.randomUUID(), cacheName, ctx.localNodeId());
+         DynamicCacheChangeRequest req = DynamicCacheChangeRequest.stopRequest(ctx, cacheName, true);
  
-         t.stop(true);
-         t.destroy(true);
++        req.stop(true);
++        req.destroy(true);
++        req.restart(restart);
 +
-         t.restart(restart);
- 
-         return F.first(initiateCacheChanges(F.asList(t), false));
+         return F.first(initiateCacheChanges(F.asList(req), false));
      }
  
      /**
@@@ -2780,14 -2336,9 +2429,13 @@@
          List<DynamicCacheChangeRequest> reqs = new ArrayList<>(cacheNames.size());
  
          for (String cacheName : cacheNames) {
-             DynamicCacheChangeRequest t = new DynamicCacheChangeRequest(UUID.randomUUID(), cacheName, ctx.localNodeId());
+             DynamicCacheChangeRequest req = DynamicCacheChangeRequest.stopRequest(ctx, cacheName, true);
  
-             t.stop(true);
-             t.destroy(true);
- 
-             t.restart(restart);
++            req.stop(true);
++            req.destroy(true);
++            req.restart(restart);
 +
-             reqs.add(t);
+             reqs.add(req);
          }
  
          GridCompoundFuture<?, ?> compoundFut = new GridCompoundFuture<>();

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheSharedContext.java
----------------------------------------------------------------------
diff --cc modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheSharedContext.java
index 0a6e499,1df74ef..04f5b85
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheSharedContext.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheSharedContext.java
@@@ -41,7 -41,9 +41,10 @@@ import org.apache.ignite.internal.pagem
  import org.apache.ignite.internal.pagemem.wal.IgniteWriteAheadLogManager;
  import org.apache.ignite.internal.processors.affinity.AffinityTopologyVersion;
  import org.apache.ignite.internal.processors.cache.database.IgniteCacheDatabaseSharedManager;
 +import org.apache.ignite.internal.processors.cache.database.IgniteCacheSnapshotManager;
+ import org.apache.ignite.internal.processors.cache.distributed.dht.GridDhtPartitionTopology;
+ import org.apache.ignite.internal.processors.cache.distributed.dht.preloader.GridDhtPartitionExchangeId;
+ import org.apache.ignite.internal.processors.cache.distributed.dht.preloader.GridDhtPartitionsExchangeFuture;
  import org.apache.ignite.internal.processors.cache.distributed.near.GridNearTxLocal;
  import org.apache.ignite.internal.processors.cache.jta.CacheJtaManagerAdapter;
  import org.apache.ignite.internal.processors.cache.store.CacheStoreManager;

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/IgniteCacheOffheapManager.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/IgniteCacheOffheapManagerImpl.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/IgniteCacheProxy.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/database/IgniteCacheDatabaseSharedManager.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/database/tree/BPlusTree.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridClientPartitionTopology.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtAssignmentFetchFuture.java
----------------------------------------------------------------------
diff --cc modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtAssignmentFetchFuture.java
index eae27a2,741ca5e..20d1722
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtAssignmentFetchFuture.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtAssignmentFetchFuture.java
@@@ -83,12 -88,13 +88,13 @@@ public class GridDhtAssignmentFetchFutu
          AffinityTopologyVersion topVer,
          DiscoCache discoCache
      ) {
 -        this.topVer = topVer;
 -        this.cacheId = cacheDesc.cacheId();
          this.ctx = ctx;
-         int cacheId = CU.cacheId(cacheName);
++        cacheId = cacheDesc.cacheId();
++        this.topVer = topVer;
  
-         key = new T2<>(cacheId, topVer);
+         id = idGen.getAndIncrement();
  
-         Collection<ClusterNode> availableNodes = discoCache.cacheAffinityNodes(cacheId);
+         Collection<ClusterNode> availableNodes = discoCache.cacheAffinityNodes(cacheDesc.cacheId());
  
          LinkedList<ClusterNode> tmp = new LinkedList<>();
  

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtCacheEntry.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtGetSingleFuture.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtLocalPartition.java
----------------------------------------------------------------------
diff --cc modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtLocalPartition.java
index 3ee6952,6fb557a..1d910a3
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtLocalPartition.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtLocalPartition.java
@@@ -896,33 -900,28 +896,35 @@@ public class GridDhtLocalPartition exte
                          CacheDataRow row = it0.next();
  
                          GridCacheMapEntry cached = putEntryIfObsoleteOrAbsent(cctx.affinity().affinityTopologyVersion(),
-                             row.key(), null, true, false);
+                             row.key(),
+                             true,
+                             false);
  
 -                        if (cached instanceof GridDhtCacheEntry && ((GridDhtCacheEntry)cached).clearInternal(clearVer, extras)) {
 -                            if (rec) {
 -                                cctx.events().addEvent(cached.partition(),
 -                                    cached.key(),
 -                                    cctx.localNodeId(),
 -                                    (IgniteUuid)null,
 -                                    null,
 -                                    EVT_CACHE_REBALANCE_OBJECT_UNLOADED,
 -                                    null,
 -                                    false,
 -                                    cached.rawGet(),
 -                                    cached.hasValue(),
 -                                    null,
 -                                    null,
 -                                    null,
 -                                    false);
 +                        cctx.shared().database().checkpointReadLock();
 +
 +                        try {
 +                            if (cached instanceof GridDhtCacheEntry && ((GridDhtCacheEntry)cached).clearInternal(clearVer, extras)) {
 +                                if (rec) {
 +                                    cctx.events().addEvent(cached.partition(),
 +                                        cached.key(),
 +                                        cctx.localNodeId(),
 +                                        (IgniteUuid)null,
 +                                        null,
 +                                        EVT_CACHE_REBALANCE_OBJECT_UNLOADED,
 +                                        null,
 +                                        false,
 +                                        cached.rawGet(),
 +                                        cached.hasValue(),
 +                                        null,
 +                                        null,
 +                                        null,
 +                                        false);
 +                                }
                              }
                          }
 +                        finally {
 +                            cctx.shared().database().checkpointReadUnlock();
 +                        }
                      }
                      catch (GridDhtInvalidPartitionException e) {
                          assert isEmpty() && state() == EVICTED : "Invalid error [e=" + e + ", part=" + this + ']';

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtPartitionTopologyImpl.java
----------------------------------------------------------------------
diff --cc modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtPartitionTopologyImpl.java
index e00f0ee,8e79eda..938c1be
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtPartitionTopologyImpl.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtPartitionTopologyImpl.java
@@@ -414,81 -506,88 +414,81 @@@ import static org.apache.ignite.interna
  
          cctx.shared().database().checkpointReadLock();
  
 -        synchronized (cctx.shared().exchange().interruptLock()) {
 -            if (Thread.currentThread().isInterrupted())
 -                throw new IgniteInterruptedCheckedException("Thread is interrupted: " + Thread.currentThread());
 +        try {
 +            synchronized (cctx.shared().exchange().interruptLock()) {
 +                if (Thread.currentThread().isInterrupted())
 +                    throw new IgniteInterruptedCheckedException("Thread is interrupted: " + Thread.currentThread());
  
 -            try {
                  U.writeLock(lock);
 -            }
 -            catch (IgniteInterruptedCheckedException e) {
 -                cctx.shared().database().checkpointReadUnlock();
  
 -                throw e;
 -            }
 +                try {
 +                    GridDhtPartitionExchangeId exchId = exchFut.exchangeId();
  
 -            try {
 -                GridDhtPartitionExchangeId exchId = exchFut.exchangeId();
 +                    if (stopping)
 +                        return;
  
 -                if (stopping)
 -                    return;
 +                    assert topVer.equals(exchId.topologyVersion()) : "Invalid topology version [topVer=" +
 +                        topVer + ", exchId=" + exchId + ']';
  
 -                assert topVer.equals(exchId.topologyVersion()) : "Invalid topology version [topVer=" +
 -                    topVer + ", exchId=" + exchId + ']';
 +                    if (exchId.isLeft())
 +                        removeNode(exchId.nodeId());
  
 -                if (exchId.isLeft())
 -                    removeNode(exchId.nodeId());
 +                    ClusterNode oldest = discoCache.oldestAliveServerNodeWithCache();
  
 -                ClusterNode oldest = discoCache.oldestAliveServerNodeWithCache();
 +                    if (log.isDebugEnabled())
 +                        log.debug("Partition map beforeExchange [exchId=" + exchId + ", fullMap=" + fullMapString() + ']');
  
 -                if (log.isDebugEnabled())
 -                    log.debug("Partition map beforeExchange [exchId=" + exchId + ", fullMap=" + fullMapString() + ']');
 +                    long updateSeq = this.updateSeq.incrementAndGet();
  
 -                long updateSeq = this.updateSeq.incrementAndGet();
 +                    cntrMap.clear();
  
 -                cntrMap.clear();
 +                    // If this is the oldest node.
-                     if (oldest != null && (loc.equals(oldest) || exchFut.isCacheAdded(cctx.cacheId(), exchId.topologyVersion()))) {
++                    if (oldest != null && (loc.equals(oldest) || exchFut.cacheAddedOnExchange(cctx.cacheId(), cctx.receivedFrom()))) {
 +                        if (node2part == null) {
 +                            node2part = new GridDhtPartitionFullMap(oldest.id(), oldest.order(), updateSeq);
  
 -                // If this is the oldest node.
 -                if (oldest != null && (loc.equals(oldest) || exchFut.cacheAddedOnExchange(cctx.cacheId(), cctx.receivedFrom()))) {
 -                    if (node2part == null) {
 -                        node2part = new GridDhtPartitionFullMap(oldest.id(), oldest.order(), updateSeq);
 +                            if (log.isDebugEnabled())
 +                                log.debug("Created brand new full topology map on oldest node [exchId=" +
 +                                    exchId + ", fullMap=" + fullMapString() + ']');
 +                        }
 +                        else if (!node2part.valid()) {
 +                            node2part = new GridDhtPartitionFullMap(oldest.id(), oldest.order(), updateSeq, node2part, false);
  
 -                        if (log.isDebugEnabled())
 -                            log.debug("Created brand new full topology map on oldest node [exchId=" +
 -                                exchId + ", fullMap=" + fullMapString() + ']');
 -                    }
 -                    else if (!node2part.valid()) {
 -                        node2part = new GridDhtPartitionFullMap(oldest.id(), oldest.order(), updateSeq, node2part, false);
 +                            if (log.isDebugEnabled())
 +                                log.debug("Created new full topology map on oldest node [exchId=" + exchId + ", fullMap=" +
 +                                    node2part + ']');
 +                        }
 +                        else if (!node2part.nodeId().equals(loc.id())) {
 +                            node2part = new GridDhtPartitionFullMap(oldest.id(), oldest.order(), updateSeq, node2part, false);
  
 -                        if (log.isDebugEnabled())
 -                            log.debug("Created new full topology map on oldest node [exchId=" + exchId + ", fullMap=" +
 -                                node2part + ']');
 +                            if (log.isDebugEnabled())
 +                                log.debug("Copied old map into new map on oldest node (previous oldest node left) [exchId=" +
 +                                    exchId + ", fullMap=" + fullMapString() + ']');
 +                        }
                      }
 -                    else if (!node2part.nodeId().equals(loc.id())) {
 -                        node2part = new GridDhtPartitionFullMap(oldest.id(), oldest.order(), updateSeq, node2part, false);
  
 -                        if (log.isDebugEnabled())
 -                            log.debug("Copied old map into new map on oldest node (previous oldest node left) [exchId=" +
 -                                exchId + ", fullMap=" + fullMapString() + ']');
 +                    if (affReady)
 +                        initPartitions0(exchFut, updateSeq);
 +                    else {
 +                        List<List<ClusterNode>> aff = cctx.affinity().idealAssignment();
 +
 +                        createPartitions(aff, updateSeq);
                      }
 -                }
  
 -                if (affReady)
 -                    initPartitions0(exchFut, updateSeq);
 -                else {
 -                    List<List<ClusterNode>> aff = cctx.affinity().idealAssignment();
 +                    consistencyCheck();
  
 -                    createPartitions(aff, updateSeq);
 +                    if (log.isDebugEnabled())
 +                        log.debug("Partition map after beforeExchange [exchId=" + exchId + ", fullMap=" +
 +                            fullMapString() + ']');
 +                }
 +                finally {
 +                    lock.writeLock().unlock();
                  }
 -
 -                consistencyCheck();
 -
 -                if (log.isDebugEnabled())
 -                    log.debug("Partition map after beforeExchange [exchId=" + exchId + ", fullMap=" +
 -                        fullMapString() + ']');
 -            }
 -            finally {
 -                lock.writeLock().unlock();
 -
 -                cctx.shared().database().checkpointReadUnlock();
              }
          }
 -
 -        // Wait for evictions.
 -        waitForRent();
 +        finally {
 +            cctx.shared().database().checkpointReadUnlock();
 +        }
      }
  
      /** {@inheritDoc} */

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridPartitionedGetFuture.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridPartitionedSingleGetFuture.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/atomic/GridDhtAtomicCache.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtForceKeysFuture.java
----------------------------------------------------------------------
diff --cc modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtForceKeysFuture.java
index 1996a98,562a165..d72d8db
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtForceKeysFuture.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtForceKeysFuture.java
@@@ -567,11 -562,9 +564,11 @@@ public final class GridDhtForceKeysFutu
                      catch (GridCacheEntryRemovedException ignore) {
                          if (log.isDebugEnabled())
                              log.debug("Trying to rebalance removed entry (will ignore) [cacheName=" +
-                                 cctx.namex() + ", entry=" + entry + ']');
+                                 cctx.name() + ", entry=" + entry + ']');
                      }
                      finally {
 +                        cctx.shared().database().checkpointReadUnlock();
 +
                          locPart.release();
                      }
                  }

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPartitionDemander.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPartitionSupplyMessage.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPartitionsExchangeFuture.java
----------------------------------------------------------------------
diff --cc modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPartitionsExchangeFuture.java
index af614ee,544f847..e64f0dd
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPartitionsExchangeFuture.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPartitionsExchangeFuture.java
@@@ -62,11 -59,10 +62,11 @@@ import org.apache.ignite.internal.proce
  import org.apache.ignite.internal.processors.cache.ClusterState;
  import org.apache.ignite.internal.processors.cache.DynamicCacheChangeBatch;
  import org.apache.ignite.internal.processors.cache.CachePartitionExchangeWorkerTask;
- import org.apache.ignite.internal.processors.cache.DynamicCacheChangeRequest;
  import org.apache.ignite.internal.processors.cache.DynamicCacheDescriptor;
+ import org.apache.ignite.internal.processors.cache.ExchangeActions;
  import org.apache.ignite.internal.processors.cache.GridCacheContext;
  import org.apache.ignite.internal.processors.cache.GridCacheMvccCandidate;
 +import org.apache.ignite.internal.processors.cache.GridCacheProcessor;
  import org.apache.ignite.internal.processors.cache.GridCacheSharedContext;
  import org.apache.ignite.internal.processors.cache.distributed.dht.GridClientPartitionTopology;
  import org.apache.ignite.internal.processors.cache.distributed.dht.GridDhtLocalPartition;
@@@ -550,8 -503,8 +530,8 @@@ public class GridDhtPartitionsExchangeF
              if (discoEvt.type() == EVT_DISCOVERY_CUSTOM_EVT) {
                  DiscoveryCustomMessage msg = ((DiscoveryCustomEvent)discoEvt).customMessage();
  
 -                if (msg instanceof DynamicCacheChangeBatch){
 +                if (msg instanceof DynamicCacheChangeBatch) {
-                     assert !F.isEmpty(reqs);
+                     assert exchActions != null && !exchActions.empty();
  
                      exchange = onCacheChangeRequest(crdNode);
                  }
@@@ -730,11 -627,10 +718,10 @@@
              GridDhtPartitionTopology top = cacheCtx.topology();
  
              if (crd) {
-                 boolean updateTop = !cacheCtx.isLocal() &&
-                     exchId.topologyVersion().equals(cacheCtx.startTopologyVersion());
+                 boolean updateTop = exchId.topologyVersion().equals(cacheCtx.startTopologyVersion());
  
                  if (updateTop && clientTop != null)
 -                    top.update(exchId, clientTop.partitionMap(true), clientTop.updateCounters(false));
 +                    top.update(this, clientTop.partitionMap(true), clientTop.updateCounters(false), Collections.<Integer>emptySet());
              }
  
              top.updateTopologyVersion(exchId, this, updSeq, stopping(cacheCtx.cacheId()));
@@@ -948,21 -837,12 +923,27 @@@
      }
  
      /**
 +     * @param snapOpMsg Snapshot operation message.
 +     */
 +    private void startLocalSnasphotOperation(
 +        StartSnapshotOperationAckDiscoveryMessage snapOpMsg
 +    ) throws IgniteCheckedException {
 +        IgniteInternalFuture fut = cctx.snapshot().startLocalSnapshotOperation(
 +            snapOpMsg.initiatorNodeId(),
 +            snapOpMsg.snapshotOperation()
 +        );
 +
 +        if (fut != null)
 +            fut.get();
 +    }
 +
 +    /**
+      * The main purpose of this method is to wait for all ongoing updates (transactional and atomic), initiated on
+      * the previous topology version, to finish to prevent inconsistencies during rebalancing and to prevent two
+      * different simultaneous owners of the same lock.
+      * For the exact list of the objects being awaited for see
+      * {@link GridCacheSharedContext#partitionReleaseFuture(AffinityTopologyVersion)} javadoc.
+      *
       * @throws IgniteCheckedException If failed.
       */
      private void waitPartitionRelease() throws IgniteCheckedException {
@@@ -1303,25 -1156,9 +1267,23 @@@
  
          cctx.exchange().onExchangeDone(this, err);
  
-         if (!F.isEmpty(reqs) && err == null) {
-             for (DynamicCacheChangeRequest req : reqs)
-                 cctx.cache().completeStartFuture(req);
-         }
+         if (exchActions != null && err == null)
+             exchActions.completeRequestFutures(cctx);
  
 +        StartSnapshotOperationAckDiscoveryMessage snapshotOperationMsg = getSnapshotOperationMessage();
 +
 +        if (snapshotOperationMsg != null) {
 +            SnapshotOperation op = snapshotOperationMsg.snapshotOperation();
 +
 +            if (op.type() == SnapshotOperationType.RESTORE)
 +                try {
 +                    startLocalSnasphotOperation(snapshotOperationMsg);
 +                }
 +                catch (IgniteCheckedException e) {
 +                    log.error("Error while starting snapshot operation", e);
 +                }
 +        }
 +
          if (exchangeOnChangeGlobalState && err == null)
              cctx.kernalContext().state().onExchangeDone();
  

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPreloader.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearGetFuture.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearLockFuture.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/cluster/GridClusterStateProcessor.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/query/GridQueryIndexing.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/processors/query/GridQueryProcessor.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/java/org/apache/ignite/internal/util/IgniteUtils.java
----------------------------------------------------------------------
diff --cc modules/core/src/main/java/org/apache/ignite/internal/util/IgniteUtils.java
index 828ca07,0668708..c3de1f7
mode 100755,100644..100755
--- a/modules/core/src/main/java/org/apache/ignite/internal/util/IgniteUtils.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/util/IgniteUtils.java

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/main/resources/META-INF/classnames.properties
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteDynamicCacheStartSelfTest.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/test/java/org/apache/ignite/loadtests/hashmap/GridCacheTestContext.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/test/java/org/apache/ignite/spi/communication/tcp/TcpCommunicationSpiFaultyClientTest.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/core/src/test/java/org/apache/ignite/testframework/junits/GridAbstractTest.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/IgniteH2Indexing.java
----------------------------------------------------------------------
diff --cc modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/IgniteH2Indexing.java
index e31ca45,599baa1..5f16fdd
--- 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
@@@ -165,8 -163,8 +164,7 @@@ import org.h2.command.ddl.CreateTableDa
  import org.h2.command.dml.Insert;
  import org.h2.engine.Session;
  import org.h2.engine.SysProperties;
 -import org.h2.index.Cursor;
  import org.h2.index.Index;
- import org.h2.index.SpatialIndex;
  import org.h2.jdbc.JdbcConnection;
  import org.h2.jdbc.JdbcPreparedStatement;
  import org.h2.jdbc.JdbcStatement;

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/modules/web-console/frontend/app/modules/agent/AgentManager.service.js
----------------------------------------------------------------------
diff --cc modules/web-console/frontend/app/modules/agent/AgentManager.service.js
index 59133a2,c511242..a7196f1
--- a/modules/web-console/frontend/app/modules/agent/AgentManager.service.js
+++ b/modules/web-console/frontend/app/modules/agent/AgentManager.service.js
@@@ -16,8 -16,11 +16,10 @@@
   */
  
  import io from 'socket.io-client'; // eslint-disable-line no-unused-vars
 +import maskNull from 'app/core/utils/maskNull';
  
+ import { BehaviorSubject } from 'rxjs/BehaviorSubject';
+ 
 -const maskNull = (val) => _.isNil(val) ? 'null' : val;
 -
  const State = {
      INIT: 'INIT',
      AGENT_DISCONNECTED: 'AGENT_DISCONNECTED',

http://git-wip-us.apache.org/repos/asf/ignite/blob/e809458e/pom.xml
----------------------------------------------------------------------


Mime
View raw message