incubator-ignite git commit: # ignite-1265

2015-08-19 Thread sboikov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-1265 5065a1ecc -> 8b3fed850


# ignite-1265


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

Branch: refs/heads/ignite-1265
Commit: 8b3fed850ccc4527a6593c5ec4e596ca6c08b61f
Parents: 5065a1e
Author: sboikov 
Authored: Wed Aug 19 09:32:54 2015 +0300
Committer: sboikov 
Committed: Wed Aug 19 10:26:10 2015 +0300

--
 .../CachePartialUpdateCheckedException.java | 11 ---
 ...teAtomicCacheEntryProcessorNodeJoinTest.java | 32 
 .../IgniteCacheEntryProcessorNodeJoinTest.java  | 25 ---
 .../testsuites/IgniteCacheTestSuite2.java   |  3 ++
 4 files changed, 55 insertions(+), 16 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8b3fed85/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CachePartialUpdateCheckedException.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CachePartialUpdateCheckedException.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CachePartialUpdateCheckedException.java
index c2259df..fc846f1 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CachePartialUpdateCheckedException.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CachePartialUpdateCheckedException.java
@@ -47,8 +47,9 @@ public class CachePartialUpdateCheckedException extends 
IgniteCheckedException {
  * Gets collection of failed keys.
  * @return Collection of failed keys.
  */
-public  Collection failedKeys() {
-return (Collection)failedKeys;
+@SuppressWarnings("unchecked")
+public synchronized  Collection failedKeys() {
+return new HashSet<>((Collection)failedKeys);
 }
 
 /**
@@ -56,7 +57,7 @@ public class CachePartialUpdateCheckedException extends 
IgniteCheckedException {
  * @param err Error.
  * @param topVer Topology version for failed update.
  */
-public void add(Collection failedKeys, Throwable err, 
AffinityTopologyVersion topVer) {
+public synchronized void add(Collection failedKeys, Throwable err, 
AffinityTopologyVersion topVer) {
 if (topVer != null) {
 AffinityTopologyVersion topVer0 = this.topVer;
 
@@ -72,7 +73,7 @@ public class CachePartialUpdateCheckedException extends 
IgniteCheckedException {
 /**
  * @return Topology version.
  */
-public AffinityTopologyVersion topologyVersion() {
+public synchronized AffinityTopologyVersion topologyVersion() {
 return topVer;
 }
 
@@ -80,7 +81,7 @@ public class CachePartialUpdateCheckedException extends 
IgniteCheckedException {
  * @param failedKeys Failed keys.
  * @param err Error.
  */
-public void add(Collection failedKeys, Throwable err) {
+public synchronized void add(Collection failedKeys, Throwable err) {
 add(failedKeys, err, null);
 }
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8b3fed85/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteAtomicCacheEntryProcessorNodeJoinTest.java
--
diff --git 
a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteAtomicCacheEntryProcessorNodeJoinTest.java
 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteAtomicCacheEntryProcessorNodeJoinTest.java
new file mode 100644
index 000..af87a7d
--- /dev/null
+++ 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteAtomicCacheEntryProcessorNodeJoinTest.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.

incubator-ignite git commit: ignite-1263 Fixed timestamp and CLOB type detection. Closes #21.

2015-08-19 Thread anovikov
Repository: incubator-ignite
Updated Branches:
  refs/heads/master 09da9c2a3 -> e9a0d06ff


ignite-1263 Fixed timestamp and CLOB type detection. Closes #21.


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

Branch: refs/heads/master
Commit: e9a0d06ffa104c0e54e0e95b0af229f7648d22d1
Parents: 09da9c2
Author: Vasiliy Sisko 
Authored: Wed Aug 19 14:33:52 2015 +0700
Committer: Andrey 
Committed: Wed Aug 19 14:33:52 2015 +0700

--
 .../ignite/schema/model/PojoDescriptor.java |   6 +-
 .../parser/dialect/OracleMetadataDialect.java   | 101 ++-
 2 files changed, 57 insertions(+), 50 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/e9a0d06f/modules/schema-import/src/main/java/org/apache/ignite/schema/model/PojoDescriptor.java
--
diff --git 
a/modules/schema-import/src/main/java/org/apache/ignite/schema/model/PojoDescriptor.java
 
b/modules/schema-import/src/main/java/org/apache/ignite/schema/model/PojoDescriptor.java
index 5e1da06..5a4a1fa 100644
--- 
a/modules/schema-import/src/main/java/org/apache/ignite/schema/model/PojoDescriptor.java
+++ 
b/modules/schema-import/src/main/java/org/apache/ignite/schema/model/PojoDescriptor.java
@@ -504,7 +504,11 @@ public class PojoDescriptor {
 case TIMESTAMP:
 return java.sql.Timestamp.class;
 
-// BINARY, VARBINARY, LONGVARBINARY, ARRAY, BLOB, CLOB, NCLOB, 
NULL, DATALINK
+case CLOB:
+case NCLOB:
+return String.class;
+
+// BINARY, VARBINARY, LONGVARBINARY, ARRAY, BLOB, NULL, DATALINK
 // OTHER, JAVA_OBJECT, DISTINCT, STRUCT, REF, ROWID, SQLXML
 default:
 return Object.class;

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/e9a0d06f/modules/schema-import/src/main/java/org/apache/ignite/schema/parser/dialect/OracleMetadataDialect.java
--
diff --git 
a/modules/schema-import/src/main/java/org/apache/ignite/schema/parser/dialect/OracleMetadataDialect.java
 
b/modules/schema-import/src/main/java/org/apache/ignite/schema/parser/dialect/OracleMetadataDialect.java
index 860ff68..30dda5d 100644
--- 
a/modules/schema-import/src/main/java/org/apache/ignite/schema/parser/dialect/OracleMetadataDialect.java
+++ 
b/modules/schema-import/src/main/java/org/apache/ignite/schema/parser/dialect/OracleMetadataDialect.java
@@ -87,73 +87,76 @@ public class OracleMetadataDialect extends 
DatabaseMetadataDialect {
  * @throws SQLException If failed to decode type.
  */
 private int decodeType(ResultSet rs) throws SQLException {
-switch (rs.getString(DATA_TYPE_IDX)) {
-case "CHAR":
-case "NCHAR":
-return CHAR;
+String type = rs.getString(DATA_TYPE_IDX);
 
-case "VARCHAR2":
-case "NVARCHAR2":
-return VARCHAR;
+if (type.startsWith("TIMESTAMP"))
+return TIMESTAMP;
+else {
+switch (type) {
+case "CHAR":
+case "NCHAR":
+return CHAR;
 
-case "LONG":
-return LONGVARCHAR;
+case "VARCHAR2":
+case "NVARCHAR2":
+return VARCHAR;
 
-case "LONG RAW":
-return LONGVARBINARY;
+case "LONG":
+return LONGVARCHAR;
 
-case "FLOAT":
-return FLOAT;
+case "LONG RAW":
+return LONGVARBINARY;
 
-case "NUMBER":
-int precision = rs.getInt(DATA_PRECISION_IDX);
-int scale = rs.getInt(DATA_SCALE_IDX);
+case "FLOAT":
+return FLOAT;
 
-if (scale > 0) {
-if (scale < 4 && precision < 19)
-return FLOAT;
+case "NUMBER":
+int precision = rs.getInt(DATA_PRECISION_IDX);
+int scale = rs.getInt(DATA_SCALE_IDX);
 
-if (scale > 4 || precision > 19)
-return DOUBLE;
+if (scale > 0) {
+if (scale < 4 && precision < 19)
+return FLOAT;
 
-return NUMERIC;
-}
-else {
-if (precision < 1)
-return INTEGER;
+if (scale > 4 || pre

[29/50] incubator-ignite git commit: # ignite-1228

2015-08-19 Thread vozerov
# ignite-1228

Signed-off-by: Valentin Kulichenko 


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

Branch: refs/heads/ignite-gg-9615-1
Commit: e5eef50844580bd9ef2dba6bdfc1efca8992e78a
Parents: 8ecddcc
Author: Valentin Kulichenko 
Authored: Tue Aug 11 18:34:58 2015 -0700
Committer: Valentin Kulichenko 
Committed: Thu Aug 13 18:57:20 2015 -0700

--
 .../main/java/org/apache/ignite/logger/log4j/Log4JLogger.java| 4 
 1 file changed, 4 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/e5eef508/modules/log4j/src/main/java/org/apache/ignite/logger/log4j/Log4JLogger.java
--
diff --git 
a/modules/log4j/src/main/java/org/apache/ignite/logger/log4j/Log4JLogger.java 
b/modules/log4j/src/main/java/org/apache/ignite/logger/log4j/Log4JLogger.java
index e3828ab..bc843fb 100644
--- 
a/modules/log4j/src/main/java/org/apache/ignite/logger/log4j/Log4JLogger.java
+++ 
b/modules/log4j/src/main/java/org/apache/ignite/logger/log4j/Log4JLogger.java
@@ -342,6 +342,10 @@ public class Log4JLogger implements IgniteLogger, 
LoggerNodeIdAware, Log4jFileAw
 impl.setLevel(logLevel);
 }
 
+// If still don't have appenders, disable logging.
+if (!isConfigured())
+impl.setLevel(Level.OFF);
+
 quiet0 = quiet;
 inited = true;
 }



[41/50] incubator-ignite git commit: Merge remote-tracking branch 'remotes/origin/ignite-1.3.3-p2'

2015-08-19 Thread vozerov
Merge remote-tracking branch 'remotes/origin/ignite-1.3.3-p2'

Conflicts:
examples/pom.xml
modules/aop/pom.xml
modules/apache-license-gen/pom.xml
modules/aws/pom.xml
modules/clients/pom.xml
modules/cloud/pom.xml
modules/codegen/pom.xml
modules/core/pom.xml

modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
modules/core/src/main/resources/ignite.properties

modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheDhtLocalPartitionAfterRemoveSelfTest.java

modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/IgniteCachePutRetryAbstractSelfTest.java
modules/extdata/p2p/pom.xml
modules/extdata/uri/modules/uri-dependency/pom.xml
modules/extdata/uri/pom.xml
modules/gce/pom.xml
modules/geospatial/pom.xml
modules/hadoop/pom.xml
modules/hibernate/pom.xml
modules/indexing/pom.xml
modules/jcl/pom.xml
modules/jta/pom.xml
modules/kafka/pom.xml
modules/log4j/pom.xml
modules/mesos/pom.xml
modules/rest-http/pom.xml
modules/scalar-2.10/pom.xml
modules/scalar/pom.xml
modules/schedule/pom.xml
modules/schema-import/pom.xml
modules/slf4j/pom.xml
modules/spark-2.10/pom.xml
modules/spark/pom.xml
modules/spring/pom.xml
modules/ssh/pom.xml
modules/tools/pom.xml
modules/urideploy/pom.xml
modules/visor-console-2.10/pom.xml
modules/visor-console/pom.xml
modules/visor-plugins/pom.xml
modules/web/pom.xml
modules/yardstick/pom.xml
modules/yarn/pom.xml
pom.xml

Merge remote-tracking branch 'remotes/origin/ignite-1.3.3-p2'

Conflicts:
benchmarks/cache-comparison/pom.xml
benchmarks/filesystem/hadoop1/pom.xml
benchmarks/filesystem/hadoop2/pom.xml
benchmarks/mongo/pom.xml
benchmarks/risk-analytics/pom.xml
benchmarks/serialization/pom.xml

benchmarks/yardstick/src/main/dotnet/gridgain-benchmarks/Properties/AssemblyInfo.cs
examples/clients/cpp/configure.ac

examples/clients/dotnet/GridGainExamples/GridGainExamples/Properties/AssemblyInfo.cs

examples/clients/dotnet/GridGainExamples/GridGainExamplesDll/Properties/AssemblyInfo.cs
examples/pom.xml
modules/clients/common/configure.ac
modules/clients/common/project/vs/Resource.rc
modules/clients/cpp/_old/main/configure.ac
modules/clients/cpp/_old/main/tests/configure.ac
modules/clients/cpp/_old/vsproject/resource.h
modules/clients/cpp/core-test/configure.ac
modules/clients/cpp/core-test/project/vs/Resource.rc
modules/clients/cpp/core/configure.ac
modules/clients/cpp/core/project/vs/Resource.rc
modules/clients/dotnet/gridgain-codegen/Properties/AssemblyInfo.cs
modules/clients/dotnet/gridgain-exe/Properties/AssemblyInfo.cs
modules/clients/dotnet/gridgain/Properties/AssemblyInfo.cs
modules/clients/pom.xml

modules/clients/src/test/dotnet/gridgain-examples-test/Properties/AssemblyInfo.cs

modules/clients/src/test/dotnet/gridgain-test-compatibility/Properties/AssemblyInfo.cs

modules/clients/src/test/dotnet/gridgain-test-dll/Properties/AssemblyInfo.cs

modules/clients/src/test/dotnet/gridgain-test-runner/Properties/AssemblyInfo.cs
modules/clients/src/test/dotnet/gridgain-test/Properties/AssemblyInfo.cs
modules/codegen/pom.xml

modules/compatibility/gg-versions/7.3.3/src/main/java/org/gridgain/grid/compatibility/GridCompatibilityTestsRunner.java
modules/compatibility/pom.xml
modules/core/pom.xml
modules/core/src/main/resources/gridgain.properties
modules/diagnostic/pom.xml
modules/dr-demo/pom.xml
modules/license-gen/pom.xml
modules/mongo-sniffer/pom.xml
modules/mongo-visor/pom.xml
modules/mongo/pom.xml
modules/tools/pom.xml
modules/visor-console/pom.xml
modules/visor-demo/pom.xml
modules/visor-tester-plugin/pom.xml
modules/visor-tester/pom.xml
modules/visor/pom.xml
modules/yardstick/dotnet/Properties/AssemblyInfo.cs
modules/yardstick/pom.xml
parent/pom.xml
pilots/chronotrack/pom.xml
pilots/ctb/pom.xml
pilots/dsi/pom.xml
pilots/ionic/pom.xml
pilots/sb/pom.xml
pilots/sony/pom.xml
pilots/wellsfargo/pom.xml
pilots/worldpay/pom.xml
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/1f00c707
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/1f00c707
Diff: http://git-wip-us.apache.org/repos/asf/incubat

[46/50] incubator-ignite git commit: master - index sort fix for merge tables

2015-08-19 Thread vozerov
master - index sort fix for merge tables


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 9c939bec1bfa2c3396051c155ffb06775a329aad
Parents: 952c7fc
Author: S.Vladykin 
Authored: Mon Aug 17 21:23:26 2015 +0300
Committer: S.Vladykin 
Committed: Mon Aug 17 21:23:26 2015 +0300

--
 .../internal/processors/query/h2/twostep/GridMergeTable.java  | 7 +--
 1 file changed, 1 insertion(+), 6 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/9c939bec/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMergeTable.java
--
diff --git 
a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMergeTable.java
 
b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMergeTable.java
index 0b335d3..7d2235d 100644
--- 
a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMergeTable.java
+++ 
b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMergeTable.java
@@ -35,9 +35,6 @@ public class GridMergeTable extends TableBase {
 private final GridKernalContext ctx;
 
 /** */
-private final ArrayList idxs = new ArrayList<>(1);
-
-/** */
 private final GridMergeIndex idx;
 
 /**
@@ -49,8 +46,6 @@ public class GridMergeTable extends TableBase {
 
 this.ctx = ctx;
 idx = new GridMergeIndexUnsorted(this, "merge_scan");
-
-idxs.add(idx);
 }
 
 /**
@@ -124,7 +119,7 @@ public class GridMergeTable extends TableBase {
 
 /** {@inheritDoc} */
 @Override public ArrayList getIndexes() {
-return idxs;
+return null;
 }
 
 /** {@inheritDoc} */



[08/50] incubator-ignite git commit: Merge remote-tracking branch 'remotes/origin/master' into ignite-946

2015-08-19 Thread vozerov
Merge remote-tracking branch 'remotes/origin/master' into ignite-946


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 92e81dca00800b1b74f0ade328121aaf0ab1d4df
Parents: 2e7799d d9acbd1
Author: Denis Magda 
Authored: Mon Aug 10 09:57:31 2015 +0300
Committer: Denis Magda 
Committed: Mon Aug 10 09:57:31 2015 +0300

--
 assembly/release-hadoop.xml |   5 +
 .../ClientAbstractMultiNodeSelfTest.java|   4 +-
 .../JettyRestProcessorAbstractSelfTest.java |  14 +-
 .../apache/ignite/IgniteSystemProperties.java   |   2 +-
 .../store/jdbc/CacheAbstractJdbcStore.java  |  21 +-
 .../apache/ignite/internal/IgniteKernal.java|   2 +-
 .../org/apache/ignite/internal/IgnitionEx.java  |  43 +-
 .../managers/communication/GridIoManager.java   | 188 +++-
 .../processors/cache/GridCacheMvccManager.java  |  73 +--
 .../processors/cache/GridCacheProcessor.java|  12 +-
 .../processors/cache/GridCacheProxyImpl.java|  42 +-
 .../processors/cache/GridCacheSwapManager.java  |   2 +-
 .../processors/cache/GridCacheUtils.java|   1 -
 .../GridDhtPartitionsExchangeFuture.java|  20 +-
 .../distributed/near/GridNearGetFuture.java |  20 +-
 .../cache/query/GridCacheSqlQuery.java  |  33 +-
 .../cache/query/GridCacheTwoStepQuery.java  |  34 +-
 .../handlers/query/QueryCommandHandler.java |   6 +-
 .../ignite/internal/util/GridLogThrottle.java   |  63 ++-
 .../ignite/internal/util/IgniteUtils.java   |  16 +
 .../util/nio/GridCommunicationClient.java   |   5 +-
 .../util/nio/GridNioFinishedFuture.java |  12 +
 .../ignite/internal/util/nio/GridNioFuture.java |  14 +
 .../internal/util/nio/GridNioFutureImpl.java|  15 +
 .../util/nio/GridNioRecoveryDescriptor.java |  13 +-
 .../ignite/internal/util/nio/GridNioServer.java |   5 +
 .../util/nio/GridNioSessionMetaKey.java |   5 +-
 .../util/nio/GridShmemCommunicationClient.java  |   7 +-
 .../util/nio/GridTcpNioCommunicationClient.java |  14 +-
 .../communication/tcp/TcpCommunicationSpi.java  |  84 +++-
 .../ignite/spi/discovery/tcp/ClientImpl.java|  29 +-
 .../ignite/spi/discovery/tcp/ServerImpl.java|  50 +-
 .../spi/discovery/tcp/TcpDiscoveryImpl.java |  15 +
 .../spi/discovery/tcp/TcpDiscoverySpi.java  |   7 +-
 .../TcpDiscoveryMulticastIpFinder.java  |   7 +-
 .../src/test/config/io-manager-benchmark.xml|   3 +-
 .../GridJobMasterLeaveAwareSelfTest.java|  10 +-
 .../IgniteClientReconnectAbstractTest.java  |   5 +-
 .../IgniteClientReconnectCacheTest.java |   5 +-
 .../GridDeploymentMessageCountSelfTest.java |   5 +-
 .../cache/CacheStopAndDestroySelfTest.java  |   8 +-
 .../GridCacheAtomicMessageCountSelfTest.java|   6 +-
 .../processors/cache/GridCacheMvccSelfTest.java |   1 -
 ...ridCacheReplicatedSynchronousCommitTest.java |   5 +-
 .../cache/GridCacheSwapPreloadSelfTest.java |   2 +
 .../IgniteCacheAbstractStopBusySelfTest.java|   6 +-
 .../cache/IgniteCacheNearLockValueSelfTest.java |   6 +-
 ...eDynamicCacheStartNoExchangeTimeoutTest.java |   4 +-
 .../cache/IgniteTxReentryAbstractSelfTest.java  |   5 +-
 ...niteCacheClientNodeChangingTopologyTest.java |   6 +-
 ...teCacheClientNodePartitionsExchangeTest.java |   4 +-
 .../IgniteCacheNearOffheapGetSelfTest.java  | 131 ++
 ...xOriginatingNodeFailureAbstractSelfTest.java |   6 +-
 ...cOriginatingNodeFailureAbstractSelfTest.java |   6 +-
 .../GridCacheDhtPreloadMessageCountTest.java|   5 +-
 ...ePrimaryNodeFailureRecoveryAbstractTest.java |   6 +-
 ...eAtomicInvalidPartitionHandlingSelfTest.java |   5 +-
 .../near/IgniteCacheNearTxRollbackTest.java |   6 +-
 .../GridCacheReplicatedInvalidateSelfTest.java  |   6 +-
 ...CommunicationRecoveryAckClosureSelfTest.java | 464 +++
 .../tcp/TcpDiscoveryMultiThreadedTest.java  |   8 +-
 .../testsuites/IgniteCacheTestSuite2.java   |   1 +
 .../IgniteSpiCommunicationSelfTestSuite.java|   1 +
 .../ignite/util/TestTcpCommunicationSpi.java|   6 +-
 .../processors/query/h2/IgniteH2Indexing.java   |  27 +-
 .../processors/query/h2/sql/GridSqlElement.java |  18 +-
 .../query/h2/sql/GridSqlFunction.java   |  17 +-
 .../processors/query/h2/sql/GridSqlQuery.java   |   4 +-
 .../query/h2/sql/GridSqlQueryParser.java|  94 ++--
 .../query/h2/sql/GridSqlQuerySplitter.java  | 117 +++--
 .../processors/query/h2/sql/GridSqlSelect.java  |  76 +--
 .../processors/query/h2/sql/GridSqlType.java|  24 +-
 .../processors/query/h2/sql/GridSqlUnion.java   |   2 +-
 .../query/h2/twostep/GridMapQueryExecutor.java  |   7 +

[28/50] incubator-ignite git commit: Fixed threads cleanup in continuous processor

2015-08-19 Thread vozerov
Fixed threads cleanup in continuous 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/8ecddcc2
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/8ecddcc2
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/8ecddcc2

Branch: refs/heads/ignite-gg-9615-1
Commit: 8ecddcc2dcb064b759486d43a4f09173f268b3cf
Parents: 260238e
Author: Valentin Kulichenko 
Authored: Thu Aug 13 16:25:09 2015 -0700
Committer: Valentin Kulichenko 
Committed: Thu Aug 13 16:25:09 2015 -0700

--
 .../internal/processors/continuous/GridEventConsumeSelfTest.java | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8ecddcc2/modules/core/src/test/java/org/apache/ignite/internal/processors/continuous/GridEventConsumeSelfTest.java
--
diff --git 
a/modules/core/src/test/java/org/apache/ignite/internal/processors/continuous/GridEventConsumeSelfTest.java
 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/continuous/GridEventConsumeSelfTest.java
index 5ce2efd..7ab858b 100644
--- 
a/modules/core/src/test/java/org/apache/ignite/internal/processors/continuous/GridEventConsumeSelfTest.java
+++ 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/continuous/GridEventConsumeSelfTest.java
@@ -26,7 +26,6 @@ import org.apache.ignite.internal.util.*;
 import org.apache.ignite.internal.util.typedef.*;
 import org.apache.ignite.internal.util.typedef.internal.*;
 import org.apache.ignite.lang.*;
-import org.apache.ignite.marshaller.optimized.*;
 import org.apache.ignite.resources.*;
 import org.apache.ignite.spi.discovery.tcp.*;
 import org.apache.ignite.spi.discovery.tcp.ipfinder.*;
@@ -125,6 +124,7 @@ public class GridEventConsumeSelfTest extends 
GridCommonAbstractTest {
 assertEquals(0, U.field(proc, "rmtInfos").size());
 assertEquals(0, U.field(proc, "startFuts").size());
 assertEquals(0, U.field(proc, "stopFuts").size());
+assertEquals(0, U.field(proc, "bufCheckThreads").size());
 }
 }
 finally {
@@ -754,7 +754,7 @@ public class GridEventConsumeSelfTest extends 
GridCommonAbstractTest {
  */
 public void testNodeJoinWithP2P() throws Exception {
 fail("https://issues.apache.org/jira/browse/IGNITE-585";);
-
+
 final Collection nodeIds = new HashSet<>();
 final AtomicInteger cnt = new AtomicInteger();
 final CountDownLatch latch = new CountDownLatch(GRID_CNT + 1);



[44/50] incubator-ignite git commit: Merge branch 'ignite-1241-dev' of https://github.com/dmagda/incubator-ignite

2015-08-19 Thread vozerov
Merge branch 'ignite-1241-dev' of https://github.com/dmagda/incubator-ignite


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

Branch: refs/heads/ignite-gg-9615-1
Commit: ad121478b6f6d0d733e8d651a541f03b4fb849f4
Parents: 45c813a 38070b2
Author: Denis Magda 
Authored: Mon Aug 17 17:11:54 2015 +0300
Committer: Yakov Zhdanov 
Committed: Mon Aug 17 17:11:54 2015 +0300

--
 .../ignite/spi/discovery/tcp/ServerImpl.java| 26 ++--
 .../spi/discovery/tcp/TcpDiscoveryImpl.java |  4 +--
 .../spi/discovery/tcp/TcpDiscoverySpi.java  |  4 ---
 .../tcp/internal/TcpDiscoveryNode.java  | 18 +++---
 .../tcp/internal/TcpDiscoveryNodesRing.java | 23 +
 5 files changed, 53 insertions(+), 22 deletions(-)
--


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

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



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

2015-08-19 Thread vozerov
review


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

Branch: refs/heads/ignite-gg-9615-1
Commit: fe2be79c8e4eccf8f823abeb32521f0fca8ddf42
Parents: b2e6734
Author: Yakov Zhdanov 
Authored: Tue Aug 4 17:49:48 2015 +0300
Committer: Yakov Zhdanov 
Committed: Tue Aug 4 17:49:48 2015 +0300

--
 .../ignite/cache/version/package-info.java  |  4 ++--
 .../processors/cache/CacheInvokeEntry.java  |  5 +++--
 .../cache/transactions/IgniteTxEntry.java   |  4 +++-
 .../transactions/IgniteTxLocalAdapter.java  | 20 ++--
 4 files changed, 18 insertions(+), 15 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/fe2be79c/modules/core/src/main/java/org/apache/ignite/cache/version/package-info.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/cache/version/package-info.java 
b/modules/core/src/main/java/org/apache/ignite/cache/version/package-info.java
index 9aeaba2..50ceb13 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/cache/version/package-info.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/cache/version/package-info.java
@@ -16,6 +16,6 @@
  */
 
 /**
- * Contains cache version based implementations.
+ * Contains cache versioned entry interface.
  */
-package org.apache.ignite.cache.version;
\ No newline at end of file
+package org.apache.ignite.cache.version;

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/fe2be79c/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheInvokeEntry.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheInvokeEntry.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheInvokeEntry.java
index 2d8f738..515a4c5 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheInvokeEntry.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheInvokeEntry.java
@@ -49,14 +49,15 @@ public class CacheInvokeEntry extends 
CacheLazyEntry implements Muta
 public CacheInvokeEntry(GridCacheContext cctx,
 KeyCacheObject keyObj,
 @Nullable CacheObject valObj,
-GridCacheVersion ver) {
+GridCacheVersion ver
+) {
 super(cctx, keyObj, valObj);
 
 this.hadVal = valObj != null;
 this.ver = ver;
 }
 
-/** 
+/**
  * @param ctx Cache context.
  * @param keyObj Key cache object.
  * @param key Key value.

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/fe2be79c/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxEntry.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxEntry.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxEntry.java
index ed57bf2..73b9975 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxEntry.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxEntry.java
@@ -577,6 +577,8 @@ public class IgniteTxEntry implements GridPeerDeployAware, 
Message {
 ver = entry.version();
 }
 catch (GridCacheEntryRemovedException e) {
+assert tx.optimistic() : tx;
+
 ver = null;
 }
 
@@ -924,7 +926,7 @@ public class IgniteTxEntry implements GridPeerDeployAware, 
Message {
 return false;
 
 reader.incrementState();
-
+
 case 6:
 flags = reader.readByte("flags");
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/fe2be79c/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 7f171c2..e03f34d 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/Igni

[02/50] incubator-ignite git commit: IGNITE-946 Added test to Suite.

2015-08-19 Thread vozerov
IGNITE-946 Added test to Suite.


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

Branch: refs/heads/ignite-gg-9615-1
Commit: f0fe0769751b7957a64fc5dd56989e54f1223ab1
Parents: 26144dc
Author: nikolay_tikhonov 
Authored: Fri Jul 31 13:00:09 2015 +0300
Committer: nikolay_tikhonov 
Committed: Fri Jul 31 15:49:13 2015 +0300

--
 .../java/org/apache/ignite/testsuites/IgniteCacheTestSuite4.java   | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/f0fe0769/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 3ac7879..228be92 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
@@ -164,7 +164,7 @@ public class IgniteCacheTestSuite4 extends TestSuite {
 suite.addTestSuite(CacheVersionedEntryReplicatedAtomicSelfTest.class);
 
suite.addTestSuite(CacheVersionedEntryReplicatedTransactionalSelfTest.class);
 
suite.addTestSuite(CacheVersionedEntryReplicatedAtomicOffHeapSelfTest.class);
-
suite.addTestSuite(CacheVersionedEntryPartitionedTransactionalOffHeapSelfTest.class);
+
suite.addTestSuite(CacheVersionedEntryReplicatedTransactionalOffHeapSelfTest.class);
 
 return suite;
 }



[05/50] incubator-ignite git commit: Merge branches 'ignite-946' and 'master' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-946

2015-08-19 Thread vozerov
Merge branches 'ignite-946' and 'master' of 
https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-946


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

Branch: refs/heads/ignite-gg-9615-1
Commit: b2e6734c76f17247a2801e63547e5edcc33f770c
Parents: 2e7799d b056a73
Author: Yakov Zhdanov 
Authored: Tue Aug 4 16:34:17 2015 +0300
Committer: Yakov Zhdanov 
Committed: Tue Aug 4 16:34:17 2015 +0300

--
 .../ClientAbstractMultiNodeSelfTest.java|   4 +-
 .../JettyRestProcessorAbstractSelfTest.java |  14 +-
 .../apache/ignite/IgniteSystemProperties.java   |   2 +-
 .../store/jdbc/CacheAbstractJdbcStore.java  |  21 +-
 .../apache/ignite/internal/IgniteKernal.java|   2 +-
 .../org/apache/ignite/internal/IgnitionEx.java  |  43 +-
 .../managers/communication/GridIoManager.java   | 188 +++-
 .../processors/cache/GridCacheMvccManager.java  |  73 +--
 .../processors/cache/GridCacheProcessor.java|   2 +-
 .../processors/cache/GridCacheProxyImpl.java|  42 +-
 .../processors/cache/GridCacheSwapManager.java  |   2 +-
 .../GridDhtPartitionsExchangeFuture.java|  20 +-
 .../distributed/near/GridNearGetFuture.java |  20 +-
 .../handlers/query/QueryCommandHandler.java |   6 +-
 .../ignite/internal/util/IgniteUtils.java   |  16 +
 .../util/nio/GridCommunicationClient.java   |   5 +-
 .../util/nio/GridNioFinishedFuture.java |  12 +
 .../ignite/internal/util/nio/GridNioFuture.java |  14 +
 .../internal/util/nio/GridNioFutureImpl.java|  15 +
 .../util/nio/GridNioRecoveryDescriptor.java |  13 +-
 .../ignite/internal/util/nio/GridNioServer.java |   5 +
 .../util/nio/GridNioSessionMetaKey.java |   5 +-
 .../util/nio/GridShmemCommunicationClient.java  |   7 +-
 .../util/nio/GridTcpNioCommunicationClient.java |  14 +-
 .../communication/tcp/TcpCommunicationSpi.java  |  84 +++-
 .../ignite/spi/discovery/tcp/ClientImpl.java|   2 +-
 .../ignite/spi/discovery/tcp/ServerImpl.java|  45 +-
 .../spi/discovery/tcp/TcpDiscoverySpi.java  |   2 +-
 .../src/test/config/io-manager-benchmark.xml|   3 +-
 .../GridJobMasterLeaveAwareSelfTest.java|  10 +-
 .../IgniteClientReconnectAbstractTest.java  |   5 +-
 .../IgniteClientReconnectCacheTest.java |   5 +-
 .../GridDeploymentMessageCountSelfTest.java |   5 +-
 .../cache/CacheStopAndDestroySelfTest.java  |   8 +-
 .../GridCacheAtomicMessageCountSelfTest.java|   6 +-
 .../processors/cache/GridCacheMvccSelfTest.java |   1 -
 ...ridCacheReplicatedSynchronousCommitTest.java |   5 +-
 .../IgniteCacheAbstractStopBusySelfTest.java|   6 +-
 .../cache/IgniteCacheNearLockValueSelfTest.java |   6 +-
 ...eDynamicCacheStartNoExchangeTimeoutTest.java |   4 +-
 .../cache/IgniteTxReentryAbstractSelfTest.java  |   5 +-
 ...niteCacheClientNodeChangingTopologyTest.java |   6 +-
 ...teCacheClientNodePartitionsExchangeTest.java |   4 +-
 .../IgniteCacheNearOffheapGetSelfTest.java  | 131 ++
 ...xOriginatingNodeFailureAbstractSelfTest.java |   6 +-
 ...cOriginatingNodeFailureAbstractSelfTest.java |   6 +-
 .../GridCacheDhtPreloadMessageCountTest.java|   5 +-
 ...ePrimaryNodeFailureRecoveryAbstractTest.java |   6 +-
 ...eAtomicInvalidPartitionHandlingSelfTest.java |   5 +-
 .../near/IgniteCacheNearTxRollbackTest.java |   6 +-
 .../GridCacheReplicatedInvalidateSelfTest.java  |   6 +-
 ...CommunicationRecoveryAckClosureSelfTest.java | 464 +++
 .../tcp/TcpDiscoveryMultiThreadedTest.java  |   8 +-
 .../testsuites/IgniteCacheTestSuite2.java   |   1 +
 .../IgniteSpiCommunicationSelfTestSuite.java|   1 +
 .../ignite/util/TestTcpCommunicationSpi.java|   6 +-
 ...CacheScanPartitionQueryFallbackSelfTest.java |  15 +-
 .../http/jetty/GridJettyRestHandler.java|  12 +-
 .../parser/dialect/OracleMetadataDialect.java   |   4 +-
 .../src/test/java/config/ignite-test-config.xml |  43 ++
 .../ignite/internal/GridFactorySelfTest.java|   9 +
 .../visor/commands/kill/VisorKillCommand.scala  |   2 +-
 62 files changed, 1241 insertions(+), 252 deletions(-)
--


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



[04/50] incubator-ignite git commit: ignite-946: fixing version retrieval for transactions

2015-08-19 Thread vozerov
ignite-946: fixing version retrieval for transactions


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 2e7799d446653bba379cc231628ba2b02c993e5e
Parents: f0fe076
Author: Denis Magda 
Authored: Fri Jul 31 15:32:45 2015 +0300
Committer: nikolay_tikhonov 
Committed: Fri Jul 31 15:49:14 2015 +0300

--
 .../processors/cache/CacheInvokeEntry.java  |  2 +-
 .../processors/cache/GridCacheMapEntry.java |  4 +-
 .../cache/transactions/IgniteTxAdapter.java | 14 ++-
 .../cache/transactions/IgniteTxEntry.java   | 11 ++-
 .../transactions/IgniteTxLocalAdapter.java  | 90 
 5 files changed, 98 insertions(+), 23 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/2e7799d4/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheInvokeEntry.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheInvokeEntry.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheInvokeEntry.java
index e6f8d4e..2d8f738 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheInvokeEntry.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheInvokeEntry.java
@@ -121,7 +121,7 @@ public class CacheInvokeEntry extends 
CacheLazyEntry implements Muta
 /** {@inheritDoc} */
 @SuppressWarnings("unchecked")
 @Override public  T unwrap(Class cls) {
-if (cls.isAssignableFrom(VersionedEntry.class))
+if (cls.isAssignableFrom(VersionedEntry.class) && ver != null)
 return (T)new CacheVersionedEntryImpl<>(getKey(), getValue(), ver);
 
 return super.unwrap(cls);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/2e7799d4/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
index ebcb908..43cf2fe 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
@@ -1653,7 +1653,7 @@ public abstract class GridCacheMapEntry extends 
GridMetadataAwareAdapter impleme
 
 oldVal = rawGetOrUnmarshalUnlocked(true);
 
-CacheInvokeEntry entry = new 
CacheInvokeEntry(cctx, key, oldVal, this.ver);
+CacheInvokeEntry entry = new 
CacheInvokeEntry(cctx, key, oldVal, version());
 
 try {
 Object computed = entryProcessor.process(entry, 
invokeArgs);
@@ -1878,7 +1878,7 @@ public abstract class GridCacheMapEntry extends 
GridMetadataAwareAdapter impleme
 
 EntryProcessor entryProcessor = 
(EntryProcessor)writeObj;
 
-CacheInvokeEntry entry = new 
CacheInvokeEntry(cctx, key, oldVal, this.ver);
+CacheInvokeEntry entry = new 
CacheInvokeEntry(cctx, key, oldVal, version());
 
 try {
 Object computed = entryProcessor.process(entry, 
invokeArgs);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/2e7799d4/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxAdapter.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxAdapter.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxAdapter.java
index 0d14012..797f75e 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxAdapter.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/transactions/IgniteTxAdapter.java
@@ -1228,9 +1228,21 @@ public abstract class IgniteTxAdapter extends 
GridMetadataAwareAdapter
 
 Object key = null;
 
+GridCacheVersion ver;
+
+try {
+ver = txEntry.cached().version();
+}
+catch (GridCacheEntryRemovedException e) {
+if (log.isDebugEnabled())
+  

[13/50] incubator-ignite git commit: ignite-946: simplified VersionedEntry interface

2015-08-19 Thread vozerov
ignite-946: simplified VersionedEntry interface


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

Branch: refs/heads/ignite-gg-9615-1
Commit: b6bef13eef82d9a2e040c01881d07c186ade372e
Parents: dd3cecf
Author: Denis Magda 
Authored: Tue Aug 11 10:17:24 2015 +0300
Committer: Denis Magda 
Committed: Tue Aug 11 10:17:24 2015 +0300

--
 .../ignite/cache/version/VersionedEntry.java| 83 +---
 .../cache/version/CacheVersionedEntryImpl.java  | 23 +-
 .../cache/version/GridCacheVersionManager.java  |  4 +-
 .../CacheVersionedEntryAbstractTest.java|  9 +--
 4 files changed, 45 insertions(+), 74 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/b6bef13e/modules/core/src/main/java/org/apache/ignite/cache/version/VersionedEntry.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/cache/version/VersionedEntry.java
 
b/modules/core/src/main/java/org/apache/ignite/cache/version/VersionedEntry.java
index 1aac68a..135d681 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/cache/version/VersionedEntry.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/cache/version/VersionedEntry.java
@@ -24,7 +24,7 @@ import javax.cache.processor.*;
 import java.util.*;
 
 /**
- * Cache entry that stores entry's version related information.
+ * Cache entry that stores entry's version related information along with its 
data.
  *
  * To get a {@code VersionedEntry} of an {@link Cache.Entry} use {@link 
Cache.Entry#unwrap(Class)} by passing
  * {@code VersionedEntry} class to it as the argument.
@@ -42,62 +42,51 @@ import java.util.*;
  * is excluded from responses.
  * Java Example
  * 
- * Cache cache = grid(0).cache(null);
+ * IgniteCache cache = grid(0).cache(null);
  *
- *  cache.invoke(100, new EntryProcessor() {
- *  public Object process(MutableEntry entry, Object... 
arguments) throws EntryProcessorException {
- *  VersionedEntry verEntry = 
entry.unwrap(VersionedEntry.class);
- *  return entry;
- *   }
- *   });
+ * VersionedEntry entry1 = cache.invoke(100,
+ * new EntryProcessor>() {
+ *  public VersionedEntry 
process(MutableEntry entry,
+ *  Object... arguments) throws EntryProcessorException {
+ *  return entry.unwrap(VersionedEntry.class);
+ *  }
+ * });
+ *
+ * // Cache entry for the given key may be updated at some point later.
+ *
+ * VersionedEntry entry2 = cache.invoke(100,
+ * new EntryProcessor>() {
+ *  public VersionedEntry 
process(MutableEntry entry,
+ *  Object... arguments) throws EntryProcessorException {
+ *  return entry.unwrap(VersionedEntry.class);
+ *  }
+ * });
+ *
+ * if (entry1.version().compareTo(entry2.version()) < 0) {
+ * // the entry has been updated
+ * }
  * 
  */
 public interface VersionedEntry extends Cache.Entry {
 /**
- * Versions comparator.
- */
-public static final Comparator VER_COMP = new 
Comparator() {
-@Override public int compare(VersionedEntry o1, VersionedEntry o2) {
-int res = Integer.compare(o1.topologyVersion(), 
o2.topologyVersion());
-
-if (res != 0)
-return res;
-
-res = Long.compare(o1.order(), o2.order());
-
-if (res != 0)
-return res;
-
-return Integer.compare(o1.nodeOrder(), o2.nodeOrder());
-}
-};
-
-/**
- * Gets the topology version at the time when the entry with a given pair 
of key and value has been created.
- *
- * @return Topology version plus number of seconds from the start time of 
the first grid node.
- */
-public int topologyVersion();
-
-/**
- * Gets versioned entry unique order.
- * Each time a cache entry for a given key is updated a new {@code 
VersionedEntry} with increased order is created.
- *
- * @return Versioned entry unique order.
- */
-public long order();
-
-/**
- * Gets local node order at the time when the entry with a given pair of 
key and value has been created.
+ * Returns a comparable object representing the version of this cache 
entry.
+ * 
+ * It is valid to compare cache entries' versions for the same key. In 
this case the latter update will be
+ * represented by a higher version. The result of versions comparison of 
cache entries of different keys is
+ * undefined.
  *
- * @return Local node order on which this version has been assigned.
+ * @return Vers

[30/50] incubator-ignite git commit: 1.3.3-p2-SNAPSHOT

2015-08-19 Thread vozerov
1.3.3-p2-SNAPSHOT


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 9300bbc776191218fb687339ba72675f3fe45848
Parents: 51dcd51
Author: Ignite Teamcity 
Authored: Fri Aug 14 11:34:47 2015 +0300
Committer: Ignite Teamcity 
Committed: Fri Aug 14 11:34:47 2015 +0300

--
 examples/pom.xml   | 2 +-
 modules/aop/pom.xml| 2 +-
 modules/apache-license-gen/pom.xml | 2 +-
 modules/aws/pom.xml| 2 +-
 modules/clients/pom.xml| 2 +-
 modules/cloud/pom.xml  | 2 +-
 modules/codegen/pom.xml| 2 +-
 modules/core/pom.xml   | 2 +-
 modules/core/src/main/resources/ignite.properties  | 2 +-
 modules/extdata/p2p/pom.xml| 2 +-
 modules/extdata/uri/modules/uri-dependency/pom.xml | 2 +-
 modules/extdata/uri/pom.xml| 2 +-
 modules/gce/pom.xml| 2 +-
 modules/geospatial/pom.xml | 2 +-
 modules/hadoop/pom.xml | 2 +-
 modules/hibernate/pom.xml  | 2 +-
 modules/indexing/pom.xml   | 2 +-
 modules/jcl/pom.xml| 2 +-
 modules/jta/pom.xml| 2 +-
 modules/kafka/pom.xml  | 2 +-
 modules/log4j/pom.xml  | 2 +-
 modules/mesos/pom.xml  | 2 +-
 modules/rest-http/pom.xml  | 2 +-
 modules/scalar-2.10/pom.xml| 2 +-
 modules/scalar/pom.xml | 2 +-
 modules/schedule/pom.xml   | 2 +-
 modules/schema-import/pom.xml  | 2 +-
 modules/slf4j/pom.xml  | 2 +-
 modules/spark-2.10/pom.xml | 2 +-
 modules/spark/pom.xml  | 2 +-
 modules/spring/pom.xml | 2 +-
 modules/ssh/pom.xml| 2 +-
 modules/tools/pom.xml  | 2 +-
 modules/urideploy/pom.xml  | 2 +-
 modules/visor-console-2.10/pom.xml | 2 +-
 modules/visor-console/pom.xml  | 2 +-
 modules/visor-plugins/pom.xml  | 2 +-
 modules/web/pom.xml| 2 +-
 modules/yardstick/pom.xml  | 2 +-
 modules/yarn/pom.xml   | 2 +-
 pom.xml| 2 +-
 41 files changed, 41 insertions(+), 41 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/9300bbc7/examples/pom.xml
--
diff --git a/examples/pom.xml b/examples/pom.xml
index 014cb0a..043689c 100644
--- a/examples/pom.xml
+++ b/examples/pom.xml
@@ -28,7 +28,7 @@
 
 
 ignite-examples
-1.3.3-p1-SNAPSHOT
+1.3.3-p2-SNAPSHOT
 
 
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/9300bbc7/modules/aop/pom.xml
--
diff --git a/modules/aop/pom.xml b/modules/aop/pom.xml
index 1983567..8a271e5 100644
--- a/modules/aop/pom.xml
+++ b/modules/aop/pom.xml
@@ -31,7 +31,7 @@
 
 
 ignite-aop
-1.3.3-p1-SNAPSHOT
+1.3.3-p2-SNAPSHOT
 
 
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/9300bbc7/modules/apache-license-gen/pom.xml
--
diff --git a/modules/apache-license-gen/pom.xml 
b/modules/apache-license-gen/pom.xml
index c723729..e1066c1 100644
--- a/modules/apache-license-gen/pom.xml
+++ b/modules/apache-license-gen/pom.xml
@@ -31,5 +31,5 @@
 
 org.apache.ignite
 ignite-apache-license-gen
-1.3.3-p1-SNAPSHOT
+1.3.3-p2-SNAPSHOT
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/9300bbc7/modules/aws/pom.xml
--
diff --git a/modules/aws/pom.xml b/modules/aws/pom.xml
index 1f92999..e5cf518 100644
--- a/modules/aws/pom.xml
+++ b/modules/aws/pom.xml
@@ -31,7 +31,7 @@
 
 
 ignite-aws
-1.3.3-p1-SNAPSHOT
+1.3.3-p2-SNAPSHOT
 
 
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/9300bbc7/modules/clients/pom.xml
-

[45/50] incubator-ignite git commit: master - schema drop fix for TL tables

2015-08-19 Thread vozerov
master - schema drop fix for TL tables


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 952c7fc99d63b5af0d5a3fe7df4b610f8baf9001
Parents: ad12147
Author: S.Vladykin 
Authored: Mon Aug 17 21:22:50 2015 +0300
Committer: S.Vladykin 
Committed: Mon Aug 17 21:22:50 2015 +0300

--
 .../query/h2/twostep/GridThreadLocalTable.java  | 22 +---
 1 file changed, 15 insertions(+), 7 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/952c7fc9/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridThreadLocalTable.java
--
diff --git 
a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridThreadLocalTable.java
 
b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridThreadLocalTable.java
index c468371..f6735b5 100644
--- 
a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridThreadLocalTable.java
+++ 
b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridThreadLocalTable.java
@@ -21,6 +21,7 @@ import org.h2.api.*;
 import org.h2.command.ddl.*;
 import org.h2.engine.*;
 import org.h2.index.*;
+import org.h2.message.*;
 import org.h2.result.*;
 import org.h2.schema.*;
 import org.h2.table.*;
@@ -154,7 +155,7 @@ public class GridThreadLocalTable extends Table {
 
 /** {@inheritDoc} */
 @Override public String getTableType() {
-return tbl.get().getTableType();
+return EXTERNAL_TABLE_ENGINE;
 }
 
 /** {@inheritDoc} */
@@ -179,7 +180,7 @@ public class GridThreadLocalTable extends Table {
 
 /** {@inheritDoc} */
 @Override public long getMaxDataModificationId() {
-return tbl.get().getMaxDataModificationId();
+return 0;
 }
 
 /** {@inheritDoc} */
@@ -194,7 +195,7 @@ public class GridThreadLocalTable extends Table {
 
 /** {@inheritDoc} */
 @Override public boolean canDrop() {
-return tbl.get().canDrop();
+return false;
 }
 
 /** {@inheritDoc} */
@@ -204,12 +205,14 @@ public class GridThreadLocalTable extends Table {
 
 /** {@inheritDoc} */
 @Override public long getRowCountApproximation() {
-return tbl.get().getRowCountApproximation();
+Table t = tbl.get();
+
+return t == null ? 0 : t.getRowCountApproximation();
 }
 
 /** {@inheritDoc} */
 @Override public long getDiskSpaceUsed() {
-return tbl.get().getDiskSpaceUsed();
+return 0;
 }
 
 /** {@inheritDoc} */
@@ -219,12 +222,17 @@ public class GridThreadLocalTable extends Table {
 
 /** {@inheritDoc} */
 @Override public String getDropSQL() {
-return tbl.get().getDropSQL();
+return "";
+}
+
+/** {@inheritDoc} */
+@Override public void addDependencies(HashSet dependencies) {
+// No-op. We should not have any dependencies to add.
 }
 
 /** {@inheritDoc} */
 @Override public void checkRename() {
-tbl.get().checkRename();
+throw DbException.getUnsupportedException("rename");
 }
 
 /**



[26/50] incubator-ignite git commit: Fixed threads cleanup in continuous processor

2015-08-19 Thread vozerov
Fixed threads cleanup in continuous 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/ba3abcec
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/ba3abcec
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/ba3abcec

Branch: refs/heads/ignite-gg-9615-1
Commit: ba3abceca10a1745253a3c28e7a6fe6f5833d266
Parents: 6697b0c
Author: Valentin Kulichenko 
Authored: Thu Aug 13 15:50:39 2015 -0700
Committer: Valentin Kulichenko 
Committed: Thu Aug 13 15:50:39 2015 -0700

--
 .../continuous/GridContinuousProcessor.java | 16 +++-
 .../GridCacheContinuousQueryAbstractSelfTest.java   |  2 +-
 2 files changed, 12 insertions(+), 6 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/ba3abcec/modules/core/src/main/java/org/apache/ignite/internal/processors/continuous/GridContinuousProcessor.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/continuous/GridContinuousProcessor.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/continuous/GridContinuousProcessor.java
index 5f1c4bb..a360e35 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/continuous/GridContinuousProcessor.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/continuous/GridContinuousProcessor.java
@@ -29,7 +29,6 @@ import org.apache.ignite.internal.managers.eventstorage.*;
 import org.apache.ignite.internal.processors.*;
 import org.apache.ignite.internal.processors.cache.*;
 import org.apache.ignite.internal.processors.timeout.*;
-import org.apache.ignite.internal.util.*;
 import org.apache.ignite.internal.util.future.*;
 import org.apache.ignite.internal.util.tostring.*;
 import org.apache.ignite.internal.util.typedef.*;
@@ -72,7 +71,7 @@ public class GridContinuousProcessor extends 
GridProcessorAdapter {
 private final ConcurrentMap stopFuts = new 
ConcurrentHashMap8<>();
 
 /** Threads started by this processor. */
-private final Collection threads = new 
GridConcurrentHashSet<>();
+private final Map bufCheckThreads = new 
ConcurrentHashMap8<>();
 
 /** */
 private final ConcurrentMap syncMsgFuts 
= new ConcurrentHashMap8<>();
@@ -311,8 +310,10 @@ public class GridContinuousProcessor extends 
GridProcessorAdapter {
 
 ctx.io().removeMessageListener(TOPIC_CONTINUOUS);
 
-U.interrupt(threads);
-U.joinThreads(threads, log);
+for (IgniteThread thread : bufCheckThreads.values()) {
+U.interrupt(thread);
+U.join(thread);
+}
 
 if (log.isDebugEnabled())
 log.debug("Continuous processor stopped.");
@@ -915,7 +916,7 @@ public class GridContinuousProcessor extends 
GridProcessorAdapter {
 }
 });
 
-threads.add(checker);
+bufCheckThreads.put(routineId, checker);
 
 checker.start();
 }
@@ -947,6 +948,11 @@ public class GridContinuousProcessor extends 
GridProcessorAdapter {
 ctx.io().removeMessageListener(hnd.orderedTopic());
 
 hnd.unregister(routineId, ctx);
+
+IgniteThread checker = bufCheckThreads.remove(routineId);
+
+if (checker != null)
+checker.interrupt();
 }
 
 /**

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/ba3abcec/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/query/continuous/GridCacheContinuousQueryAbstractSelfTest.java
--
diff --git 
a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/query/continuous/GridCacheContinuousQueryAbstractSelfTest.java
 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/query/continuous/GridCacheContinuousQueryAbstractSelfTest.java
index 4681071..7b628b4 100644
--- 
a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/query/continuous/GridCacheContinuousQueryAbstractSelfTest.java
+++ 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/query/continuous/GridCacheContinuousQueryAbstractSelfTest.java
@@ -29,7 +29,6 @@ import org.apache.ignite.internal.processors.datastructures.*;
 import org.apache.ignite.internal.util.typedef.*;
 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.*;
@@ -177,6 +176,7 @@ public abstract class 
GridCacheContinuousQuery

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

2015-08-19 Thread vozerov
 # Fix TopologyVersionAwareJob


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

Branch: refs/heads/ignite-gg-9615-1
Commit: a3301b3511a742c7c2cc013a4e31a1a838482938
Parents: 51dcd51
Author: sboikov 
Authored: Fri Aug 14 11:27:29 2015 +0300
Committer: sboikov 
Committed: Fri Aug 14 11:37:47 2015 +0300

--
 .../processors/cache/GridCacheAdapter.java  |   9 +-
 .../IgniteCacheSizeFailoverTest.java| 115 +++
 .../IgniteCachePutRetryAbstractSelfTest.java|  19 ++-
 ...PutRetryAtomicPrimaryWriteOrderSelfTest.java |  32 ++
 .../tcp/IgniteCacheSslStartStopSelfTest.java|   1 +
 .../IgniteCacheFailoverTestSuite.java   |   3 +
 6 files changed, 175 insertions(+), 4 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/a3301b35/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
index 18f4004..47ede5b 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
@@ -5597,9 +5597,12 @@ public abstract class GridCacheAdapter implements 
IgniteInternalCache>() {
-@Override
-public void apply(IgniteInternalFuture t) {
-jobCtx.callcc();
+@Override public void apply(IgniteInternalFuture t) 
{
+
((IgniteKernal)ignite).context().closure().runLocalSafe(new Runnable() {
+@Override public void run() {
+jobCtx.callcc();
+}
+}, false);
 }
 });
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/a3301b35/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheSizeFailoverTest.java
--
diff --git 
a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheSizeFailoverTest.java
 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheSizeFailoverTest.java
new file mode 100644
index 000..a76d894
--- /dev/null
+++ 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheSizeFailoverTest.java
@@ -0,0 +1,115 @@
+/*
+ * 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 IgniteCacheSizeFailoverTest extends GridCommonAbstractTest {
+/** */
+private static TcpDiscoveryIpFinder ipFinder = new 
TcpDiscoveryVmIpFinder(true);
+
+/** {@inheritDoc} */
+@Override protected IgniteConfiguration getC

[35/50] incubator-ignite git commit: ignite-1241-dev: fixed endless "failure detection threshold" warnings for the case when there is only one server and client nodes in the topology

2015-08-19 Thread vozerov
ignite-1241-dev: fixed endless "failure detection threshold" warnings for the 
case when there is only one server and client nodes in the topology


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 38070b28bdda9e95b125f27706037c9916edeeb6
Parents: 7760847
Author: Denis Magda 
Authored: Fri Aug 14 16:20:18 2015 +0300
Committer: Denis Magda 
Committed: Fri Aug 14 16:20:18 2015 +0300

--
 .../ignite/spi/discovery/tcp/ServerImpl.java| 26 ++--
 .../spi/discovery/tcp/TcpDiscoveryImpl.java |  4 +--
 .../spi/discovery/tcp/TcpDiscoverySpi.java  |  4 ---
 .../tcp/internal/TcpDiscoveryNode.java  | 18 +++---
 .../tcp/internal/TcpDiscoveryNodesRing.java | 23 +
 5 files changed, 53 insertions(+), 22 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/38070b28/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 76144e3..c8c4c50 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
@@ -628,9 +628,9 @@ class ServerImpl extends TcpDiscoveryImpl {
 }
 
 /** {@inheritDoc} */
-@Override protected void onDataReceived() {
+@Override protected void onMessageExchanged() {
 if (spi.failureDetectionTimeoutEnabled() && locNode != null)
-locNode.lastDataReceivedTime(U.currentTimeMillis());
+locNode.lastExchangeTime(U.currentTimeMillis());
 }
 
 /**
@@ -1916,9 +1916,13 @@ class ServerImpl extends TcpDiscoveryImpl {
 if (spi.ensured(msg))
 msgHist.add(msg);
 
-if (msg.senderNodeId() != null && 
!msg.senderNodeId().equals(getLocalNodeId()))
-// Reset the flag.
+if (msg.senderNodeId() != null && 
!msg.senderNodeId().equals(getLocalNodeId())) {
+// Received a message from remote node.
+onMessageExchanged();
+
+// Reset the failure flag.
 failureThresholdReached = false;
+}
 
 spi.stats.onMessageProcessingFinished(msg);
 }
@@ -2278,6 +2282,8 @@ class ServerImpl extends TcpDiscoveryImpl {
 
 int res = spi.readReceipt(sock, 
timeoutHelper.nextTimeoutChunk(ackTimeout0));
 
+onMessageExchanged();
+
 if (log.isDebugEnabled())
 log.debug("Message has been sent to next 
node [msg=" + msg +
 ", next=" + next.id() +
@@ -4104,9 +4110,12 @@ class ServerImpl extends TcpDiscoveryImpl {
  * Check connection aliveness status.
  */
 private void checkConnection() {
+Boolean hasRemoteSrvNodes = null;
+
 if (spi.failureDetectionTimeoutEnabled() && 
!failureThresholdReached &&
-U.currentTimeMillis() - locNode.lastDataReceivedTime() >= 
connCheckThreshold &&
-ring.hasRemoteNodes() && spiStateCopy() == CONNECTED) {
+U.currentTimeMillis() - locNode.lastExchangeTime() >= 
connCheckThreshold &&
+spiStateCopy() == CONNECTED &&
+(hasRemoteSrvNodes = ring.hasRemoteServerNodes())) {
 
 log.info("Local node seems to be disconnected from topology 
(failure detection timeout " +
 "is reached): [failureDetectionTimeout=" + 
spi.failureDetectionTimeout() +
@@ -4123,7 +4132,10 @@ class ServerImpl extends TcpDiscoveryImpl {
 if (elapsed > 0)
 return;
 
-if (ring.hasRemoteNodes()) {
+if (hasRemoteSrvNodes == null)
+hasRemoteSrvNodes = ring.hasRemoteServerNodes();
+
+if (hasRemoteSrvNodes) {
 sendMessageAcrossRing(new 
TcpDiscoveryConnectionCheckMessage(locNode));
 
 lastTimeConnCheckMsgSent = U.currentTimeMillis();

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/38070b28/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

[40/50] incubator-ignite git commit: Merge remote-tracking branch 'remotes/origin/ignite-1.3.3-p2'

2015-08-19 Thread vozerov
Merge remote-tracking branch 'remotes/origin/ignite-1.3.3-p2'

Conflicts:
examples/pom.xml
modules/aop/pom.xml
modules/apache-license-gen/pom.xml
modules/aws/pom.xml
modules/clients/pom.xml
modules/cloud/pom.xml
modules/codegen/pom.xml
modules/core/pom.xml

modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
modules/core/src/main/resources/ignite.properties

modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheDhtLocalPartitionAfterRemoveSelfTest.java

modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/IgniteCachePutRetryAbstractSelfTest.java
modules/extdata/p2p/pom.xml
modules/extdata/uri/modules/uri-dependency/pom.xml
modules/extdata/uri/pom.xml
modules/gce/pom.xml
modules/geospatial/pom.xml
modules/hadoop/pom.xml
modules/hibernate/pom.xml
modules/indexing/pom.xml
modules/jcl/pom.xml
modules/jta/pom.xml
modules/kafka/pom.xml
modules/log4j/pom.xml
modules/mesos/pom.xml
modules/rest-http/pom.xml
modules/scalar-2.10/pom.xml
modules/scalar/pom.xml
modules/schedule/pom.xml
modules/schema-import/pom.xml
modules/slf4j/pom.xml
modules/spark-2.10/pom.xml
modules/spark/pom.xml
modules/spring/pom.xml
modules/ssh/pom.xml
modules/tools/pom.xml
modules/urideploy/pom.xml
modules/visor-console-2.10/pom.xml
modules/visor-console/pom.xml
modules/visor-plugins/pom.xml
modules/web/pom.xml
modules/yardstick/pom.xml
modules/yarn/pom.xml
pom.xml

Merge remote-tracking branch 'remotes/origin/ignite-1.3.3-p2'

Conflicts:
benchmarks/cache-comparison/pom.xml
benchmarks/filesystem/hadoop1/pom.xml
benchmarks/filesystem/hadoop2/pom.xml
benchmarks/mongo/pom.xml
benchmarks/risk-analytics/pom.xml
benchmarks/serialization/pom.xml

benchmarks/yardstick/src/main/dotnet/gridgain-benchmarks/Properties/AssemblyInfo.cs
examples/clients/cpp/configure.ac

examples/clients/dotnet/GridGainExamples/GridGainExamples/Properties/AssemblyInfo.cs

examples/clients/dotnet/GridGainExamples/GridGainExamplesDll/Properties/AssemblyInfo.cs
examples/pom.xml
modules/clients/common/configure.ac
modules/clients/common/project/vs/Resource.rc
modules/clients/cpp/_old/main/configure.ac
modules/clients/cpp/_old/main/tests/configure.ac
modules/clients/cpp/_old/vsproject/resource.h
modules/clients/cpp/core-test/configure.ac
modules/clients/cpp/core-test/project/vs/Resource.rc
modules/clients/cpp/core/configure.ac
modules/clients/cpp/core/project/vs/Resource.rc
modules/clients/dotnet/gridgain-codegen/Properties/AssemblyInfo.cs
modules/clients/dotnet/gridgain-exe/Properties/AssemblyInfo.cs
modules/clients/dotnet/gridgain/Properties/AssemblyInfo.cs
modules/clients/pom.xml

modules/clients/src/test/dotnet/gridgain-examples-test/Properties/AssemblyInfo.cs

modules/clients/src/test/dotnet/gridgain-test-compatibility/Properties/AssemblyInfo.cs

modules/clients/src/test/dotnet/gridgain-test-dll/Properties/AssemblyInfo.cs

modules/clients/src/test/dotnet/gridgain-test-runner/Properties/AssemblyInfo.cs
modules/clients/src/test/dotnet/gridgain-test/Properties/AssemblyInfo.cs
modules/codegen/pom.xml

modules/compatibility/gg-versions/7.3.3/src/main/java/org/gridgain/grid/compatibility/GridCompatibilityTestsRunner.java
modules/compatibility/pom.xml
modules/core/pom.xml
modules/core/src/main/resources/gridgain.properties
modules/diagnostic/pom.xml
modules/dr-demo/pom.xml
modules/license-gen/pom.xml
modules/mongo-sniffer/pom.xml
modules/mongo-visor/pom.xml
modules/mongo/pom.xml
modules/tools/pom.xml
modules/visor-console/pom.xml
modules/visor-demo/pom.xml
modules/visor-tester-plugin/pom.xml
modules/visor-tester/pom.xml
modules/visor/pom.xml
modules/yardstick/dotnet/Properties/AssemblyInfo.cs
modules/yardstick/pom.xml
parent/pom.xml
pilots/chronotrack/pom.xml
pilots/ctb/pom.xml
pilots/dsi/pom.xml
pilots/ionic/pom.xml
pilots/sb/pom.xml
pilots/sony/pom.xml
pilots/wellsfargo/pom.xml
pilots/worldpay/pom.xml
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/648cbd78
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/648cbd78
Diff: http://git-wip-us.apache.org/repos/asf/incubat

[23/50] incubator-ignite git commit: # Register client continuous listeners on node join

2015-08-19 Thread vozerov
 # Register client continuous listeners on node join


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 35e3e4e048fa34b5b23ebd0ae235424f3e3492d9
Parents: aed83af
Author: sboikov 
Authored: Thu Aug 13 17:37:00 2015 +0300
Committer: sboikov 
Committed: Thu Aug 13 17:37:00 2015 +0300

--
 .../continuous/GridContinuousProcessor.java | 44 
 .../IgniteCacheContinuousQueryClientTest.java   | 33 ---
 .../IgniteCacheQuerySelfTestSuite.java  |  1 +
 scripts/git-format-patch.sh |  2 +-
 4 files changed, 66 insertions(+), 14 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/35e3e4e0/modules/core/src/main/java/org/apache/ignite/internal/processors/continuous/GridContinuousProcessor.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/continuous/GridContinuousProcessor.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/continuous/GridContinuousProcessor.java
index daa9494..5f1c4bb 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/continuous/GridContinuousProcessor.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/continuous/GridContinuousProcessor.java
@@ -193,10 +193,10 @@ public class GridContinuousProcessor extends 
GridProcessorAdapter {
 unregisterRemote(routineId);
 
 if (snd.isClient()) {
-Map infoMap = 
clientInfos.get(snd.id());
+Map clientRoutineMap = 
clientInfos.get(snd.id());
 
-if (infoMap != null)
-infoMap.remove(msg.routineId());
+if (clientRoutineMap != null)
+clientRoutineMap.remove(msg.routineId());
 }
 }
 }
@@ -370,6 +370,34 @@ public class GridContinuousProcessor extends 
GridProcessorAdapter {
 }
 
 for (Map.Entry> entry : 
data.clientInfos.entrySet()) {
+UUID clientNodeId = entry.getKey();
+
+Map clientRoutineMap = 
entry.getValue();
+
+for (Map.Entry e : 
clientRoutineMap.entrySet()) {
+UUID routineId = e.getKey();
+LocalRoutineInfo info = e.getValue();
+
+try {
+if (info.prjPred != null)
+ctx.resource().injectGeneric(info.prjPred);
+
+if (info.prjPred == null || 
info.prjPred.apply(ctx.discovery().localNode())) {
+if (registerHandler(clientNodeId,
+routineId,
+info.hnd,
+info.bufSize,
+info.interval,
+info.autoUnsubscribe,
+false))
+info.hnd.onListenerRegistered(routineId, ctx);
+}
+}
+catch (IgniteCheckedException err) {
+U.error(log, "Failed to register continuous handler.", 
err);
+}
+}
+
 Map map = 
clientInfos.get(entry.getKey());
 
 if (map == null) {
@@ -723,17 +751,17 @@ public class GridContinuousProcessor extends 
GridProcessorAdapter {
 }
 
 if (node.isClient()) {
-Map clientRouteMap = 
clientInfos.get(node.id());
+Map clientRoutineMap = 
clientInfos.get(node.id());
 
-if (clientRouteMap == null) {
-clientRouteMap = new HashMap<>();
+if (clientRoutineMap == null) {
+clientRoutineMap = new HashMap<>();
 
-Map old = clientInfos.put(node.id(), 
clientRouteMap);
+Map old = clientInfos.put(node.id(), 
clientRoutineMap);
 
 assert old == null;
 }
 
-clientRouteMap.put(routineId, new 
LocalRoutineInfo(data.projectionPredicate(),
+clientRoutineMap.put(routineId, new 
LocalRoutineInfo(data.projectionPredicate(),
 hnd,
 data.bufferSize(),
 data.interval(),

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/35e3e4e0/modules/core/src/test/java/org/apache/ignite/internal/processors/cach

[37/50] incubator-ignite git commit: # Properly handle ClusterTopologyServerNotFoundException for retries

2015-08-19 Thread vozerov
# Properly handle ClusterTopologyServerNotFoundException for retries


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 5faffb98032f54ed1160279de9d52938aef94bd2
Parents: 2903a29
Author: sboikov 
Authored: Fri Aug 14 16:23:19 2015 +0300
Committer: sboikov 
Committed: Fri Aug 14 16:23:19 2015 +0300

--
 .../processors/cache/CachePartialUpdateCheckedException.java   | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/5faffb98/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CachePartialUpdateCheckedException.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CachePartialUpdateCheckedException.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CachePartialUpdateCheckedException.java
index f430d12..c2259df 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CachePartialUpdateCheckedException.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CachePartialUpdateCheckedException.java
@@ -34,7 +34,7 @@ public class CachePartialUpdateCheckedException extends 
IgniteCheckedException {
 private final Collection failedKeys = new ArrayList<>();
 
 /** */
-private AffinityTopologyVersion topVer;
+private transient AffinityTopologyVersion topVer;
 
 /**
  * @param msg Error message.



[33/50] incubator-ignite git commit: Merge branch 'ignite-946'

2015-08-19 Thread vozerov
Merge branch 'ignite-946'


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 776084772c06f6149d09726b2f6c3c7a08cef7bc
Parents: 8ecddcc 51a9bd8
Author: nikolay_tikhonov 
Authored: Fri Aug 14 12:54:34 2015 +0300
Committer: nikolay_tikhonov 
Committed: Fri Aug 14 12:54:34 2015 +0300

--
 .../org/apache/ignite/cache/CacheEntry.java |  94 ++
 .../processors/cache/CacheEntryImpl.java|  20 +++
 .../processors/cache/CacheEntryImpl0.java   |   5 +
 .../processors/cache/CacheEntryImplEx.java  |  83 +
 .../processors/cache/CacheInvokeEntry.java  |  27 ++-
 .../cache/CacheVersionedEntryImpl.java  |  80 -
 .../processors/cache/GridCacheAdapter.java  |  13 +-
 .../processors/cache/GridCacheEntryEx.java  |   2 +-
 .../processors/cache/GridCacheMapEntry.java |  28 ++-
 .../processors/cache/GridCacheSwapManager.java  |  82 +
 .../distributed/dht/GridDhtTxPrepareFuture.java |   2 +-
 .../dht/atomic/GridDhtAtomicCache.java  |   3 +-
 .../local/atomic/GridLocalAtomicCache.java  |   3 +-
 .../cache/transactions/IgniteTxAdapter.java |  16 +-
 .../cache/transactions/IgniteTxEntry.java   |  16 +-
 .../transactions/IgniteTxLocalAdapter.java  |  83 +++--
 .../cache/version/GridCacheVersion.java |   2 +-
 .../cache/version/GridCacheVersionAware.java|  30 
 .../cache/version/GridCacheVersionManager.java  |   5 +-
 .../clock/GridClockSyncProcessor.java   |   2 +-
 .../resources/META-INF/classnames.properties|   3 +-
 .../processors/cache/GridCacheTestEntryEx.java  |   2 +-
 .../CacheVersionedEntryAbstractTest.java| 170 +++
 ...nedEntryLocalAtomicSwapDisabledSelfTest.java |  45 +
 ...ersionedEntryLocalTransactionalSelfTest.java |  40 +
 ...edEntryPartitionedAtomicOffHeapSelfTest.java |  35 
 ...VersionedEntryPartitionedAtomicSelfTest.java |  35 
 ...PartitionedTransactionalOffHeapSelfTest.java |  36 
 ...edEntryPartitionedTransactionalSelfTest.java |  35 
 ...nedEntryReplicatedAtomicOffHeapSelfTest.java |  35 
 ...eVersionedEntryReplicatedAtomicSelfTest.java |  35 
 ...yReplicatedTransactionalOffHeapSelfTest.java |  36 
 ...nedEntryReplicatedTransactionalSelfTest.java |  35 
 .../testsuites/IgniteCacheTestSuite4.java   |  13 ++
 34 files changed, 1005 insertions(+), 146 deletions(-)
--




[36/50] incubator-ignite git commit: # Properly handle ClusterTopologyServerNotFoundException for retries

2015-08-19 Thread vozerov
# Properly handle ClusterTopologyServerNotFoundException for retries


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 2903a29e7a50802617872bfd0fcc3497c4c7785e
Parents: 122a9db
Author: sboikov 
Authored: Fri Aug 14 16:22:25 2015 +0300
Committer: sboikov 
Committed: Fri Aug 14 16:22:25 2015 +0300

--
 .../CachePartialUpdateCheckedException.java | 29 +++-
 .../processors/cache/GridCacheAdapter.java  | 50 
 .../dht/atomic/GridNearAtomicUpdateFuture.java  | 48 +++
 .../near/GridNearOptimisticTxPrepareFuture.java |  2 +-
 .../cache/GridCacheAbstractFullApiSelfTest.java |  1 -
 5 files changed, 86 insertions(+), 44 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/2903a29e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CachePartialUpdateCheckedException.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CachePartialUpdateCheckedException.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CachePartialUpdateCheckedException.java
index 0272b7c..f430d12 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CachePartialUpdateCheckedException.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CachePartialUpdateCheckedException.java
@@ -18,6 +18,7 @@
 package org.apache.ignite.internal.processors.cache;
 
 import org.apache.ignite.*;
+import org.apache.ignite.internal.processors.affinity.*;
 
 import java.util.*;
 
@@ -32,6 +33,9 @@ public class CachePartialUpdateCheckedException extends 
IgniteCheckedException {
 /** Failed keys. */
 private final Collection failedKeys = new ArrayList<>();
 
+/** */
+private AffinityTopologyVersion topVer;
+
 /**
  * @param msg Error message.
  */
@@ -50,13 +54,36 @@ public class CachePartialUpdateCheckedException extends 
IgniteCheckedException {
 /**
  * @param failedKeys Failed keys.
  * @param err Error.
+ * @param topVer Topology version for failed update.
  */
-public void add(Collection failedKeys, Throwable err) {
+public void add(Collection failedKeys, Throwable err, 
AffinityTopologyVersion topVer) {
+if (topVer != null) {
+AffinityTopologyVersion topVer0 = this.topVer;
+
+if (topVer0 == null || topVer.compareTo(topVer0) > 0)
+this.topVer = topVer;
+}
+
 this.failedKeys.addAll(failedKeys);
 
 addSuppressed(err);
 }
 
+/**
+ * @return Topology version.
+ */
+public AffinityTopologyVersion topologyVersion() {
+return topVer;
+}
+
+/**
+ * @param failedKeys Failed keys.
+ * @param err Error.
+ */
+public void add(Collection failedKeys, Throwable err) {
+add(failedKeys, err, null);
+}
+
 /** {@inheritDoc} */
 @Override public String getMessage() {
 return super.getMessage() + ": " + failedKeys;

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/2903a29e/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
index 91af352..992edd8 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
@@ -3975,13 +3975,17 @@ public abstract class GridCacheAdapter implements 
IgniteInternalCache 0 
: tx;
+if (!(topErr instanceof 
ClusterTopologyServerNotFoundException)) {
+AffinityTopologyVersion topVer = 
tx.topologyVersion();
+
+assert topVer != null && topVer.topologyVersion() 
> 0 : tx;
 
-
ctx.affinity().affinityReadyFuture(topVer.topologyVersion() + 1).get();
+
ctx.affinity().affinityReadyFuture(topVer.topologyVersion() + 1).get();
 
-continue;
+continue;
+}
 }
 
 throw e;
@@ -4702,31 +4706,35 @@ public abstract class GridCacheAdapter implements 
Ign

[43/50] incubator-ignite git commit: Squashed commit for ignite-1239

2015-08-19 Thread vozerov
Squashed commit for ignite-1239


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 45c813af7eb4a11ec59d3477a6a0b68791f1d7f2
Parents: 7635e58
Author: Denis Magda 
Authored: Mon Aug 17 16:51:41 2015 +0300
Committer: Yakov Zhdanov 
Committed: Mon Aug 17 16:51:41 2015 +0300

--
 .../GridDhtUnreservedPartitionException.java| 66 ++
 .../cache/query/GridCacheQueryAdapter.java  | 56 ++--
 .../cache/query/GridCacheQueryManager.java  | 71 ++-
 ...CacheScanPartitionQueryFallbackSelfTest.java | 96 
 4 files changed, 261 insertions(+), 28 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/45c813af/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtUnreservedPartitionException.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtUnreservedPartitionException.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtUnreservedPartitionException.java
new file mode 100644
index 000..d824a47
--- /dev/null
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtUnreservedPartitionException.java
@@ -0,0 +1,66 @@
+/*
+ * 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.dht;
+
+import org.apache.ignite.*;
+import org.apache.ignite.internal.processors.affinity.*;
+
+/**
+ * Exception that is thrown when a partition reservation failed.
+ */
+public class GridDhtUnreservedPartitionException extends 
IgniteCheckedException {
+/** */
+private static final long serialVersionUID = 0L;
+
+/** Partition. */
+private final int part;
+
+/** Topology version. */
+private final AffinityTopologyVersion topVer;
+
+/**
+ * @param part Partition.
+ * @param topVer Affinity topology version.
+ * @param msg Message.
+ */
+public GridDhtUnreservedPartitionException(int part, 
AffinityTopologyVersion topVer, String msg) {
+super(msg);
+
+this.part = part;
+this.topVer = topVer;
+}
+
+/**
+ * @return Partition.
+ */
+public int partition() {
+return part;
+}
+
+/**
+ * @return Affinity topology version.
+ */
+public AffinityTopologyVersion topologyVersion() {
+return topVer;
+}
+
+/** {@inheritDoc} */
+@Override public String toString() {
+return getClass() + " [part=" + part + ", msg=" + getMessage() + ']';
+}
+}

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/45c813af/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryAdapter.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryAdapter.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryAdapter.java
index 953cb9a..90f9b9e 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryAdapter.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryAdapter.java
@@ -25,6 +25,7 @@ import org.apache.ignite.internal.*;
 import org.apache.ignite.internal.cluster.*;
 import org.apache.ignite.internal.processors.affinity.*;
 import org.apache.ignite.internal.processors.cache.*;
+import org.apache.ignite.internal.processors.cache.distributed.dht.*;
 import org.apache.ignite.internal.processors.query.*;
 import org.apache.ignite.internal.util.future.*;
 im

[27/50] incubator-ignite git commit: JavaDoc fix

2015-08-19 Thread vozerov
JavaDoc fix


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 260238e041c66a02f2552692bab2f44a923f7d41
Parents: ba3abce
Author: Valentin Kulichenko 
Authored: Thu Aug 13 15:50:48 2015 -0700
Committer: Valentin Kulichenko 
Committed: Thu Aug 13 15:50:48 2015 -0700

--
 .../main/java/org/apache/ignite/internal/IgnitionEx.java  | 10 +-
 .../src/main/java/org/apache/ignite/IgniteSpring.java |  8 
 2 files changed, 9 insertions(+), 9 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/260238e0/modules/core/src/main/java/org/apache/ignite/internal/IgnitionEx.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/IgnitionEx.java 
b/modules/core/src/main/java/org/apache/ignite/internal/IgnitionEx.java
index 3790703..fd74745 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/IgnitionEx.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/IgnitionEx.java
@@ -429,7 +429,7 @@ public class IgnitionEx {
  * @param springCtx Optional Spring application context, possibly {@code 
null}.
  *  Spring bean definitions for bean injection are taken from this 
context.
  *  If provided, this context can be injected into grid tasks and grid 
jobs using
- *  {@link SpringApplicationContextResource 
@IgniteSpringApplicationContextResource} annotation.
+ *  {@link SpringApplicationContextResource 
@SpringApplicationContextResource} annotation.
  * @return Started grid.
  * @throws IgniteCheckedException If default grid could not be started. 
This exception will be thrown
  *  also if default grid has already been started.
@@ -466,7 +466,7 @@ public class IgnitionEx {
  * @param springCtx Optional Spring application context, possibly {@code 
null}.
  *  Spring bean definitions for bean injection are taken from this 
context.
  *  If provided, this context can be injected into grid tasks and grid 
jobs using
- *  {@link SpringApplicationContextResource 
@IgniteSpringApplicationContextResource} annotation.
+ *  {@link SpringApplicationContextResource 
@SpringApplicationContextResource} annotation.
  * @return Started grid.
  * @throws IgniteCheckedException If grid could not be started. This 
exception will be thrown
  *  also if named grid has already been started.
@@ -642,7 +642,7 @@ public class IgnitionEx {
  * @param springCtx Optional Spring application context, possibly {@code 
null}.
  *  Spring bean definitions for bean injection are taken from this 
context.
  *  If provided, this context can be injected into grid tasks and grid 
jobs using
- *  {@link SpringApplicationContextResource 
@IgniteSpringApplicationContextResource} annotation.
+ *  {@link SpringApplicationContextResource 
@SpringApplicationContextResource} annotation.
  * @return Started grid. If Spring configuration contains multiple grid 
instances,
  *  then the 1st found instance is returned.
  * @throws IgniteCheckedException If grid could not be started or 
configuration
@@ -690,7 +690,7 @@ public class IgnitionEx {
  * @param springCtx Optional Spring application context, possibly {@code 
null}.
  *  Spring bean definitions for bean injection are taken from this 
context.
  *  If provided, this context can be injected into grid tasks and grid 
jobs using
- *  {@link SpringApplicationContextResource 
@IgniteSpringApplicationContextResource} annotation.
+ *  {@link SpringApplicationContextResource 
@SpringApplicationContextResource} annotation.
  * @return Started grid. If Spring configuration contains multiple grid 
instances,
  *  then the 1st found instance is returned.
  * @throws IgniteCheckedException If grid could not be started or 
configuration
@@ -769,7 +769,7 @@ public class IgnitionEx {
  * @param springCtx Optional Spring application context, possibly {@code 
null}.
  *  Spring bean definitions for bean injection are taken from this 
context.
  *  If provided, this context can be injected into grid tasks and grid 
jobs using
- *  {@link SpringApplicationContextResource 
@IgniteSpringApplicationContextResource} annotation.
+ *  {@link SpringApplicationContextResource 
@SpringApplicationContextResource} annotation.
  * @return Started grid. If Spring configuration contains multiple grid 
instances,
  *  then th

[19/50] incubator-ignite git commit: Fixed error message

2015-08-19 Thread vozerov
Fixed error message


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 36f7ba669fd5b706fd9b01c06ce20dbb7610d50f
Parents: 653c0b2
Author: Valentin Kulichenko 
Authored: Wed Aug 12 16:56:18 2015 -0700
Committer: Valentin Kulichenko 
Committed: Wed Aug 12 16:56:18 2015 -0700

--
 .../apache/ignite/internal/processors/cache/GridCacheGateway.java  | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/36f7ba66/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheGateway.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheGateway.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheGateway.java
index 93c5858..58c9035 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheGateway.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheGateway.java
@@ -156,7 +156,7 @@ public class GridCacheGateway {
 GridCachePreloader preldr = cache != null ? cache.preloader() : 
null;
 
 if (preldr == null)
-throw new IllegalStateException("Cache has been closed: " + 
ctx.name());
+throw new IllegalStateException("Cache has been closed or 
destroyed: " + ctx.name());
 
 preldr.startFuture().get();
 }



[48/50] incubator-ignite git commit: Deprecated IgniteConfiguration.setNodeId()

2015-08-19 Thread vozerov
Deprecated IgniteConfiguration.setNodeId()


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

Branch: refs/heads/ignite-gg-9615-1
Commit: fcd9d611503592ef3104feee42d82b3956aae42d
Parents: d31c8c6
Author: Valentin Kulichenko 
Authored: Mon Aug 17 21:24:55 2015 -0700
Committer: Valentin Kulichenko 
Committed: Mon Aug 17 21:24:55 2015 -0700

--
 .../org/apache/ignite/configuration/IgniteConfiguration.java| 5 -
 1 file changed, 4 insertions(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/fcd9d611/modules/core/src/main/java/org/apache/ignite/configuration/IgniteConfiguration.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/configuration/IgniteConfiguration.java
 
b/modules/core/src/main/java/org/apache/ignite/configuration/IgniteConfiguration.java
index 546c382..b670398 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/configuration/IgniteConfiguration.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/configuration/IgniteConfiguration.java
@@ -60,8 +60,8 @@ import javax.cache.expiry.*;
 import javax.cache.integration.*;
 import javax.cache.processor.*;
 import javax.management.*;
-import java.io.*;
 import javax.net.ssl.*;
+import java.io.*;
 import java.lang.management.*;
 import java.util.*;
 
@@ -970,6 +970,7 @@ public class IgniteConfiguration {
  *
  * @return Unique identifier for this node within grid.
  */
+@Deprecated
 public UUID getNodeId() {
 return nodeId;
 }
@@ -980,7 +981,9 @@ public class IgniteConfiguration {
  * @param nodeId Unique identifier for local node.
  * @see IgniteConfiguration#getNodeId()
  * @return {@code this} for chaining.
+ * @deprecated Use {@link #setConsistentId(Serializable)} instead.
  */
+@Deprecated
 public IgniteConfiguration setNodeId(UUID nodeId) {
 this.nodeId = nodeId;
 



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

2015-08-19 Thread vozerov
Merge remote-tracking branch 'origin/ignite-946' into ignite-946


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 9f16eb165f2aad48f05cef17f608eb2898c078a3
Parents: 92e81dc 53557e3
Author: Denis Magda 
Authored: Mon Aug 10 09:58:27 2015 +0300
Committer: Denis Magda 
Committed: Mon Aug 10 09:58:27 2015 +0300

--
 .../apache/ignite/cache/version/package-info.java |  4 ++--
 .../processors/cache/CacheInvokeEntry.java|  5 +++--
 .../cache/transactions/IgniteTxEntry.java |  4 +++-
 .../cache/transactions/IgniteTxLocalAdapter.java  | 18 +-
 4 files changed, 17 insertions(+), 14 deletions(-)
--




[22/50] incubator-ignite git commit: # Test for ignite-1245.

2015-08-19 Thread vozerov
# Test for ignite-1245.


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

Branch: refs/heads/ignite-gg-9615-1
Commit: aed83af5f76c47bc9e4d0e8f60955fc6c6b42aac
Parents: 36f7ba6
Author: sboikov 
Authored: Thu Aug 13 13:05:43 2015 +0300
Committer: sboikov 
Committed: Thu Aug 13 13:05:43 2015 +0300

--
 .../IgniteCacheContinuousQueryClientTest.java   | 114 +++
 1 file changed, 114 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/aed83af5/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/query/continuous/IgniteCacheContinuousQueryClientTest.java
--
diff --git 
a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/query/continuous/IgniteCacheContinuousQueryClientTest.java
 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/query/continuous/IgniteCacheContinuousQueryClientTest.java
new file mode 100644
index 000..bb413a0
--- /dev/null
+++ 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/query/continuous/IgniteCacheContinuousQueryClientTest.java
@@ -0,0 +1,114 @@
+/*
+ * 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.query.continuous;
+
+import org.apache.ignite.*;
+import org.apache.ignite.cache.query.*;
+import org.apache.ignite.configuration.*;
+import org.apache.ignite.resources.*;
+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.event.*;
+import java.util.concurrent.*;
+
+import static java.util.concurrent.TimeUnit.*;
+import static org.apache.ignite.cache.CacheAtomicityMode.*;
+import static org.apache.ignite.cache.CacheMode.*;
+import static org.apache.ignite.cache.CacheWriteSynchronizationMode.*;
+
+/**
+ *
+ */
+public class IgniteCacheContinuousQueryClientTest extends 
GridCommonAbstractTest {
+/** */
+protected static TcpDiscoveryIpFinder ipFinder = new 
TcpDiscoveryVmIpFinder(true);
+
+/** */
+private boolean client;
+
+/** {@inheritDoc} */
+@Override protected IgniteConfiguration getConfiguration(String gridName) 
throws Exception {
+IgniteConfiguration cfg = super.getConfiguration(gridName);
+
+CacheConfiguration ccfg = new CacheConfiguration();
+
+ccfg.setCacheMode(PARTITIONED);
+ccfg.setAtomicityMode(ATOMIC);
+ccfg.setWriteSynchronizationMode(FULL_SYNC);
+
+cfg.setCacheConfiguration(ccfg);
+
+cfg.setClientMode(client);
+
+return cfg;
+}
+
+/**
+ * @throws Exception If failed.
+ */
+public void testNodeJoins() throws Exception {
+startGrids(2);
+
+client = true;
+
+Ignite clientNode = startGrid(3);
+
+client = false;
+
+CacheEventListener lsnr = new CacheEventListener();
+
+ContinuousQuery qry = new ContinuousQuery<>();
+
+qry.setLocalListener(lsnr);
+
+QueryCursor cur = clientNode.cache(null).query(qry);
+
+Ignite joined = startGrid(4);
+
+IgniteCache joinedCache = joined.cache(null);
+
+joinedCache.put(primaryKey(joinedCache), 1);
+
+assertTrue("Failed to wait for event.", lsnr.latch.await(5, SECONDS));
+
+cur.close();
+}
+
+/**
+ *
+ */
+private static class CacheEventListener implements 
CacheEntryUpdatedListener {
+/** */
+private final CountDownLatch latch = new CountDownLatch(1);
+
+/** */
+@LoggerResource
+private IgniteLogger log;
+
+/** {@inheritDoc} */
+@Override public void onUpdated(Iterable> evts) {
+for (CacheEntryEvent evt : evts) {
+log.info

[17/50] incubator-ignite git commit: ignite-946: reverted renaming topVer to avoid breaking compatibility

2015-08-19 Thread vozerov
ignite-946: reverted renaming topVer to avoid breaking compatibility


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 954c4591c95b7625042657f7a7311f4ea0f17c19
Parents: 801d6df
Author: Denis Magda 
Authored: Tue Aug 11 15:00:47 2015 +0300
Committer: Denis Magda 
Committed: Tue Aug 11 15:00:47 2015 +0300

--
 .../cache/GridCacheAtomicVersionComparator.java |  4 +--
 .../processors/cache/GridCacheMapEntry.java |  2 +-
 .../processors/cache/GridCacheUtils.java|  2 +-
 .../cache/transactions/IgniteTxManager.java |  2 +-
 .../cache/version/CacheVersionedEntryImpl.java  |  4 +--
 .../version/GridCachePlainVersionedEntry.java   |  2 +-
 .../version/GridCacheRawVersionedEntry.java |  2 +-
 .../cache/version/GridCacheVersion.java | 26 ++--
 .../cache/version/GridCacheVersionManager.java  |  4 +--
 .../ignite/internal/util/IgniteUtils.java   |  4 +--
 .../cache/GridCacheEntryVersionSelfTest.java|  4 +--
 11 files changed, 28 insertions(+), 28 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/954c4591/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAtomicVersionComparator.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAtomicVersionComparator.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAtomicVersionComparator.java
index 45288d9..3a06100 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAtomicVersionComparator.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAtomicVersionComparator.java
@@ -32,8 +32,8 @@ public class GridCacheAtomicVersionComparator {
  * @return Comparison value.
  */
 public int compare(GridCacheVersion one, GridCacheVersion other, boolean 
ignoreTime) {
-int topVer = one.topologyOrder();
-int otherTopVer = other.topologyOrder();
+int topVer = one.topologyVersion();
+int otherTopVer = other.topologyVersion();
 
 if (topVer == otherTopVer) {
 long globalTime = one.globalTime();

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/954c4591/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
index 33c42c4..298f7a6 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
@@ -1927,7 +1927,7 @@ public abstract class GridCacheMapEntry extends 
GridMetadataAwareAdapter impleme
 
 // Incorporate conflict version into new version if needed.
 if (conflictVer != null && conflictVer != newVer)
-newVer = new GridCacheVersionEx(newVer.topologyOrder(),
+newVer = new GridCacheVersionEx(newVer.topologyVersion(),
 newVer.globalTime(),
 newVer.order(),
 newVer.nodeOrder(),

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/954c4591/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
index 75f1dee..a313e3d 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
@@ -1060,7 +1060,7 @@ public class GridCacheUtils {
 
 byte[] bytes = new byte[28];
 
-U.intToBytes(ver.topologyOrder(), bytes, 0);
+U.intToBytes(ver.topologyVersion(), bytes, 0);
 U.longToBytes(ver.globalTime(), bytes, 4);
 U.longToBytes(ver.order(), bytes, 12);
 U.intToBytes(ver.nodeOrderAndDrIdRaw(), bytes, 20);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/954c4591/modules/core/src/main/java/org/apache/i

[47/50] incubator-ignite git commit: master - OFFSET clause fix IGNITE-1259

2015-08-19 Thread vozerov
master - OFFSET clause fix IGNITE-1259


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

Branch: refs/heads/ignite-gg-9615-1
Commit: d31c8c6477e03563bf73db3cf216250b9c22b562
Parents: 9c939be
Author: S.Vladykin 
Authored: Mon Aug 17 21:25:25 2015 +0300
Committer: S.Vladykin 
Committed: Mon Aug 17 21:25:25 2015 +0300

--
 .../query/h2/sql/GridSqlQuerySplitter.java  |   3 +
 .../query/IgniteSqlSplitterSelfTest.java| 152 +++
 .../IgniteCacheQuerySelfTestSuite.java  |   2 +
 3 files changed, 157 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/d31c8c64/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/sql/GridSqlQuerySplitter.java
--
diff --git 
a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/sql/GridSqlQuerySplitter.java
 
b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/sql/GridSqlQuerySplitter.java
index 2f8bcdd..34aef87 100644
--- 
a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/sql/GridSqlQuerySplitter.java
+++ 
b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/sql/GridSqlQuerySplitter.java
@@ -205,6 +205,9 @@ public class GridSqlQuerySplitter {
 if (mapQry.offset() != null) {
 rdcQry.offset(mapQry.offset());
 
+if (mapQry.limit() != null) // LIMIT off + lim
+mapQry.limit(op(GridSqlOperationType.PLUS, mapQry.offset(), 
mapQry.limit()));
+
 mapQry.offset(null);
 }
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/d31c8c64/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlSplitterSelfTest.java
--
diff --git 
a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlSplitterSelfTest.java
 
b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlSplitterSelfTest.java
new file mode 100644
index 000..6ec6bb3
--- /dev/null
+++ 
b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/IgniteSqlSplitterSelfTest.java
@@ -0,0 +1,152 @@
+/*
+ * 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.query;
+
+import org.apache.ignite.*;
+import org.apache.ignite.cache.*;
+import org.apache.ignite.cache.query.*;
+import org.apache.ignite.configuration.*;
+import org.apache.ignite.internal.util.*;
+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 java.util.*;
+
+/**
+ * Tests for correct distributed partitioned queries.
+ */
+@SuppressWarnings("unchecked")
+public class IgniteSqlSplitterSelfTest extends GridCommonAbstractTest {
+/** */
+private static final TcpDiscoveryIpFinder ipFinder = new 
TcpDiscoveryVmIpFinder(true);
+
+/** {@inheritDoc} */
+@Override protected IgniteConfiguration getConfiguration() throws 
Exception {
+IgniteConfiguration cfg = super.getConfiguration();
+
+cfg.setPeerClassLoadingEnabled(false);
+
+TcpDiscoverySpi disco = new TcpDiscoverySpi();
+
+disco.setIpFinder(ipFinder);
+
+cfg.setDiscoverySpi(disco);
+
+return cfg;
+}
+
+/** {@inheritDoc} */
+@Override protected void beforeTestsStarted() throws Exception {
+startGridsMultiThreaded(3, false);
+}
+
+/** {@inheritDoc} */
+@Override protected void afterTestsStopped() throws Exception {
+stopAllGrids();
+}
+
+/**
+ * @param name Cache name.
+

[16/50] incubator-ignite git commit: # ignite-1175: call 'onDeferredDelete' from innerRemover

2015-08-19 Thread vozerov
# ignite-1175: call 'onDeferredDelete' from innerRemover


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 51dcd518e51883ca043492a86928cf3488db4bd7
Parents: 834b347
Author: sboikov 
Authored: Tue Aug 11 11:30:02 2015 +0300
Committer: sboikov 
Committed: Tue Aug 11 11:39:54 2015 +0300

--
 .../processors/cache/GridCacheMapEntry.java |   4 +-
 ...cheDhtLocalPartitionAfterRemoveSelfTest.java | 112 +++
 .../testsuites/IgniteCacheTestSuite2.java   |   1 +
 3 files changed, 116 insertions(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/51dcd518/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
index 4680994..a078bed 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
@@ -1232,7 +1232,9 @@ public abstract class GridCacheMapEntry implements 
GridCacheEntryEx {
 if (writeThrough)
 cctx.store().remove(tx, keyValue(false));
 
-if (!cctx.deferredDelete()) {
+if (cctx.deferredDelete() && !detached() && !isInternal())
+cctx.onDeferredDelete(this, newVer);
+else {
 boolean marked = false;
 
 synchronized (this) {

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/51dcd518/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheDhtLocalPartitionAfterRemoveSelfTest.java
--
diff --git 
a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheDhtLocalPartitionAfterRemoveSelfTest.java
 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheDhtLocalPartitionAfterRemoveSelfTest.java
new file mode 100644
index 000..a930d35
--- /dev/null
+++ 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheDhtLocalPartitionAfterRemoveSelfTest.java
@@ -0,0 +1,112 @@
+/*
+ * 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.configuration.*;
+import org.apache.ignite.internal.processors.cache.distributed.dht.*;
+import org.apache.ignite.testframework.junits.common.*;
+
+import static org.apache.ignite.cache.CacheAtomicityMode.*;
+
+/**
+ * Test for remove operation.
+ */
+public class CacheDhtLocalPartitionAfterRemoveSelfTest extends 
GridCommonAbstractTest {
+/** Grid count. */
+private static final int GRID_CNT = 3;
+
+/** {@inheritDoc} */
+@Override protected IgniteConfiguration getConfiguration(String gridName) 
throws Exception {
+IgniteConfiguration cfg = super.getConfiguration(gridName);
+
+CacheConfiguration ccfg = new CacheConfiguration();
+
+ccfg.setAtomicityMode(TRANSACTIONAL);
+ccfg.setNearConfiguration(null);
+
+cfg.setCacheConfiguration(ccfg);
+
+return cfg;
+}
+
+/** {@inheritDoc} */
+@Override protected void beforeTestsStarted() throws Exception {
+startGrids(GRID_CNT);
+}
+
+/** {@inheritDoc} */
+@Override protected void afterTestsStopped() throws Exception {
+stopAllGrids();
+}
+
+/**
+ * @throws Exception If failed.
+ */
+public void testMemoryUsage() throws Exception {
+assertEquals(10_000, GridDhtLocalPartition.MAX_DELETE_QUEUE_SIZE);

[25/50] incubator-ignite git commit: Merge remote-tracking branch 'origin/master'

2015-08-19 Thread vozerov
Merge remote-tracking branch 'origin/master'


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 6697b0c98c098a96ce572048b0c82cbfdfd41dca
Parents: 7290d06 35e3e4e
Author: vozerov-gridgain 
Authored: Thu Aug 13 18:10:25 2015 +0300
Committer: vozerov-gridgain 
Committed: Thu Aug 13 18:10:25 2015 +0300

--
 .../continuous/GridContinuousProcessor.java | 44 
 .../IgniteCacheContinuousQueryClientTest.java   | 33 ---
 .../IgniteCacheQuerySelfTestSuite.java  |  1 +
 scripts/git-format-patch.sh |  2 +-
 4 files changed, 66 insertions(+), 14 deletions(-)
--




[01/50] incubator-ignite git commit: ignite-946: added documentation

2015-08-19 Thread vozerov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-gg-9615-1 b73750b01 -> da3065212


ignite-946: added documentation


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 4928d99d80a837843ce733eab546a3ea6aa3c2d3
Parents: 2d200a3
Author: Denis Magda 
Authored: Fri Jul 31 12:14:54 2015 +0300
Committer: nikolay_tikhonov 
Committed: Fri Jul 31 15:49:12 2015 +0300

--
 .../ignite/cache/version/VersionedEntry.java| 31 +++-
 1 file changed, 30 insertions(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/4928d99d/modules/core/src/main/java/org/apache/ignite/cache/version/VersionedEntry.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/cache/version/VersionedEntry.java
 
b/modules/core/src/main/java/org/apache/ignite/cache/version/VersionedEntry.java
index 6f9d8f6..e669f15 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/cache/version/VersionedEntry.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/cache/version/VersionedEntry.java
@@ -17,11 +17,40 @@
 
 package org.apache.ignite.cache.version;
 
+import org.apache.ignite.*;
+
 import javax.cache.*;
+import javax.cache.processor.*;
 import java.util.*;
 
 /**
- * Cache entry along with version information.
+ * Cache entry that stores entry's version related information.
+ *
+ * To get a {@code VersionedEntry} of an {@link Cache.Entry} use {@link 
Cache.Entry#unwrap(Class)} by passing
+ * {@code VersionedEntry} class to it as the argument.
+ * 
+ * {@code VersionedEntry} is supported only for {@link Cache.Entry} returned 
by one of the following methods:
+ * 
+ * {@link Cache#invoke(Object, EntryProcessor, Object...)}
+ * {@link Cache#invokeAll(Set, EntryProcessor, Object...)}
+ * invoke and invokeAll methods of {@link IgniteCache}
+ * {@link IgniteCache#randomEntry()}
+ * 
+ * 
+ * {@code VersionedEntry} is not supported for {@link Cache#iterator()} 
because of performance reasons.
+ * {@link Cache#iterator()} loads entries from all the cluster nodes and to 
speed up the load version information
+ * is excluded from responses.
+ * Java Example
+ * 
+ * Cache cache = grid(0).cache(null);
+ *
+ *  cache.invoke(100, new EntryProcessor() {
+ *  public Object process(MutableEntry entry, Object... 
arguments) throws EntryProcessorException {
+ *  VersionedEntry verEntry = 
entry.unwrap(VersionedEntry.class);
+ *  return entry;
+ *   }
+ *   });
+ * 
  */
 public interface VersionedEntry extends Cache.Entry {
 /**



[38/50] incubator-ignite git commit: ignite-1228 - Closed #18

2015-08-19 Thread vozerov
ignite-1228 - Closed #18


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

Branch: refs/heads/ignite-gg-9615-1
Commit: d0536dcec02e46cc1e68a13676e87a140d511db2
Parents: 7760847 e5eef50
Author: Valentin Kulichenko 
Authored: Fri Aug 14 15:31:34 2015 -0700
Committer: Valentin Kulichenko 
Committed: Fri Aug 14 15:31:34 2015 -0700

--
 .../main/java/org/apache/ignite/logger/log4j/Log4JLogger.java| 4 
 1 file changed, 4 insertions(+)
--




[50/50] incubator-ignite git commit: Merge branch 'master' into ignite-gg-9615-1

2015-08-19 Thread vozerov
Merge branch 'master' into ignite-gg-9615-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/da306521
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/da306521
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/da306521

Branch: refs/heads/ignite-gg-9615-1
Commit: da306521295cfdaaa84d51ebe69f2478d818ca0b
Parents: b73750b 09da9c2
Author: vozerov-gridgain 
Authored: Wed Aug 19 10:08:43 2015 +0300
Committer: vozerov-gridgain 
Committed: Wed Aug 19 10:08:43 2015 +0300

--
 .../org/apache/ignite/cache/CacheEntry.java |  94 
 .../store/jdbc/CacheJdbcPojoStoreFactory.java   |   2 +-
 .../configuration/IgniteConfiguration.java  |   5 +-
 .../org/apache/ignite/internal/IgnitionEx.java  |  10 +-
 .../processors/cache/CacheEntryImpl.java|  20 +
 .../processors/cache/CacheEntryImpl0.java   |   5 +
 .../processors/cache/CacheEntryImplEx.java  |  83 +++
 .../processors/cache/CacheInvokeEntry.java  |  27 +-
 .../CachePartialUpdateCheckedException.java |  29 +-
 .../cache/CacheVersionedEntryImpl.java  |  80 ---
 .../processors/cache/GridCacheAdapter.java  | 174 +-
 .../processors/cache/GridCacheEntryEx.java  |   2 +-
 .../processors/cache/GridCacheGateway.java  |   5 +-
 .../processors/cache/GridCacheMapEntry.java |  32 +-
 .../processors/cache/GridCacheSwapManager.java  |  82 ++-
 .../distributed/dht/GridDhtTxPrepareFuture.java |   2 +-
 .../GridDhtUnreservedPartitionException.java|  66 +++
 .../dht/atomic/GridDhtAtomicCache.java  |   3 +-
 .../dht/atomic/GridNearAtomicUpdateFuture.java  |  63 ++-
 .../near/GridNearOptimisticTxPrepareFuture.java |   2 +-
 .../local/atomic/GridLocalAtomicCache.java  |   3 +-
 .../cache/query/GridCacheQueryAdapter.java  |  56 +-
 .../cache/query/GridCacheQueryManager.java  |  71 ++-
 .../cache/transactions/IgniteTxAdapter.java |  16 +-
 .../cache/transactions/IgniteTxEntry.java   |  16 +-
 .../transactions/IgniteTxLocalAdapter.java  |  83 ++-
 .../cache/version/GridCacheVersion.java |   2 +-
 .../cache/version/GridCacheVersionAware.java|  30 +
 .../cache/version/GridCacheVersionManager.java  |   5 +-
 .../clock/GridClockSyncProcessor.java   |   2 +-
 .../continuous/GridContinuousProcessor.java |  60 +-
 .../ignite/internal/util/GridArgumentCheck.java |  17 +
 .../ignite/internal/util/nio/GridNioServer.java |   4 +-
 .../ignite/spi/discovery/tcp/ServerImpl.java|  83 ++-
 .../spi/discovery/tcp/TcpDiscoveryImpl.java |   4 +-
 .../spi/discovery/tcp/TcpDiscoverySpi.java  |  49 +-
 .../tcp/internal/TcpDiscoveryNode.java  |  18 +-
 .../tcp/internal/TcpDiscoveryNodesRing.java |  23 +
 .../resources/META-INF/classnames.properties|   3 +-
 ...cheDhtLocalPartitionAfterRemoveSelfTest.java |  33 +-
 .../cache/GridCacheAbstractFullApiSelfTest.java |   1 -
 .../processors/cache/GridCacheTestEntryEx.java  |   2 +-
 .../IgniteCacheSizeFailoverTest.java| 115 
 .../IgniteCachePutRetryAbstractSelfTest.java| 120 +++-
 ...PutRetryAtomicPrimaryWriteOrderSelfTest.java |  32 ++
 ...ridCacheContinuousQueryAbstractSelfTest.java |   2 +-
 .../IgniteCacheContinuousQueryClientTest.java   | 137 +
 .../CacheVersionedEntryAbstractTest.java| 170 ++
 ...nedEntryLocalAtomicSwapDisabledSelfTest.java |  45 ++
 ...ersionedEntryLocalTransactionalSelfTest.java |  40 ++
 ...edEntryPartitionedAtomicOffHeapSelfTest.java |  35 ++
 ...VersionedEntryPartitionedAtomicSelfTest.java |  35 ++
 ...PartitionedTransactionalOffHeapSelfTest.java |  36 ++
 ...edEntryPartitionedTransactionalSelfTest.java |  35 ++
 ...nedEntryReplicatedAtomicOffHeapSelfTest.java |  35 ++
 ...eVersionedEntryReplicatedAtomicSelfTest.java |  35 ++
 ...yReplicatedTransactionalOffHeapSelfTest.java |  36 ++
 ...nedEntryReplicatedTransactionalSelfTest.java |  35 ++
 .../continuous/GridEventConsumeSelfTest.java|   4 +-
 .../tcp/IgniteCacheSslStartStopSelfTest.java|   1 +
 .../spi/discovery/tcp/TcpDiscoverySelfTest.java | 152 -
 .../TcpDiscoverySpiFailureTimeoutSelfTest.java  |   8 +-
 .../IgniteCacheFailoverTestSuite.java   |   3 +
 .../testsuites/IgniteCacheTestSuite2.java   |   1 +
 .../testsuites/IgniteCacheTestSuite4.java   |  13 +
 .../query/h2/sql/GridSqlQuerySplitter.java  |   3 +
 .../query/h2/twostep/GridMergeTable.java|   7 +-
 .../query/h2/twostep/GridThreadLocalTable.java  |  22 +-
 ...CacheScanPartitionQueryFallbackSelfTest.java |  96 
 .../query/IgniteSqlSplitterSelfTest.java| 152 +
 .../IgniteCacheQuerySelfTestSuite.java  |   3 +
 modules/jms11/pom.xml   |  98 
 .../apache/ignite/stream/jms11/JmsStreamer.java | 524 ++
 .../ignite/stream/jms11/MessageTransformer.java |  43 ++

[10/50] incubator-ignite git commit: ignite-946: fixed review notes

2015-08-19 Thread vozerov
ignite-946: fixed review 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/911ffbb5
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/911ffbb5
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/911ffbb5

Branch: refs/heads/ignite-gg-9615-1
Commit: 911ffbb5de261d662a915677b99cae4a160407eb
Parents: 9f16eb1
Author: Denis Magda 
Authored: Mon Aug 10 11:39:44 2015 +0300
Committer: Denis Magda 
Committed: Mon Aug 10 11:39:44 2015 +0300

--
 .../ignite/cache/version/VersionedEntry.java|  2 +-
 .../processors/cache/CacheEntryImpl0.java   |  4 +-
 .../processors/cache/GridCacheMapEntry.java |  2 +-
 .../processors/cache/GridCacheSwapManager.java  | 88 
 .../cache/transactions/IgniteTxAdapter.java |  2 +
 .../cache/transactions/IgniteTxEntry.java   |  2 +-
 .../transactions/IgniteTxLocalAdapter.java  |  8 ++
 .../cache/version/GridCacheVersionAware.java| 30 +++
 .../cache/version/GridVersionedMapEntry.java| 33 
 .../CacheVersionedEntryAbstractTest.java|  2 +-
 10 files changed, 99 insertions(+), 74 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/911ffbb5/modules/core/src/main/java/org/apache/ignite/cache/version/VersionedEntry.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/cache/version/VersionedEntry.java
 
b/modules/core/src/main/java/org/apache/ignite/cache/version/VersionedEntry.java
index e669f15..2c0879b 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/cache/version/VersionedEntry.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/cache/version/VersionedEntry.java
@@ -56,7 +56,7 @@ public interface VersionedEntry extends Cache.Entry {
 /**
  * Versions comparator.
  */
-public static final Comparator VERSIONS_COMPARATOR = new 
Comparator() {
+public static final Comparator VER_COMP = new 
Comparator() {
 @Override public int compare(VersionedEntry o1, VersionedEntry o2) {
 int res = Integer.compare(o1.topologyVersion(), 
o2.topologyVersion());
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/911ffbb5/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheEntryImpl0.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheEntryImpl0.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheEntryImpl0.java
index a5e27d6..987fbd3 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheEntryImpl0.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheEntryImpl0.java
@@ -52,8 +52,8 @@ public class CacheEntryImpl0 implements Cache.Entry {
 @Override public  T unwrap(Class cls) {
 if(cls.isAssignableFrom(getClass()))
 return cls.cast(this);
-else if (cls.isAssignableFrom(VersionedEntry.class) && e instanceof 
GridVersionedMapEntry)
-return (T)new CacheVersionedEntryImpl<>(e.getKey(), e.getValue(), 
((GridVersionedMapEntry)e).version());
+else if (cls.isAssignableFrom(VersionedEntry.class) && e instanceof 
GridCacheVersionAware)
+return (T)new CacheVersionedEntryImpl<>(e.getKey(), e.getValue(), 
((GridCacheVersionAware)e).version());
 
 throw new IllegalArgumentException("Unwrapping to class is not 
supported: " + cls);
 }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/911ffbb5/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
index 43cf2fe..298f7a6 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
@@ -1385,7 +1385,7 @@ public abstract class GridCacheMapEntry extends 
GridMetadataAwareAdapter impleme
 
 assert entryProcessor != null;
 
-CacheInvokeEntry entry = new 
CacheInvokeEntry<>(cctx, key, old, this.ver);
+CacheInvokeEntry entry = new 
CacheInvokeEntry<>(cctx, key, old, version());
 
 try {
 Object computed = entryProcessor.process(entry, 
invokeArgs);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/911ffbb5/modules/

[15/50] incubator-ignite git commit: 1.3.3-p1-SNAPSHOT

2015-08-19 Thread vozerov
1.3.3-p1-SNAPSHOT


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 834b34765fac4cb87d9d8f4bdb39c14a9e61275d
Parents: 7d747d2
Author: Ignite Teamcity 
Authored: Tue Aug 11 10:53:58 2015 +0300
Committer: Ignite Teamcity 
Committed: Tue Aug 11 10:53:58 2015 +0300

--
 examples/pom.xml   | 2 +-
 modules/aop/pom.xml| 2 +-
 modules/apache-license-gen/pom.xml | 2 +-
 modules/aws/pom.xml| 2 +-
 modules/clients/pom.xml| 2 +-
 modules/cloud/pom.xml  | 2 +-
 modules/codegen/pom.xml| 2 +-
 modules/core/pom.xml   | 2 +-
 modules/core/src/main/resources/ignite.properties  | 2 +-
 modules/extdata/p2p/pom.xml| 2 +-
 modules/extdata/uri/modules/uri-dependency/pom.xml | 2 +-
 modules/extdata/uri/pom.xml| 2 +-
 modules/gce/pom.xml| 2 +-
 modules/geospatial/pom.xml | 2 +-
 modules/hadoop/pom.xml | 2 +-
 modules/hibernate/pom.xml  | 2 +-
 modules/indexing/pom.xml   | 2 +-
 modules/jcl/pom.xml| 2 +-
 modules/jta/pom.xml| 2 +-
 modules/kafka/pom.xml  | 2 +-
 modules/log4j/pom.xml  | 2 +-
 modules/mesos/pom.xml  | 2 +-
 modules/rest-http/pom.xml  | 2 +-
 modules/scalar-2.10/pom.xml| 2 +-
 modules/scalar/pom.xml | 2 +-
 modules/schedule/pom.xml   | 2 +-
 modules/schema-import/pom.xml  | 2 +-
 modules/slf4j/pom.xml  | 2 +-
 modules/spark-2.10/pom.xml | 2 +-
 modules/spark/pom.xml  | 2 +-
 modules/spring/pom.xml | 2 +-
 modules/ssh/pom.xml| 2 +-
 modules/tools/pom.xml  | 2 +-
 modules/urideploy/pom.xml  | 2 +-
 modules/visor-console-2.10/pom.xml | 2 +-
 modules/visor-console/pom.xml  | 2 +-
 modules/visor-plugins/pom.xml  | 2 +-
 modules/web/pom.xml| 2 +-
 modules/yardstick/pom.xml  | 2 +-
 modules/yarn/pom.xml   | 2 +-
 pom.xml| 2 +-
 41 files changed, 41 insertions(+), 41 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/834b3476/examples/pom.xml
--
diff --git a/examples/pom.xml b/examples/pom.xml
index 1338a18..014cb0a 100644
--- a/examples/pom.xml
+++ b/examples/pom.xml
@@ -28,7 +28,7 @@
 
 
 ignite-examples
-1.3.3-SNAPSHOT
+1.3.3-p1-SNAPSHOT
 
 
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/834b3476/modules/aop/pom.xml
--
diff --git a/modules/aop/pom.xml b/modules/aop/pom.xml
index 194ffab..1983567 100644
--- a/modules/aop/pom.xml
+++ b/modules/aop/pom.xml
@@ -31,7 +31,7 @@
 
 
 ignite-aop
-1.3.3-SNAPSHOT
+1.3.3-p1-SNAPSHOT
 
 
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/834b3476/modules/apache-license-gen/pom.xml
--
diff --git a/modules/apache-license-gen/pom.xml 
b/modules/apache-license-gen/pom.xml
index 11259a5..c723729 100644
--- a/modules/apache-license-gen/pom.xml
+++ b/modules/apache-license-gen/pom.xml
@@ -31,5 +31,5 @@
 
 org.apache.ignite
 ignite-apache-license-gen
-1.3.3-SNAPSHOT
+1.3.3-p1-SNAPSHOT
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/834b3476/modules/aws/pom.xml
--
diff --git a/modules/aws/pom.xml b/modules/aws/pom.xml
index 37f6250..1f92999 100644
--- a/modules/aws/pom.xml
+++ b/modules/aws/pom.xml
@@ -31,7 +31,7 @@
 
 
 ignite-aws
-1.3.3-SNAPSHOT
+1.3.3-p1-SNAPSHOT
 
 
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/834b3476/modules/clients/pom.xml
-

[03/50] incubator-ignite git commit: ignite-946: formatting fixes

2015-08-19 Thread vozerov
ignite-946: formatting fixes


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 26144dc4f845af7533cc645d898202b80c0a29f6
Parents: 4928d99
Author: Denis Magda 
Authored: Fri Jul 31 12:18:58 2015 +0300
Committer: nikolay_tikhonov 
Committed: Fri Jul 31 15:49:13 2015 +0300

--
 .../processors/cache/GridCacheMapEntry.java | 20 ++--
 1 file changed, 10 insertions(+), 10 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/26144dc4/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
index 45ff619..ebcb908 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
@@ -609,16 +609,16 @@ public abstract class GridCacheMapEntry extends 
GridMetadataAwareAdapter impleme
 @Nullable IgniteCacheExpiryPolicy expirePlc)
 throws IgniteCheckedException, GridCacheEntryRemovedException {
 return innerGet0(tx,
- readSwap,
- readThrough,
- evt,
- unmarshal,
- updateMetrics,
- tmp,
- subjId,
- transformClo,
- taskName,
- expirePlc);
+readSwap,
+readThrough,
+evt,
+unmarshal,
+updateMetrics,
+tmp,
+subjId,
+transformClo,
+taskName,
+expirePlc);
 }
 
 /** {@inheritDoc} */



[11/50] incubator-ignite git commit: ignite-946: fixed comments and bugs

2015-08-19 Thread vozerov
ignite-946: fixed comments and bugs


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

Branch: refs/heads/ignite-gg-9615-1
Commit: c1582fc32884cdf9494df32fb33207d64ed1230f
Parents: 911ffbb
Author: Denis Magda 
Authored: Mon Aug 10 12:44:31 2015 +0300
Committer: Denis Magda 
Committed: Mon Aug 10 12:44:31 2015 +0300

--
 .../ignite/cache/version/VersionedEntry.java   | 17 +
 .../cache/version/CacheVersionedEntryImpl.java |  4 ++--
 .../processors/clock/GridClockSyncProcessor.java   |  2 +-
 .../version/CacheVersionedEntryAbstractTest.java   |  2 +-
 4 files changed, 13 insertions(+), 12 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/c1582fc3/modules/core/src/main/java/org/apache/ignite/cache/version/VersionedEntry.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/cache/version/VersionedEntry.java
 
b/modules/core/src/main/java/org/apache/ignite/cache/version/VersionedEntry.java
index 2c0879b..1aac68a 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/cache/version/VersionedEntry.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/cache/version/VersionedEntry.java
@@ -73,30 +73,31 @@ public interface VersionedEntry extends 
Cache.Entry {
 };
 
 /**
- * Gets entry's topology version.
+ * Gets the topology version at the time when the entry with a given pair 
of key and value has been created.
  *
  * @return Topology version plus number of seconds from the start time of 
the first grid node.
  */
 public int topologyVersion();
 
 /**
- * Gets entry's order.
+ * Gets versioned entry unique order.
+ * Each time a cache entry for a given key is updated a new {@code 
VersionedEntry} with increased order is created.
  *
- * @return Version order.
+ * @return Versioned entry unique order.
  */
 public long order();
 
 /**
- * Gets entry's node order.
+ * Gets local node order at the time when the entry with a given pair of 
key and value has been created.
  *
- * @return Node order on which this version was assigned.
+ * @return Local node order on which this version has been assigned.
  */
 public int nodeOrder();
 
 /**
- * Gets entry's global time.
+ * Gets the time when the entry with a given pair of key and value has 
been created.
  *
- * @return Adjusted time.
+ * @return Time in milliseconds.
  */
-public long globalTime();
+public long creationTime();
 }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/c1582fc3/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/version/CacheVersionedEntryImpl.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/version/CacheVersionedEntryImpl.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/version/CacheVersionedEntryImpl.java
index 924eff9..74e4a9a 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/version/CacheVersionedEntryImpl.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/version/CacheVersionedEntryImpl.java
@@ -74,7 +74,7 @@ public class CacheVersionedEntryImpl extends 
CacheEntryImpl implemen
 }
 
 /** {@inheritDoc} */
-@Override public long globalTime() {
+@Override public long creationTime() {
 return ver.globalTime();
 }
 
@@ -95,6 +95,6 @@ public class CacheVersionedEntryImpl extends 
CacheEntryImpl implemen
 /** {@inheritDoc} */
 public String toString() {
 return "VersionedEntry [key=" + getKey() + ", val=" + getValue() + ", 
topVer=" + ver.topologyVersion() +
-", nodeOrder=" + ver.nodeOrder() + ", order=" + ver.order() + ", 
globalTime=" + ver.globalTime() + ']';
+", nodeOrder=" + ver.nodeOrder() + ", order=" + ver.order() + ", 
creationTime=" + ver.globalTime() + ']';
 }
 }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/c1582fc3/modules/core/src/main/java/org/apache/ignite/internal/processors/clock/GridClockSyncProcessor.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/clock/GridClockSyncProcessor.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/clock/GridClockSyncProcessor.java
index 3ac44f2..69b07b3 100644
--- 
a/modules/core/src/main/jav

[39/50] incubator-ignite git commit: ignite-534 - IgniteJmsStreamer implemented. Closes #14.

2015-08-19 Thread vozerov
ignite-534 - IgniteJmsStreamer implemented. Closes #14.


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 0d701127c8a95a30f4c484247e84ab1f10f95e3a
Parents: d0536dc
Author: Raul Kripalani 
Authored: Fri Aug 14 16:11:19 2015 -0700
Committer: Valentin Kulichenko 
Committed: Fri Aug 14 16:11:19 2015 -0700

--
 .../ignite/internal/util/GridArgumentCheck.java |  17 +
 modules/jms11/pom.xml   |  98 
 .../apache/ignite/stream/jms11/JmsStreamer.java | 524 ++
 .../ignite/stream/jms11/MessageTransformer.java |  43 ++
 .../stream/jms11/IgniteJmsStreamerTest.java | 551 +++
 .../jms11/IgniteJmsStreamerTestSuite.java   |  34 ++
 .../ignite/stream/jms11/TestTransformers.java   | 123 +
 pom.xml |   1 +
 8 files changed, 1391 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0d701127/modules/core/src/main/java/org/apache/ignite/internal/util/GridArgumentCheck.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/util/GridArgumentCheck.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/util/GridArgumentCheck.java
index b94bae6..8289f90 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/util/GridArgumentCheck.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/util/GridArgumentCheck.java
@@ -35,6 +35,9 @@ public class GridArgumentCheck {
 /** Not empty argument error message suffix. */
 private static final String NOT_EMPTY_SUFFIX = " must not be empty.";
 
+/** Not null or empty error message suffix. */
+private static final String NOT_NULL_OR_EMPTY_SUFFIX = " must not be null 
or empty.";
+
 /**
  * Checks if given argument value is not {@code null}. Otherwise - throws 
{@link NullPointerException}.
  *
@@ -145,4 +148,18 @@ public class GridArgumentCheck {
 if (arr.length == 0)
 throw new IllegalArgumentException(INVALID_ARG_MSG_PREFIX + name + 
NOT_EMPTY_SUFFIX);
 }
+
+/**
+ * Checks that a String is not null or empty.
+ *
+ * @param value Value to check.
+ * @param name Argument name.
+ */
+public static void notNullOrEmpty(String value, String name) {
+notNull(value, name);
+
+if (value.trim().length() == 0) {
+throw new IllegalArgumentException(INVALID_ARG_MSG_PREFIX + name + 
NOT_NULL_OR_EMPTY_SUFFIX);
+}
+}
 }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0d701127/modules/jms11/pom.xml
--
diff --git a/modules/jms11/pom.xml b/modules/jms11/pom.xml
new file mode 100644
index 000..c93ea9a
--- /dev/null
+++ b/modules/jms11/pom.xml
@@ -0,0 +1,98 @@
+
+
+
+
+
+http://maven.apache.org/POM/4.0.0"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 
http://maven.apache.org/xsd/maven-4.0.0.xsd";>
+4.0.0
+
+
+org.apache.ignite
+ignite-parent
+1
+../../parent
+
+
+ignite-jms11
+1.4.1-SNAPSHOT
+
+
+5.11.1
+
+
+
+
+org.apache.ignite
+ignite-core
+${project.version}
+
+
+
+javax.jms
+jms-api
+1.1-rev-1
+
+
+
+org.apache.activemq
+activemq-client
+${activemq.version}
+test
+
+
+
+org.apache.activemq
+activemq-broker
+${activemq.version}
+test
+
+
+
+org.apache.activemq
+activemq-kahadb-store
+${activemq.version}
+test
+
+
+
+org.apache.ignite
+ignite-log4j
+${project.version}
+test
+
+
+
+org.apache.ignite
+ignite-spring
+${project.version}
+test
+
+
+
+org.apache.ignite
+ignite-core
+${project.version}
+test-jar
+test
+
+
+
+

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0d701127/modules/jms11/src/main/java/org/apache/ignite/stream/jms11/JmsStreamer.java
--
diff --git 
a/modules/jms11/src/main/java/org/apache/ignite/s

[21/50] incubator-ignite git commit: Merge remote-tracking branch 'remotes/origin/master' into ignite-946

2015-08-19 Thread vozerov
Merge remote-tracking branch 'remotes/origin/master' into ignite-946


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 51a9bd85e5cb7cb38fcc60b7adf808fe0545e7df
Parents: 4f8f32a 36f7ba6
Author: Denis Magda 
Authored: Thu Aug 13 09:12:26 2015 +0300
Committer: Denis Magda 
Committed: Thu Aug 13 09:12:26 2015 +0300

--
 .../processors/cache/GridCacheGateway.java  |  5 +-
 .../ignite/spi/discovery/tcp/ServerImpl.java| 91 +---
 2 files changed, 62 insertions(+), 34 deletions(-)
--




[24/50] incubator-ignite git commit: When NIO server port is set to -1, we do not need to check address for null.

2015-08-19 Thread vozerov
When NIO server port is set to -1, we do not need to check address for null.


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 7290d0658aa10675095f1a0379f5c21b9bb09bc4
Parents: aed83af
Author: vozerov-gridgain 
Authored: Thu Aug 13 18:09:54 2015 +0300
Committer: vozerov-gridgain 
Committed: Thu Aug 13 18:09:54 2015 +0300

--
 .../java/org/apache/ignite/internal/util/nio/GridNioServer.java  | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/7290d065/modules/core/src/main/java/org/apache/ignite/internal/util/nio/GridNioServer.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/util/nio/GridNioServer.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/util/nio/GridNioServer.java
index c180837..2d60f98 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/util/nio/GridNioServer.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/util/nio/GridNioServer.java
@@ -209,7 +209,9 @@ public class GridNioServer {
 IgniteBiInClosure msgQueueLsnr,
 GridNioFilter... filters
 ) throws IgniteCheckedException {
-A.notNull(addr, "addr");
+if (port != -1)
+A.notNull(addr, "addr");
+
 A.notNull(lsnr, "lsnr");
 A.notNull(log, "log");
 A.notNull(order, "order");



[18/50] incubator-ignite git commit: Fixed error message

2015-08-19 Thread vozerov
Fixed error message


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 653c0b28d340a37893741b0d381a63330732fd10
Parents: d5986c2
Author: Valentin Kulichenko 
Authored: Wed Aug 12 16:54:47 2015 -0700
Committer: Valentin Kulichenko 
Committed: Wed Aug 12 16:54:47 2015 -0700

--
 .../ignite/internal/processors/cache/GridCacheGateway.java  | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/653c0b28/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheGateway.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheGateway.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheGateway.java
index a3c8da6..93c5858 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheGateway.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheGateway.java
@@ -156,8 +156,7 @@ public class GridCacheGateway {
 GridCachePreloader preldr = cache != null ? cache.preloader() : 
null;
 
 if (preldr == null)
-throw new IllegalStateException("Grid is in invalid state to 
perform this operation. " +
-"It either not started yet or has already being or have 
stopped [gridName=" + ctx.gridName() + ']');
+throw new IllegalStateException("Cache has been closed: " + 
ctx.name());
 
 preldr.startFuture().get();
 }
@@ -177,7 +176,7 @@ public class GridCacheGateway {
 try {
 return setOperationContextPerCall(opCtx);
 }
-catch (RuntimeException e) {
+catch (Throwable e) {
 rwLock.readUnlock();
 
 throw e;



[49/50] incubator-ignite git commit: Exception handling

2015-08-19 Thread vozerov
Exception handling


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 09da9c2a369b52b06fe9312aafd19f1085ba79d2
Parents: fcd9d61
Author: Valentin Kulichenko 
Authored: Mon Aug 17 23:44:59 2015 -0700
Committer: Valentin Kulichenko 
Committed: Mon Aug 17 23:44:59 2015 -0700

--
 .../ignite/cache/store/jdbc/CacheJdbcPojoStoreFactory.java   | 2 +-
 .../ignite/internal/util/spring/IgniteSpringHelperImpl.java  | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/09da9c2a/modules/core/src/main/java/org/apache/ignite/cache/store/jdbc/CacheJdbcPojoStoreFactory.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/cache/store/jdbc/CacheJdbcPojoStoreFactory.java
 
b/modules/core/src/main/java/org/apache/ignite/cache/store/jdbc/CacheJdbcPojoStoreFactory.java
index ac1f4f1..5449433 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/cache/store/jdbc/CacheJdbcPojoStoreFactory.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/cache/store/jdbc/CacheJdbcPojoStoreFactory.java
@@ -98,7 +98,7 @@ public class CacheJdbcPojoStoreFactory implements 
Factoryhttp://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/09da9c2a/modules/spring/src/main/java/org/apache/ignite/internal/util/spring/IgniteSpringHelperImpl.java
--
diff --git 
a/modules/spring/src/main/java/org/apache/ignite/internal/util/spring/IgniteSpringHelperImpl.java
 
b/modules/spring/src/main/java/org/apache/ignite/internal/util/spring/IgniteSpringHelperImpl.java
index 435f522..d65a199 100644
--- 
a/modules/spring/src/main/java/org/apache/ignite/internal/util/spring/IgniteSpringHelperImpl.java
+++ 
b/modules/spring/src/main/java/org/apache/ignite/internal/util/spring/IgniteSpringHelperImpl.java
@@ -201,11 +201,11 @@ public class IgniteSpringHelperImpl implements 
IgniteSpringHelper {
 }
 catch (NoSuchBeanDefinitionException e) {
 throw new IgniteCheckedException("Spring bean with provided name 
doesn't exist " +
-", beanName=" + beanName + ']');
+", beanName=" + beanName + ']');
 }
 catch (BeansException e) {
 throw new IgniteCheckedException("Failed to load Spring bean with 
provided name " +
-", beanName=" + beanName + ']', e);
+", beanName=" + beanName + ']', e);
 }
 }
 



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

2015-08-19 Thread vozerov
review


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 53557e327721fee683b9b37217d530db44166aec
Parents: fe2be79
Author: Yakov Zhdanov 
Authored: Wed Aug 5 10:15:52 2015 +0300
Committer: Yakov Zhdanov 
Committed: Wed Aug 5 10:15:52 2015 +0300

--
 .../processors/cache/transactions/IgniteTxLocalAdapter.java| 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/53557e32/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 e03f34d..a209780 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
@@ -1937,7 +1937,7 @@ public abstract class IgniteTxLocalAdapter extends 
IgniteTxAdapter
 GridCacheContext cacheCtx,
 Map drMap
 ) {
-return putAllAsync0(cacheCtx,
+return this.putAllAsync0(cacheCtx,
 null,
 null,
 null,



[14/50] incubator-ignite git commit: Merge remote-tracking branch 'remotes/origin/master' into ignite-946

2015-08-19 Thread vozerov
Merge remote-tracking branch 'remotes/origin/master' into ignite-946


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 801d6df1acd2615c1a85e9e3829983011b5fd0a3
Parents: b6bef13 ae11e9b
Author: Denis Magda 
Authored: Tue Aug 11 10:19:21 2015 +0300
Committer: Denis Magda 
Committed: Tue Aug 11 10:19:21 2015 +0300

--
 .../configuration/IgniteConfiguration.java  |  1 -
 .../GridCachePartitionExchangeManager.java  | 48 +++
 .../dht/atomic/GridDhtAtomicCache.java  | 36 +---
 .../cache/CacheStopAndDestroySelfTest.java  | 87 
 4 files changed, 56 insertions(+), 116 deletions(-)
--


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



[20/50] incubator-ignite git commit: ignite-946: renamed VersionedEntry to CacheEntry

2015-08-19 Thread vozerov
ignite-946: renamed VersionedEntry to CacheEntry


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 4f8f32af80d2c13df3fd8d3c5b302c0fd04906c5
Parents: 954c459
Author: Denis Magda 
Authored: Thu Aug 13 09:10:45 2015 +0300
Committer: Denis Magda 
Committed: Thu Aug 13 09:10:45 2015 +0300

--
 .../org/apache/ignite/cache/CacheEntry.java | 94 
 .../ignite/cache/version/VersionedEntry.java| 92 ---
 .../ignite/cache/version/package-info.java  | 21 -
 .../processors/cache/CacheEntryImpl.java|  6 +-
 .../processors/cache/CacheEntryImpl0.java   |  6 +-
 .../processors/cache/CacheEntryImplEx.java  | 83 +
 .../processors/cache/CacheInvokeEntry.java  |  6 +-
 .../processors/cache/GridCacheEntryEx.java  |  2 +-
 .../processors/cache/GridCacheMapEntry.java | 12 +--
 .../cache/version/CacheVersionedEntryImpl.java  | 83 -
 .../resources/META-INF/classnames.properties|  3 +-
 .../processors/cache/GridCacheTestEntryEx.java  |  2 +-
 .../CacheVersionedEntryAbstractTest.java| 27 +++---
 13 files changed, 209 insertions(+), 228 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/4f8f32af/modules/core/src/main/java/org/apache/ignite/cache/CacheEntry.java
--
diff --git a/modules/core/src/main/java/org/apache/ignite/cache/CacheEntry.java 
b/modules/core/src/main/java/org/apache/ignite/cache/CacheEntry.java
new file mode 100644
index 000..a6a2aa3
--- /dev/null
+++ b/modules/core/src/main/java/org/apache/ignite/cache/CacheEntry.java
@@ -0,0 +1,94 @@
+/*
+ * 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.cache;
+
+import org.apache.ignite.*;
+
+import javax.cache.*;
+import javax.cache.processor.*;
+import java.util.*;
+
+/**
+ * Cache entry that extends {@link javax.cache.Cache.Entry} by providing 
additional entry related information.
+ *
+ * To get an instance of {@code CacheEntry} use {@link 
javax.cache.Cache.Entry#unwrap(Class)} method by passing
+ * {@code CacheEntry} class to it as the argument.
+ * 
+ * {@code CacheEntry} is supported only for {@link javax.cache.Cache.Entry} 
returned by one of the following methods:
+ * 
+ * {@link javax.cache.Cache#invoke(Object, EntryProcessor, Object...)}
+ * {@link javax.cache.Cache#invokeAll(Set, EntryProcessor, Object...)}
+ * invoke and invokeAll methods of {@link IgniteCache}
+ * {@link IgniteCache#randomEntry()}
+ * 
+ * 
+ * {@code CacheEntry} is not supported for {@link 
javax.cache.Cache#iterator()} because of performance reasons.
+ * {@link javax.cache.Cache#iterator()} loads entries from all the cluster 
nodes and to speed up the load additional
+ * information, like entry's version, is ignored.
+ *
+ * Java Example
+ * 
+ * IgniteCache cache = grid(0).cache(null);
+ *
+ * CacheEntry entry1 = cache.invoke(100,
+ * new EntryProcessor>() {
+ *  public CacheEntry process(MutableEntry entry,
+ *  Object... arguments) throws EntryProcessorException {
+ *  return entry.unwrap(CacheEntry.class);
+ *  }
+ * });
+ *
+ * // Cache entry for the given key may be updated at some point later.
+ *
+ * CacheEntry entry2 = cache.invoke(100,
+ * new EntryProcessor>() {
+ *  public CacheEntry process(MutableEntry entry,
+ *  Object... arguments) throws EntryProcessorException {
+ *  return entry.unwrap(CacheEntry.class);
+ *  }
+ * });
+ *
+ * // Comparing entries' versions.
+ * if (entry1.version().compareTo(entry2.version()) < 0) {
+ * // the entry has been updated
+ * }
+ * 
+ */
+public interface CacheEntry extends Cache.Entry {
+/**
+ * Returns a comparab

[32/50] incubator-ignite git commit: Merge remote-tracking branch 'origin/ignite-1.3.3-p2' into ignite-1.3.3-p2

2015-08-19 Thread vozerov
Merge remote-tracking branch 'origin/ignite-1.3.3-p2' into ignite-1.3.3-p2


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 47895da65c84e3c51a0eeb6c526d424ea9fabf41
Parents: a3301b3 9300bbc
Author: sboikov 
Authored: Fri Aug 14 11:39:04 2015 +0300
Committer: sboikov 
Committed: Fri Aug 14 11:39:04 2015 +0300

--
 examples/pom.xml   | 2 +-
 modules/aop/pom.xml| 2 +-
 modules/apache-license-gen/pom.xml | 2 +-
 modules/aws/pom.xml| 2 +-
 modules/clients/pom.xml| 2 +-
 modules/cloud/pom.xml  | 2 +-
 modules/codegen/pom.xml| 2 +-
 modules/core/pom.xml   | 2 +-
 modules/core/src/main/resources/ignite.properties  | 2 +-
 modules/extdata/p2p/pom.xml| 2 +-
 modules/extdata/uri/modules/uri-dependency/pom.xml | 2 +-
 modules/extdata/uri/pom.xml| 2 +-
 modules/gce/pom.xml| 2 +-
 modules/geospatial/pom.xml | 2 +-
 modules/hadoop/pom.xml | 2 +-
 modules/hibernate/pom.xml  | 2 +-
 modules/indexing/pom.xml   | 2 +-
 modules/jcl/pom.xml| 2 +-
 modules/jta/pom.xml| 2 +-
 modules/kafka/pom.xml  | 2 +-
 modules/log4j/pom.xml  | 2 +-
 modules/mesos/pom.xml  | 2 +-
 modules/rest-http/pom.xml  | 2 +-
 modules/scalar-2.10/pom.xml| 2 +-
 modules/scalar/pom.xml | 2 +-
 modules/schedule/pom.xml   | 2 +-
 modules/schema-import/pom.xml  | 2 +-
 modules/slf4j/pom.xml  | 2 +-
 modules/spark-2.10/pom.xml | 2 +-
 modules/spark/pom.xml  | 2 +-
 modules/spring/pom.xml | 2 +-
 modules/ssh/pom.xml| 2 +-
 modules/tools/pom.xml  | 2 +-
 modules/urideploy/pom.xml  | 2 +-
 modules/visor-console-2.10/pom.xml | 2 +-
 modules/visor-console/pom.xml  | 2 +-
 modules/visor-plugins/pom.xml  | 2 +-
 modules/web/pom.xml| 2 +-
 modules/yardstick/pom.xml  | 2 +-
 modules/yarn/pom.xml   | 2 +-
 pom.xml| 2 +-
 41 files changed, 41 insertions(+), 41 deletions(-)
--




[12/50] incubator-ignite git commit: ignite-946: renamed topologyVersion to topologyOrder for GridCacheVersion

2015-08-19 Thread vozerov
ignite-946: renamed topologyVersion to topologyOrder for GridCacheVersion


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

Branch: refs/heads/ignite-gg-9615-1
Commit: dd3cecf6a68deec93c084af2f7d7e1be9de9f877
Parents: c1582fc
Author: Denis Magda 
Authored: Tue Aug 11 09:02:00 2015 +0300
Committer: Denis Magda 
Committed: Tue Aug 11 09:02:00 2015 +0300

--
 .../cache/GridCacheAtomicVersionComparator.java |  4 +--
 .../processors/cache/GridCacheMapEntry.java |  2 +-
 .../processors/cache/GridCacheUtils.java|  2 +-
 .../cache/transactions/IgniteTxManager.java |  2 +-
 .../cache/version/CacheVersionedEntryImpl.java  |  4 +--
 .../version/GridCachePlainVersionedEntry.java   |  2 +-
 .../version/GridCacheRawVersionedEntry.java |  2 +-
 .../cache/version/GridCacheVersion.java | 28 ++--
 .../cache/version/GridCacheVersionManager.java  |  5 ++--
 .../ignite/internal/util/IgniteUtils.java   |  4 +--
 .../cache/GridCacheEntryVersionSelfTest.java|  4 +--
 11 files changed, 29 insertions(+), 30 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/dd3cecf6/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAtomicVersionComparator.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAtomicVersionComparator.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAtomicVersionComparator.java
index 3a06100..45288d9 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAtomicVersionComparator.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAtomicVersionComparator.java
@@ -32,8 +32,8 @@ public class GridCacheAtomicVersionComparator {
  * @return Comparison value.
  */
 public int compare(GridCacheVersion one, GridCacheVersion other, boolean 
ignoreTime) {
-int topVer = one.topologyVersion();
-int otherTopVer = other.topologyVersion();
+int topVer = one.topologyOrder();
+int otherTopVer = other.topologyOrder();
 
 if (topVer == otherTopVer) {
 long globalTime = one.globalTime();

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/dd3cecf6/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
index 298f7a6..33c42c4 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
@@ -1927,7 +1927,7 @@ public abstract class GridCacheMapEntry extends 
GridMetadataAwareAdapter impleme
 
 // Incorporate conflict version into new version if needed.
 if (conflictVer != null && conflictVer != newVer)
-newVer = new GridCacheVersionEx(newVer.topologyVersion(),
+newVer = new GridCacheVersionEx(newVer.topologyOrder(),
 newVer.globalTime(),
 newVer.order(),
 newVer.nodeOrder(),

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/dd3cecf6/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
index a313e3d..75f1dee 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
@@ -1060,7 +1060,7 @@ public class GridCacheUtils {
 
 byte[] bytes = new byte[28];
 
-U.intToBytes(ver.topologyVersion(), bytes, 0);
+U.intToBytes(ver.topologyOrder(), bytes, 0);
 U.longToBytes(ver.globalTime(), bytes, 4);
 U.longToBytes(ver.order(), bytes, 12);
 U.intToBytes(ver.nodeOrderAndDrIdRaw(), bytes, 20);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/dd3cecf6/modules/core/src/main/java/org/ap

[34/50] incubator-ignite git commit: # Wait for next topology version before retry, retries for async tx operations

2015-08-19 Thread vozerov
# Wait for next topology version before retry, retries for async tx operations


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 122a9dbf337d5c1128be32d4efee1e0f1dc683f5
Parents: 47895da
Author: sboikov 
Authored: Fri Aug 14 12:50:06 2015 +0300
Committer: sboikov 
Committed: Fri Aug 14 13:57:19 2015 +0300

--
 .../processors/cache/GridCacheAdapter.java  | 143 +--
 .../dht/atomic/GridNearAtomicUpdateFuture.java  |  25 +++-
 .../IgniteCachePutRetryAbstractSelfTest.java|  94 ++--
 3 files changed, 237 insertions(+), 25 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/122a9dbf/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
index 47ede5b..91af352 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
@@ -2283,8 +2283,7 @@ public abstract class GridCacheAdapter implements 
IgniteInternalCache putAsync(K key, V val,
-  @Nullable 
CacheEntryPredicate... filter) {
+public IgniteInternalFuture putAsync(K key, V val, @Nullable 
CacheEntryPredicate... filter) {
 final boolean statsEnabled = ctx.config().isStatisticsEnabled();
 
 final long start = statsEnabled ? System.nanoTime() : 0L;
@@ -3975,8 +3974,15 @@ public abstract class GridCacheAdapter implements 
IgniteInternalCache 0 
: tx;
+
+
ctx.affinity().affinityReadyFuture(topVer.topologyVersion() + 1).get();
+
 continue;
+}
 
 throw e;
 }
@@ -4014,18 +4020,36 @@ public abstract class GridCacheAdapter implements 
IgniteInternalCache fut = new AsyncOpRetryFuture<>(op, 
skipStore, retries);
+
+fut.execute();
+
+return fut;
+}
+}
+else
+return asyncOp(tx, op);
 }
 
 /**
@@ -4624,6 +4648,97 @@ public abstract class GridCacheAdapter implements 
IgniteInternalCache extends GridFutureAdapter {
+/** */
+private AsyncOp op;
+
+/** */
+private boolean skipStore;
+
+/** */
+private int retries;
+
+/** */
+private IgniteTxLocalAdapter tx;
+
+/**
+ * @param op Operation.
+ * @param skipStore Skip store flag.
+ * @param retries Number of retries.
+ */
+public AsyncOpRetryFuture(AsyncOp op,
+boolean skipStore,
+int retries) {
+assert retries > 1 : retries;
+
+this.op = op;
+this.tx = null;
+this.skipStore = skipStore;
+this.retries = retries;
+}
+
+/**
+ * @param tx Transaction.
+ */
+public void execute() {
+tx = ctx.tm().newTx(
+true,
+op.single(),
+ctx.systemTx() ? ctx : null,
+OPTIMISTIC,
+READ_COMMITTED,
+
ctx.kernalContext().config().getTransactionConfiguration().getDefaultTxTimeout(),
+!skipStore,
+0);
+
+IgniteInternalFuture fut = asyncOp(tx, op);
+
+fut.listen(new IgniteInClosure>() {
+@Override public void apply(IgniteInternalFuture fut) {
+try {
+T res = fut.get();
+
+onDone(res);
+}
+catch (IgniteCheckedException e) {
+if (X.hasCause(e, 
ClusterTopologyCheckedException.class) && --retries > 0) {
+IgniteTxLocalAdapter tx = 
AsyncOpRetryFuture.this.tx;
+
+assert tx != null;
+
+AffinityTopologyVersion topVer = 
tx.topologyVersion();
+
+assert topVer != null && topVer.topologyVersion() 
> 0 : tx;
+
+IgniteInternalFuture topFut =
+
ctx.affinity().affinityReadyFuture(topVer.topologyVersion() + 1);
+
+topFut.listen(new 
IgniteInClosure>() {
+  

[42/50] incubator-ignite git commit: Squashed commit of the IGNITE-1229

2015-08-19 Thread vozerov
Squashed commit of the IGNITE-1229


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

Branch: refs/heads/ignite-gg-9615-1
Commit: 7635e5894df6aab477b82253451b729985f632be
Parents: 1f00c70
Author: Denis Magda 
Authored: Mon Aug 17 16:41:03 2015 +0300
Committer: Yakov Zhdanov 
Committed: Mon Aug 17 16:41:03 2015 +0300

--
 .../ignite/spi/discovery/tcp/ServerImpl.java|  57 ++-
 .../spi/discovery/tcp/TcpDiscoverySpi.java  |  45 --
 .../spi/discovery/tcp/TcpDiscoverySelfTest.java | 152 ++-
 .../TcpDiscoverySpiFailureTimeoutSelfTest.java  |   8 +-
 4 files changed, 245 insertions(+), 17 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/7635e589/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 76144e3..40e110f 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
@@ -114,7 +114,7 @@ class ServerImpl extends TcpDiscoveryImpl {
 protected TcpDiscoverySpiState spiState = DISCONNECTED;
 
 /** Map with proceeding ping requests. */
-private final ConcurrentMap>> pingMap =
+private final ConcurrentMap>> pingMap =
 new ConcurrentHashMap8<>();
 
 /**
@@ -497,9 +497,9 @@ class ServerImpl extends TcpDiscoveryImpl {
 return F.t(getLocalNodeId(), clientPingRes);
 }
 
-GridFutureAdapter> fut = new 
GridFutureAdapter<>();
+GridPingFutureAdapter> fut = new 
GridPingFutureAdapter<>();
 
-IgniteInternalFuture> oldFut = 
pingMap.putIfAbsent(addr, fut);
+GridPingFutureAdapter> oldFut = 
pingMap.putIfAbsent(addr, fut);
 
 if (oldFut != null)
 return oldFut.get();
@@ -520,7 +520,11 @@ class ServerImpl extends TcpDiscoveryImpl {
 
 long tstamp = U.currentTimeMillis();
 
-sock = spi.openSocket(addr, timeoutHelper);
+sock = spi.createSocket();
+
+fut.sock = sock;
+
+sock = spi.openSocket(sock, addr, timeoutHelper);
 
 openedSock = true;
 
@@ -597,6 +601,21 @@ class ServerImpl extends TcpDiscoveryImpl {
 }
 }
 
+/**
+ * Interrupts all existed 'ping' request for the given node.
+ *
+ * @param node Node that may be pinged.
+ */
+private void interruptPing(TcpDiscoveryNode node) {
+for (InetSocketAddress addr : spi.getNodeAddresses(node)) {
+GridPingFutureAdapter fut = pingMap.get(addr);
+
+if (fut != null && fut.sock != null)
+// Reference to the socket is not set to null. No need to 
assign it to a local variable.
+U.closeQuiet(fut.sock);
+}
+}
+
 /** {@inheritDoc} */
 @Override public void disconnect() throws IgniteSpiException {
 spiStop0(true);
@@ -3366,6 +3385,8 @@ class ServerImpl extends TcpDiscoveryImpl {
 if (msg.verified() && !locNodeId.equals(leavingNodeId)) {
 TcpDiscoveryNode leftNode = ring.removeNode(leavingNodeId);
 
+interruptPing(leavingNode);
+
 assert leftNode != null;
 
 if (log.isDebugEnabled())
@@ -3533,6 +3554,8 @@ class ServerImpl extends TcpDiscoveryImpl {
 if (msg.verified()) {
 node = ring.removeNode(nodeId);
 
+interruptPing(node);
+
 assert node != null;
 
 long topVer;
@@ -5142,4 +5165,30 @@ class ServerImpl extends TcpDiscoveryImpl {
 spi.writeToSocket(sock, msg, bout, timeout);
 }
 }
+
+/**
+ *
+ */
+private static class GridPingFutureAdapter extends GridFutureAdapter 
{
+/** Socket. */
+private volatile Socket sock;
+
+/**
+ * Returns socket associated with this ping future.
+ *
+ * @return Socket or {@code null} if no socket associated.
+ */
+public Socket sock() {
+return sock;
+}
+
+/**
+ * Associates socket with this ping future.
+ *
+ * @param sock Socket.
+ */
+public void sock(Socket sock) {
+this.sock = sock;
+}
+}
 }

http://git-wip-us.apache.org/rep

[2/2] incubator-ignite git commit: Merge branches 'ignite-843' and 'master' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-843

2015-08-19 Thread akuznetsov
Merge branches 'ignite-843' and 'master' of 
https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-843


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

Branch: refs/heads/ignite-843
Commit: b4321d895d51009d5a7b22af26a07961404f8806
Parents: eaf880b e9a0d06
Author: Alexey Kuznetsov 
Authored: Wed Aug 19 15:08:20 2015 +0700
Committer: Alexey Kuznetsov 
Committed: Wed Aug 19 15:08:20 2015 +0700

--
 .../parser/dialect/OracleMetadataDialect.java   | 101 ++-
 .../ignite/schema/model/PojoDescriptor.java |   6 +-
 2 files changed, 57 insertions(+), 50 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/b4321d89/modules/schema-import-db/src/main/java/org/apache/ignite/schema/parser/dialect/OracleMetadataDialect.java
--
diff --cc 
modules/schema-import-db/src/main/java/org/apache/ignite/schema/parser/dialect/OracleMetadataDialect.java
index 860ff68,000..30dda5d
mode 100644,00..100644
--- 
a/modules/schema-import-db/src/main/java/org/apache/ignite/schema/parser/dialect/OracleMetadataDialect.java
+++ 
b/modules/schema-import-db/src/main/java/org/apache/ignite/schema/parser/dialect/OracleMetadataDialect.java
@@@ -1,281 -1,0 +1,284 @@@
 +/*
 + * 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.schema.parser.dialect;
 +
 +import org.apache.ignite.schema.parser.*;
 +
 +import java.sql.*;
 +import java.util.*;
 +
 +import static java.sql.Types.*;
 +
 +/**
 + * Oracle specific metadata dialect.
 + */
 +public class OracleMetadataDialect extends DatabaseMetadataDialect {
 +/** SQL to get columns metadata. */
 +private static final String SQL_COLUMNS = "SELECT a.owner, a.table_name, 
a.column_name, a.nullable," +
 +" a.data_type, a.data_precision, a.data_scale " +
 +"FROM all_tab_columns a %s" +
 +" WHERE a.owner = '%s'" +
 +" ORDER BY a.owner, a.table_name, a.column_id";
 +
 +/** SQL to get list of PRIMARY KEYS columns. */
 +private static final String SQL_PRIMARY_KEYS = "SELECT b.column_name" +
 +" FROM all_constraints a" +
 +"  INNER JOIN all_cons_columns b ON a.owner = b.owner AND 
a.constraint_name = b.constraint_name" +
 +" WHERE a.owner = ? and a.table_name = ? AND a.constraint_type = 'P'";
 +
 +/** SQL to get indexes metadata. */
 +private static final String SQL_INDEXES = "SELECT i.index_name, 
u.column_expression, i.column_name, i.descend" +
 +" FROM all_ind_columns i" +
 +" LEFT JOIN user_ind_expressions u on u.index_name = i.index_name and 
i.table_name = u.table_name" +
 +" WHERE i.index_owner = ? and i.table_name = ?" +
 +" ORDER BY i.index_name, i.column_position";
 +
 +/** Owner index. */
 +private static final int OWNER_IDX = 1;
 +
 +/** Table name index. */
 +private static final int TBL_NAME_IDX = 2;
 +
 +/** Column name index. */
 +private static final int COL_NAME_IDX = 3;
 +
 +/** Nullable index. */
 +private static final int NULLABLE_IDX = 4;
 +
 +/** Data type index. */
 +private static final int DATA_TYPE_IDX = 5;
 +
 +/** Numeric precision index. */
 +private static final int DATA_PRECISION_IDX = 6;
 +
 +/** Numeric scale index. */
 +private static final int DATA_SCALE_IDX = 7;
 +
 +/** Index name index. */
 +private static final int IDX_NAME_IDX = 1;
 +
 +/** Index name index. */
 +private static final int IDX_EXPR_IDX = 2;
 +
 +/** Index column name index. */
 +private static final int IDX_COL_NAME_IDX = 3;
 +
 +/** Index column sort order index. */
 +private static final int IDX_COL_DESCEND_IDX = 4;
 +
 +/**
 + * @param rs Result set with column type metadata from Oracle database.
 

[1/2] incubator-ignite git commit: ignite-1263 Fixed timestamp and CLOB type detection. Closes #21.

2015-08-19 Thread akuznetsov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-843 eaf880bb7 -> b4321d895


ignite-1263 Fixed timestamp and CLOB type detection. Closes #21.


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

Branch: refs/heads/ignite-843
Commit: e9a0d06ffa104c0e54e0e95b0af229f7648d22d1
Parents: 09da9c2
Author: Vasiliy Sisko 
Authored: Wed Aug 19 14:33:52 2015 +0700
Committer: Andrey 
Committed: Wed Aug 19 14:33:52 2015 +0700

--
 .../ignite/schema/model/PojoDescriptor.java |   6 +-
 .../parser/dialect/OracleMetadataDialect.java   | 101 ++-
 2 files changed, 57 insertions(+), 50 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/e9a0d06f/modules/schema-import/src/main/java/org/apache/ignite/schema/model/PojoDescriptor.java
--
diff --git 
a/modules/schema-import/src/main/java/org/apache/ignite/schema/model/PojoDescriptor.java
 
b/modules/schema-import/src/main/java/org/apache/ignite/schema/model/PojoDescriptor.java
index 5e1da06..5a4a1fa 100644
--- 
a/modules/schema-import/src/main/java/org/apache/ignite/schema/model/PojoDescriptor.java
+++ 
b/modules/schema-import/src/main/java/org/apache/ignite/schema/model/PojoDescriptor.java
@@ -504,7 +504,11 @@ public class PojoDescriptor {
 case TIMESTAMP:
 return java.sql.Timestamp.class;
 
-// BINARY, VARBINARY, LONGVARBINARY, ARRAY, BLOB, CLOB, NCLOB, 
NULL, DATALINK
+case CLOB:
+case NCLOB:
+return String.class;
+
+// BINARY, VARBINARY, LONGVARBINARY, ARRAY, BLOB, NULL, DATALINK
 // OTHER, JAVA_OBJECT, DISTINCT, STRUCT, REF, ROWID, SQLXML
 default:
 return Object.class;

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/e9a0d06f/modules/schema-import/src/main/java/org/apache/ignite/schema/parser/dialect/OracleMetadataDialect.java
--
diff --git 
a/modules/schema-import/src/main/java/org/apache/ignite/schema/parser/dialect/OracleMetadataDialect.java
 
b/modules/schema-import/src/main/java/org/apache/ignite/schema/parser/dialect/OracleMetadataDialect.java
index 860ff68..30dda5d 100644
--- 
a/modules/schema-import/src/main/java/org/apache/ignite/schema/parser/dialect/OracleMetadataDialect.java
+++ 
b/modules/schema-import/src/main/java/org/apache/ignite/schema/parser/dialect/OracleMetadataDialect.java
@@ -87,73 +87,76 @@ public class OracleMetadataDialect extends 
DatabaseMetadataDialect {
  * @throws SQLException If failed to decode type.
  */
 private int decodeType(ResultSet rs) throws SQLException {
-switch (rs.getString(DATA_TYPE_IDX)) {
-case "CHAR":
-case "NCHAR":
-return CHAR;
+String type = rs.getString(DATA_TYPE_IDX);
 
-case "VARCHAR2":
-case "NVARCHAR2":
-return VARCHAR;
+if (type.startsWith("TIMESTAMP"))
+return TIMESTAMP;
+else {
+switch (type) {
+case "CHAR":
+case "NCHAR":
+return CHAR;
 
-case "LONG":
-return LONGVARCHAR;
+case "VARCHAR2":
+case "NVARCHAR2":
+return VARCHAR;
 
-case "LONG RAW":
-return LONGVARBINARY;
+case "LONG":
+return LONGVARCHAR;
 
-case "FLOAT":
-return FLOAT;
+case "LONG RAW":
+return LONGVARBINARY;
 
-case "NUMBER":
-int precision = rs.getInt(DATA_PRECISION_IDX);
-int scale = rs.getInt(DATA_SCALE_IDX);
+case "FLOAT":
+return FLOAT;
 
-if (scale > 0) {
-if (scale < 4 && precision < 19)
-return FLOAT;
+case "NUMBER":
+int precision = rs.getInt(DATA_PRECISION_IDX);
+int scale = rs.getInt(DATA_SCALE_IDX);
 
-if (scale > 4 || precision > 19)
-return DOUBLE;
+if (scale > 0) {
+if (scale < 4 && precision < 19)
+return FLOAT;
 
-return NUMERIC;
-}
-else {
-if (precision < 1)
-return INTEGER;
+if (scale > 

incubator-ignite git commit: IGNITE-843: Minor changes to "what's next".

2015-08-19 Thread akuznetsov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-843 b4321d895 -> da1751ff6


IGNITE-843: Minor changes to "what's next".


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

Branch: refs/heads/ignite-843
Commit: da1751ff6c3eafbb0c9fc3889c31cf483e998963
Parents: b4321d8
Author: Alexey Kuznetsov 
Authored: Wed Aug 19 15:24:35 2015 +0700
Committer: Alexey Kuznetsov 
Committed: Wed Aug 19 15:24:35 2015 +0700

--
 .../control-center-web/src/main/js/controllers/models/caches.json  | 2 +-
 .../src/main/js/controllers/models/metadata.json   | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/da1751ff/modules/control-center-web/src/main/js/controllers/models/caches.json
--
diff --git 
a/modules/control-center-web/src/main/js/controllers/models/caches.json 
b/modules/control-center-web/src/main/js/controllers/models/caches.json
index 740df17..0636a94 100644
--- a/modules/control-center-web/src/main/js/controllers/models/caches.json
+++ b/modules/control-center-web/src/main/js/controllers/models/caches.json
@@ -11,8 +11,8 @@
 "whatsNextTitle": "What's next:",
 "whatsNextContent": [
   "",
-  "  Continue to Summary",
   "  Continue to Metadata",
+  "  Continue to Summary",
   "  Back to Clusters",
   ""
 ]

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/da1751ff/modules/control-center-web/src/main/js/controllers/models/metadata.json
--
diff --git 
a/modules/control-center-web/src/main/js/controllers/models/metadata.json 
b/modules/control-center-web/src/main/js/controllers/models/metadata.json
index 58a40fa..1c0fb34 100644
--- a/modules/control-center-web/src/main/js/controllers/models/metadata.json
+++ b/modules/control-center-web/src/main/js/controllers/models/metadata.json
@@ -10,8 +10,8 @@
 "whatsNextTitle": "What's next:",
 "whatsNextContent": [
   "",
-  "  Continue to Caches",
   "  Continue to Summary",
+  "  Back to Caches",
   "  Back to Clusters",
   ""
 ]



incubator-ignite git commit: IGNITE-843: Fixed generation of type metadata for cache store.

2015-08-19 Thread akuznetsov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-843 da1751ff6 -> 510139132


IGNITE-843: Fixed generation of type metadata for cache store.


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

Branch: refs/heads/ignite-843
Commit: 510139132d25f826799adbd5061dc70bd4aa97f5
Parents: da1751f
Author: Alexey Kuznetsov 
Authored: Wed Aug 19 16:26:59 2015 +0700
Committer: Alexey Kuznetsov 
Committed: Wed Aug 19 16:26:59 2015 +0700

--
 .../src/main/js/controllers/models/caches.json  |  1 -
 .../src/main/js/routes/generator/xml.js | 15 +-
 .../src/main/js/routes/metadata.js  | 54 +---
 3 files changed, 36 insertions(+), 34 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/51013913/modules/control-center-web/src/main/js/controllers/models/caches.json
--
diff --git 
a/modules/control-center-web/src/main/js/controllers/models/caches.json 
b/modules/control-center-web/src/main/js/controllers/models/caches.json
index 0636a94..a0b3a0c 100644
--- a/modules/control-center-web/src/main/js/controllers/models/caches.json
+++ b/modules/control-center-web/src/main/js/controllers/models/caches.json
@@ -449,7 +449,6 @@
 {
   "label": "Metadata",
   "type": "dropdown-multiple",
-  "path": "cacheStoreFactory.CacheJdbcPojoStoreFactory",
   "model": "storeMetadata",
   "placeholder": "Choose metadata",
   "items": "storeMetadata",

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/51013913/modules/control-center-web/src/main/js/routes/generator/xml.js
--
diff --git a/modules/control-center-web/src/main/js/routes/generator/xml.js 
b/modules/control-center-web/src/main/js/routes/generator/xml.js
index 34f964d..75b590b 100644
--- a/modules/control-center-web/src/main/js/routes/generator/xml.js
+++ b/modules/control-center-web/src/main/js/routes/generator/xml.js
@@ -357,7 +357,7 @@ function addCacheTypeMetadataDatabaseFields(res, meta, 
fieldProperty) {
 
 addProperty(res, field, 'javaName');
 
-addElement(res, 'property', 'name', 'javaType', 'value', 
generatorCommon.javaBuildInClass(field.javaType));
+addClassNameProperty(res, field, 'javaType');
 
 res.endBlock('');
 });
@@ -428,7 +428,8 @@ function generateCacheTypeMetadataConfiguration(res, meta) {
 
 var kind = meta.kind;
 
-var keyType = addProperty(res, meta, 'keyType');
+var keyType = addClassNameProperty(res, meta, 'keyType');
+
 addProperty(res, meta, 'valueType');
 
 if (kind != 'query') {
@@ -655,6 +656,15 @@ function addProperty(res, obj, propName, setterName) {
 return val;
 }
 
+function addClassNameProperty(res, obj, propName) {
+var val = obj[propName];
+
+if (generatorCommon.isDefined(val))
+addElement(res, 'property', 'name', propName, 'value', 
generatorCommon.javaBuildInClass(val));
+
+return val;
+}
+
 function addBeanWithProperties(res, bean, beanPropName, beanClass, props, 
createBeanAlthoughNoProps) {
 if (bean && generatorCommon.hasProperty(bean, props)) {
 res.emptyLineIfNeeded();
@@ -715,6 +725,7 @@ function addBeanWithProperties(res, bean, beanPropName, 
beanClass, props, create
 res.line('');
 }
 }
+
 function addListProperty(res, obj, propName, listType, rowFactory) {
 var val = obj[propName];
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/51013913/modules/control-center-web/src/main/js/routes/metadata.js
--
diff --git a/modules/control-center-web/src/main/js/routes/metadata.js 
b/modules/control-center-web/src/main/js/routes/metadata.js
index 67bee96..6158f27 100644
--- a/modules/control-center-web/src/main/js/routes/metadata.js
+++ b/modules/control-center-web/src/main/js/routes/metadata.js
@@ -39,20 +39,17 @@ router.post('/list', function (req, res) {
 
 // Get owned space and all accessed space.
 db.Space.find({$or: [{owner: user_id}, {usedBy: {$elemMatch: {account: 
user_id}}}]}, function (err, spaces) {
-if (err)
-return res.status(500).send(err.message);
-
-var space_ids = spaces.map(function (value) {
-return value._id;
-});
-
-// Get all metadata for spaces.
-db.CacheTypeMetadata.find({space: {$in: 
space_ids}}).sort('name').exec(function (err, me

[2/2] incubator-ignite git commit: Merge remote-tracking branch 'remotes/origin/master' into ignite-gg-9615-1

2015-08-19 Thread vozerov
Merge remote-tracking branch 'remotes/origin/master' into ignite-gg-9615-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/0a5f5e33
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/0a5f5e33
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/0a5f5e33

Branch: refs/heads/ignite-gg-9615-1
Commit: 0a5f5e3369501bd37fc1cc1b4e58f5440c4a3590
Parents: da30652 e9a0d06
Author: ptupitsyn 
Authored: Wed Aug 19 12:50:03 2015 +0300
Committer: ptupitsyn 
Committed: Wed Aug 19 12:50:03 2015 +0300

--
 .../ignite/schema/model/PojoDescriptor.java |   6 +-
 .../parser/dialect/OracleMetadataDialect.java   | 101 ++-
 2 files changed, 57 insertions(+), 50 deletions(-)
--




[1/2] incubator-ignite git commit: ignite-1263 Fixed timestamp and CLOB type detection. Closes #21.

2015-08-19 Thread vozerov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-gg-9615-1 da3065212 -> 0a5f5e336


ignite-1263 Fixed timestamp and CLOB type detection. Closes #21.


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

Branch: refs/heads/ignite-gg-9615-1
Commit: e9a0d06ffa104c0e54e0e95b0af229f7648d22d1
Parents: 09da9c2
Author: Vasiliy Sisko 
Authored: Wed Aug 19 14:33:52 2015 +0700
Committer: Andrey 
Committed: Wed Aug 19 14:33:52 2015 +0700

--
 .../ignite/schema/model/PojoDescriptor.java |   6 +-
 .../parser/dialect/OracleMetadataDialect.java   | 101 ++-
 2 files changed, 57 insertions(+), 50 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/e9a0d06f/modules/schema-import/src/main/java/org/apache/ignite/schema/model/PojoDescriptor.java
--
diff --git 
a/modules/schema-import/src/main/java/org/apache/ignite/schema/model/PojoDescriptor.java
 
b/modules/schema-import/src/main/java/org/apache/ignite/schema/model/PojoDescriptor.java
index 5e1da06..5a4a1fa 100644
--- 
a/modules/schema-import/src/main/java/org/apache/ignite/schema/model/PojoDescriptor.java
+++ 
b/modules/schema-import/src/main/java/org/apache/ignite/schema/model/PojoDescriptor.java
@@ -504,7 +504,11 @@ public class PojoDescriptor {
 case TIMESTAMP:
 return java.sql.Timestamp.class;
 
-// BINARY, VARBINARY, LONGVARBINARY, ARRAY, BLOB, CLOB, NCLOB, 
NULL, DATALINK
+case CLOB:
+case NCLOB:
+return String.class;
+
+// BINARY, VARBINARY, LONGVARBINARY, ARRAY, BLOB, NULL, DATALINK
 // OTHER, JAVA_OBJECT, DISTINCT, STRUCT, REF, ROWID, SQLXML
 default:
 return Object.class;

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/e9a0d06f/modules/schema-import/src/main/java/org/apache/ignite/schema/parser/dialect/OracleMetadataDialect.java
--
diff --git 
a/modules/schema-import/src/main/java/org/apache/ignite/schema/parser/dialect/OracleMetadataDialect.java
 
b/modules/schema-import/src/main/java/org/apache/ignite/schema/parser/dialect/OracleMetadataDialect.java
index 860ff68..30dda5d 100644
--- 
a/modules/schema-import/src/main/java/org/apache/ignite/schema/parser/dialect/OracleMetadataDialect.java
+++ 
b/modules/schema-import/src/main/java/org/apache/ignite/schema/parser/dialect/OracleMetadataDialect.java
@@ -87,73 +87,76 @@ public class OracleMetadataDialect extends 
DatabaseMetadataDialect {
  * @throws SQLException If failed to decode type.
  */
 private int decodeType(ResultSet rs) throws SQLException {
-switch (rs.getString(DATA_TYPE_IDX)) {
-case "CHAR":
-case "NCHAR":
-return CHAR;
+String type = rs.getString(DATA_TYPE_IDX);
 
-case "VARCHAR2":
-case "NVARCHAR2":
-return VARCHAR;
+if (type.startsWith("TIMESTAMP"))
+return TIMESTAMP;
+else {
+switch (type) {
+case "CHAR":
+case "NCHAR":
+return CHAR;
 
-case "LONG":
-return LONGVARCHAR;
+case "VARCHAR2":
+case "NVARCHAR2":
+return VARCHAR;
 
-case "LONG RAW":
-return LONGVARBINARY;
+case "LONG":
+return LONGVARCHAR;
 
-case "FLOAT":
-return FLOAT;
+case "LONG RAW":
+return LONGVARBINARY;
 
-case "NUMBER":
-int precision = rs.getInt(DATA_PRECISION_IDX);
-int scale = rs.getInt(DATA_SCALE_IDX);
+case "FLOAT":
+return FLOAT;
 
-if (scale > 0) {
-if (scale < 4 && precision < 19)
-return FLOAT;
+case "NUMBER":
+int precision = rs.getInt(DATA_PRECISION_IDX);
+int scale = rs.getInt(DATA_SCALE_IDX);
 
-if (scale > 4 || precision > 19)
-return DOUBLE;
+if (scale > 0) {
+if (scale < 4 && precision < 19)
+return FLOAT;
 
-return NUMERIC;
-}
-else {
-if (precision < 1)
-return INTEGER;
+

incubator-ignite git commit: IGNITE-843: Fixed merging cmd options and cfg options.

2015-08-19 Thread akuznetsov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-843 510139132 -> 2f839acb4


IGNITE-843: Fixed merging cmd options and cfg options.


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

Branch: refs/heads/ignite-843
Commit: 2f839acb4799ca7b2b54b55604dccb77bf924a7f
Parents: 5101391
Author: Alexey Kuznetsov 
Authored: Wed Aug 19 16:57:07 2015 +0700
Committer: Alexey Kuznetsov 
Committed: Wed Aug 19 16:57:07 2015 +0700

--
 modules/control-center-agent/README.txt|  4 ++--
 .../apache/ignite/agent/AgentConfiguration.java| 17 +
 2 files changed, 15 insertions(+), 6 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/2f839acb/modules/control-center-agent/README.txt
--
diff --git a/modules/control-center-agent/README.txt 
b/modules/control-center-agent/README.txt
index 694fa89..aaabdf0 100644
--- a/modules/control-center-agent/README.txt
+++ b/modules/control-center-agent/README.txt
@@ -25,7 +25,7 @@ Configuration file:
 
 Example configuration file:
 login=john.sm...@gmail.com
-serverURI=wss://control-center.example.com
+serverURI=wss://control-center.example.com:3001
 
 Options:
 -h, --help
@@ -49,7 +49,7 @@ Options:
User's password.
 
 -s, --serverUri
-   URI for connect to Ignite Web Control Center, for example: 
"wss://control-center.example.com".
+   URI for connect to Ignite Web Control Center, for example: 
"wss://control-center.example.com:3001".
Default: "wss://localhost:3001".
 
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/2f839acb/modules/control-center-agent/src/main/java/org/apache/ignite/agent/AgentConfiguration.java
--
diff --git 
a/modules/control-center-agent/src/main/java/org/apache/ignite/agent/AgentConfiguration.java
 
b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/AgentConfiguration.java
index cf10e77..318b1ac 100644
--- 
a/modules/control-center-agent/src/main/java/org/apache/ignite/agent/AgentConfiguration.java
+++ 
b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/AgentConfiguration.java
@@ -27,6 +27,12 @@ import java.util.*;
  * Agent configuration.
  */
 public class AgentConfiguration {
+/** Default server URI. */
+private static final String DFLT_SERVER_URI = "wss://localhost:3001";
+
+/** Default Ignite node HTTP URI. */
+private static final String DFLT_NODE_URI = "http://localhost:8080";;
+
 /** */
 @Parameter(names = {"-l", "--login"}, description = "User's login (email) 
on Ignite Web Control Center")
 private String login;
@@ -37,8 +43,8 @@ public class AgentConfiguration {
 
 /** */
 @Parameter(names = {"-s", "--serverUri"}, description = "URI for connect 
to Ignite Web Control Center via " +
-"web-socket protocol, for example: 
wss://control-center.my-company.com")
-private String srvUri = "wss://localhost:3001";
+"web-socket protocol, for example: 
wss://control-center.my-company.com:3001")
+private String srvUri;
 
 /** */
 @Parameter(names = {"-n", "--nodeUri"}, description = "URI for connect to 
Ignite REST server, " +
@@ -191,11 +197,14 @@ public class AgentConfiguration {
 if (cmd.getServerUri() != null)
 setServerUri(cmd.getServerUri());
 
+if (srvUri == null)
+setServerUri(DFLT_SERVER_URI);
+
 if (cmd.getNodeUri() != null)
 setNodeUri(cmd.getNodeUri());
 
-if (cmd.getConfigPath() != null)
-setNodeUri(cmd.getNodeUri());
+if (nodeUri == null)
+setNodeUri(DFLT_NODE_URI);
 
 if (cmd.getDriversFolder() != null)
 setDriversFolder(cmd.getDriversFolder());



incubator-ignite git commit: IGNITE-843: Set java name same as db name on enter..

2015-08-19 Thread akuznetsov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-843 2f839acb4 -> 7307836d3


IGNITE-843: Set java name same as db name on enter..


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

Branch: refs/heads/ignite-843
Commit: 7307836d3fc93cd2e8bcd5e1ba317284c30813bf
Parents: 2f839ac
Author: Alexey Kuznetsov 
Authored: Wed Aug 19 17:25:42 2015 +0700
Committer: Alexey Kuznetsov 
Committed: Wed Aug 19 17:25:42 2015 +0700

--
 .../control-center-web/src/main/js/views/includes/controls.jade| 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/7307836d/modules/control-center-web/src/main/js/views/includes/controls.jade
--
diff --git 
a/modules/control-center-web/src/main/js/views/includes/controls.jade 
b/modules/control-center-web/src/main/js/views/includes/controls.jade
index 0dd319d1..5ca038d 100644
--- a/modules/control-center-web/src/main/js/views/includes/controls.jade
+++ b/modules/control-center-web/src/main/js/views/includes/controls.jade
@@ -202,7 +202,7 @@ mixin table-db-field-edit(prefix, focusId, index)
 .col-xs-3.col-sm-3.col-md-3
 label.fieldSep /
 .input-tip
-input.form-control(id=databaseNameId 
enter-focus-next=databaseTypeId type='text' ng-model=databaseNameModel 
placeholder='DB name' on-escape='tableReset()')
+input.form-control(id=databaseNameId 
enter-focus-next=databaseTypeId type='text' ng-model=databaseNameModel 
placeholder='DB name' on-enter='#{javaNameModel} = #{javaNameModel} ? 
#{javaNameModel} : #{databaseNameModel}' on-escape='tableReset()')
 .col-xs-3.col-sm-3.col-md-3
 label.fieldSep /
 .input-tip



incubator-ignite git commit: # ignite-1265 set topology version for mvcc candidate

2015-08-19 Thread sboikov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-1265 8b3fed850 -> b55365d31


# ignite-1265 set topology version for mvcc candidate


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

Branch: refs/heads/ignite-1265
Commit: b55365d316febf834cde553fbb55b33d42194069
Parents: 8b3fed8
Author: sboikov 
Authored: Wed Aug 19 13:30:06 2015 +0300
Committer: sboikov 
Committed: Wed Aug 19 13:53:41 2015 +0300

--
 .../distributed/GridDistributedCacheEntry.java  |  7 ++
 .../distributed/dht/GridDhtTxPrepareFuture.java |  7 +-
 .../distributed/near/GridNearCacheEntry.java|  6 ++
 .../distributed/near/GridNearLockFuture.java|  4 +-
 .../cache/IgniteCacheInvokeReadThroughTest.java |  2 +-
 .../near/GridCacheNearOnlyTopologySelfTest.java |  4 +-
 .../near/GridCacheNearTxForceKeyTest.java   | 76 
 .../testsuites/IgniteCacheTestSuite2.java   |  1 +
 8 files changed, 100 insertions(+), 7 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/b55365d3/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/GridDistributedCacheEntry.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/GridDistributedCacheEntry.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/GridDistributedCacheEntry.java
index bd72764..e007190 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/GridDistributedCacheEntry.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/GridDistributedCacheEntry.java
@@ -17,6 +17,7 @@
 
 package org.apache.ignite.internal.processors.cache.distributed;
 
+import org.apache.ignite.internal.processors.affinity.*;
 import org.apache.ignite.internal.processors.cache.*;
 import org.apache.ignite.internal.processors.cache.transactions.*;
 import org.apache.ignite.internal.processors.cache.version.*;
@@ -68,6 +69,7 @@ public class GridDistributedCacheEntry extends 
GridCacheMapEntry {
  *
  * @param threadId Owning thread ID.
  * @param ver Lock version.
+ * @param topVer Topology version.
  * @param timeout Timeout to acquire lock.
  * @param reenter Reentry flag.
  * @param tx Transaction flag.
@@ -78,6 +80,7 @@ public class GridDistributedCacheEntry extends 
GridCacheMapEntry {
 @Nullable public GridCacheMvccCandidate addLocal(
 long threadId,
 GridCacheVersion ver,
+AffinityTopologyVersion topVer,
 long timeout,
 boolean reenter,
 boolean tx,
@@ -105,6 +108,9 @@ public class GridDistributedCacheEntry extends 
GridCacheMapEntry {
 
 cand = mvcc.addLocal(this, threadId, ver, timeout, reenter, tx, 
implicitSingle);
 
+if (cand != null)
+cand.topologyVersion(topVer);
+
 owner = mvcc.anyOwner();
 
 boolean emptyAfter = mvcc.isEmpty();
@@ -732,6 +738,7 @@ public class GridDistributedCacheEntry extends 
GridCacheMapEntry {
 return addLocal(
 tx.threadId(),
 tx.xidVersion(),
+tx.topologyVersion(),
 timeout,
 false,
 true,

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/b55365d3/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
index ad1023f..1539a2a 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
@@ -797,6 +797,10 @@ public final class GridDhtTxPrepareFuture extends 
GridCompoundFuture forceRebalanceKeys(Map> keysMap) {
 if (F.isEmpty(keysMap))
 return null;
@@ -978,7 +982,8 @@ public final class GridDhtTxPrepareFuture extends 
GridCompoundFuturehttp://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/b55365d3/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearCacheEntry.java
--

incubator-ignite git commit: IGNITE-843: WIP saving presets.

2015-08-19 Thread akuznetsov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-843 7307836d3 -> a87cc90b8


IGNITE-843: WIP saving presets.


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

Branch: refs/heads/ignite-843
Commit: a87cc90b89f7976fc46f79f4e19f594b7838db9c
Parents: 7307836
Author: Alexey Kuznetsov 
Authored: Wed Aug 19 18:12:11 2015 +0700
Committer: Alexey Kuznetsov 
Committed: Wed Aug 19 18:12:11 2015 +0700

--
 modules/control-center-web/src/main/js/app.js   |  2 +
 .../src/main/js/routes/presets.js   | 68 
 2 files changed, 70 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/a87cc90b/modules/control-center-web/src/main/js/app.js
--
diff --git a/modules/control-center-web/src/main/js/app.js 
b/modules/control-center-web/src/main/js/app.js
index 95b300a..81107ec 100644
--- a/modules/control-center-web/src/main/js/app.js
+++ b/modules/control-center-web/src/main/js/app.js
@@ -31,6 +31,7 @@ var notebooksRoutes = require('./routes/notebooks');
 var clustersRouter = require('./routes/clusters');
 var cachesRouter = require('./routes/caches');
 var metadataRouter = require('./routes/metadata');
+var presetsRouter = require('./routes/presets');
 var summary = require('./routes/summary');
 var adminRouter = require('./routes/admin');
 var profileRouter = require('./routes/profile');
@@ -132,6 +133,7 @@ app.use('/profile', mustAuthenticated, profileRouter);
 app.use('/configuration/clusters', clustersRouter);
 app.use('/configuration/caches', cachesRouter);
 app.use('/configuration/metadata', metadataRouter);
+app.use('/configuration/presets', presetsRouter);
 app.use('/configuration/summary', summary);
 
 app.use('/notebooks', mustAuthenticated, notebooksRoutes);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/a87cc90b/modules/control-center-web/src/main/js/routes/presets.js
--
diff --git a/modules/control-center-web/src/main/js/routes/presets.js 
b/modules/control-center-web/src/main/js/routes/presets.js
new file mode 100644
index 000..119102a
--- /dev/null
+++ b/modules/control-center-web/src/main/js/routes/presets.js
@@ -0,0 +1,68 @@
+/*
+ * 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.
+ */
+
+var router = require('express').Router();
+var db = require('../db');
+
+/**
+ * Get database presets.
+ *
+ * @param req Request.
+ * @param res Response.
+ */
+router.post('/list', function (req, res) {
+var userId = req.currentUserId();
+
+// Get owned space and all accessed space.
+db.Space.find({$or: [{owner: userId}, {usedBy: {$elemMatch: {account: 
userId}}}]}, function (err, spaces) {
+if (db.processed(err, res)) {
+var spaceIds = spaces.map(function (value) {
+return value._id;
+});
+
+// Get all presets for spaces.
+db.DatabasePreset.find({space: {$in: spaceIds}}).exec(function 
(err, presets) {
+if (db.processed(err, res))
+res.json({spaces: spaces, presets: presets});
+});
+}
+});
+});
+
+/**
+ * Save database preset.
+ */
+router.post('/save', function (req, res) {
+var params = req.body;
+
+db.CacheTypeMetadata.findOne({space: params.space, jdbcDriverJar: 
params.jdbcDriverJar}, function (err, preset) {
+if (db.processed(err, res)) {
+if (preset)
+db.CacheTypeMetadata.update({space: params.space, 
jdbcDriverJar: params.jdbcDriverJar}, params, {upsert: true}, function (err) {
+if (db.processed(err, res))
+return res.sendStatus(200);
+});
+else
+(new db.CacheTypeMetadata(params)).save(function (

incubator-ignite git commit: IGNITE-843: Filter deleted metadatas.

2015-08-19 Thread akuznetsov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-843 a87cc90b8 -> 700eca7a6


IGNITE-843: Filter deleted metadatas.


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

Branch: refs/heads/ignite-843
Commit: 700eca7a668d0edd8aa9ee374fd11b1e7d2abecd
Parents: a87cc90
Author: Alexey Kuznetsov 
Authored: Wed Aug 19 18:17:02 2015 +0700
Committer: Alexey Kuznetsov 
Committed: Wed Aug 19 18:17:02 2015 +0700

--
 .../src/main/js/controllers/caches-controller.js| 16 ++--
 1 file changed, 14 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/700eca7a/modules/control-center-web/src/main/js/controllers/caches-controller.js
--
diff --git 
a/modules/control-center-web/src/main/js/controllers/caches-controller.js 
b/modules/control-center-web/src/main/js/controllers/caches-controller.js
index 121eed0..978e263 100644
--- a/modules/control-center-web/src/main/js/controllers/caches-controller.js
+++ b/modules/control-center-web/src/main/js/controllers/caches-controller.js
@@ -186,6 +186,18 @@ controlCenterModule.controller('cachesController', [
 var restoredItem = 
angular.fromJson(sessionStorage.cacheBackupItem);
 
 if (restoredItem) {
+restoredItem.queryMetadata = 
_.filter(restoredItem.queryMetadata, function (metaId) {
+return _.findIndex($scope.metadatas, function 
(scopeMeta) {
+return scopeMeta.value == metaId;
+}) >= 0;
+});
+
+restoredItem.storeMetadata = 
_.filter(restoredItem.storeMetadata, function (metaId) {
+return _.findIndex($scope.metadatas, function 
(scopeMeta) {
+return scopeMeta.value == metaId;
+}) >= 0;
+});
+
 if (restoredItem._id) {
 var idx = _.findIndex($scope.caches, function 
(cache) {
 return cache._id == restoredItem._id;
@@ -207,8 +219,8 @@ controlCenterModule.controller('cachesController', [
 else {
 // Clusters changed by user. We need to 
remove deleted clusters (if any).
 restoredItem.clusters = 
_.filter(restoredItem.clusters, function (clusterId) {
-return _.findIndex($scope.clusters, 
function (scopeCcluster) {
-return scopeCcluster.value == 
clusterId;
+return _.findIndex($scope.clusters, 
function (scopeCluster) {
+return scopeCluster.value == 
clusterId;
 }) >= 0;
 });
 }



incubator-ignite git commit: IGNITE-843: Fixed typo.

2015-08-19 Thread akuznetsov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-843 700eca7a6 -> 0993b4df0


IGNITE-843: Fixed typo.


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

Branch: refs/heads/ignite-843
Commit: 0993b4df0c66d734e10a0e56d4838c912ddfc854
Parents: 700eca7
Author: Alexey Kuznetsov 
Authored: Wed Aug 19 18:35:47 2015 +0700
Committer: Alexey Kuznetsov 
Committed: Wed Aug 19 18:35:47 2015 +0700

--
 .../control-center-web/src/main/js/views/includes/controls.jade| 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/0993b4df/modules/control-center-web/src/main/js/views/includes/controls.jade
--
diff --git 
a/modules/control-center-web/src/main/js/views/includes/controls.jade 
b/modules/control-center-web/src/main/js/views/includes/controls.jade
index 5ca038d..779fe80 100644
--- a/modules/control-center-web/src/main/js/views/includes/controls.jade
+++ b/modules/control-center-web/src/main/js/views/includes/controls.jade
@@ -113,7 +113,7 @@ mixin details-row
 
 - var detailMdl = 'getModel(backupItem, detail)[detail.model]';
 - var detailCommon = {'ng-model': detailMdl, 'ng-required': 
'detail.required'};
-- var detailDisabled = '{{detail.disable}}'
+- var detailDisabled = '{{detail.disabled}}'
 
 - var customValidators = {'ng-attr-ipaddress': '{{detail.ipaddress}}'}
 



Git Push Summary

2015-08-19 Thread sboikov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-1.3.3-p3 [created] 5faffb980


incubator-ignite git commit: 1.3.3-p3-SNAPSHOT

2015-08-19 Thread sboikov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-1.3.3-p3 5faffb980 -> ac670f923


1.3.3-p3-SNAPSHOT


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

Branch: refs/heads/ignite-1.3.3-p3
Commit: ac670f923c84b4a20b60487354e838cd1d26e263
Parents: 5faffb9
Author: Ignite Teamcity 
Authored: Wed Aug 19 15:09:09 2015 +0300
Committer: Ignite Teamcity 
Committed: Wed Aug 19 15:09:09 2015 +0300

--
 examples/pom.xml   | 2 +-
 modules/aop/pom.xml| 2 +-
 modules/apache-license-gen/pom.xml | 2 +-
 modules/aws/pom.xml| 2 +-
 modules/clients/pom.xml| 2 +-
 modules/cloud/pom.xml  | 2 +-
 modules/codegen/pom.xml| 2 +-
 modules/core/pom.xml   | 2 +-
 modules/core/src/main/resources/ignite.properties  | 2 +-
 modules/extdata/p2p/pom.xml| 2 +-
 modules/extdata/uri/modules/uri-dependency/pom.xml | 2 +-
 modules/extdata/uri/pom.xml| 2 +-
 modules/gce/pom.xml| 2 +-
 modules/geospatial/pom.xml | 2 +-
 modules/hadoop/pom.xml | 2 +-
 modules/hibernate/pom.xml  | 2 +-
 modules/indexing/pom.xml   | 2 +-
 modules/jcl/pom.xml| 2 +-
 modules/jta/pom.xml| 2 +-
 modules/kafka/pom.xml  | 2 +-
 modules/log4j/pom.xml  | 2 +-
 modules/mesos/pom.xml  | 2 +-
 modules/rest-http/pom.xml  | 2 +-
 modules/scalar-2.10/pom.xml| 2 +-
 modules/scalar/pom.xml | 2 +-
 modules/schedule/pom.xml   | 2 +-
 modules/schema-import/pom.xml  | 2 +-
 modules/slf4j/pom.xml  | 2 +-
 modules/spark-2.10/pom.xml | 2 +-
 modules/spark/pom.xml  | 2 +-
 modules/spring/pom.xml | 2 +-
 modules/ssh/pom.xml| 2 +-
 modules/tools/pom.xml  | 2 +-
 modules/urideploy/pom.xml  | 2 +-
 modules/visor-console-2.10/pom.xml | 2 +-
 modules/visor-console/pom.xml  | 2 +-
 modules/visor-plugins/pom.xml  | 2 +-
 modules/web/pom.xml| 2 +-
 modules/yardstick/pom.xml  | 2 +-
 modules/yarn/pom.xml   | 2 +-
 pom.xml| 2 +-
 41 files changed, 41 insertions(+), 41 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/ac670f92/examples/pom.xml
--
diff --git a/examples/pom.xml b/examples/pom.xml
index 043689c..e57a075 100644
--- a/examples/pom.xml
+++ b/examples/pom.xml
@@ -28,7 +28,7 @@
 
 
 ignite-examples
-1.3.3-p2-SNAPSHOT
+1.3.3-p3-SNAPSHOT
 
 
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/ac670f92/modules/aop/pom.xml
--
diff --git a/modules/aop/pom.xml b/modules/aop/pom.xml
index 8a271e5..bcf2b9f 100644
--- a/modules/aop/pom.xml
+++ b/modules/aop/pom.xml
@@ -31,7 +31,7 @@
 
 
 ignite-aop
-1.3.3-p2-SNAPSHOT
+1.3.3-p3-SNAPSHOT
 
 
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/ac670f92/modules/apache-license-gen/pom.xml
--
diff --git a/modules/apache-license-gen/pom.xml 
b/modules/apache-license-gen/pom.xml
index e1066c1..5dd7459 100644
--- a/modules/apache-license-gen/pom.xml
+++ b/modules/apache-license-gen/pom.xml
@@ -31,5 +31,5 @@
 
 org.apache.ignite
 ignite-apache-license-gen
-1.3.3-p2-SNAPSHOT
+1.3.3-p3-SNAPSHOT
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/ac670f92/modules/aws/pom.xml
--
diff --git a/modules/aws/pom.xml b/modules/aws/pom.xml
index e5cf518..51457cf 100644
--- a/modules/aws/pom.xml
+++ b/modules/aws/pom.xml
@@ -31,7 +31,7 @@
 
 
 ignite-aws
-1.3.3-p2-SNAPSHOT
+1.3.3-p3-SNAPSHOT
 
 
 

http://git-wip-us.a

incubator-ignite git commit: # ignite-1265 cross cache tx failover test

2015-08-19 Thread sboikov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-1265 b55365d31 -> b398474a1


# ignite-1265 cross cache tx failover test


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

Branch: refs/heads/ignite-1265
Commit: b398474a1393fc8ea49a35023d4229411029f217
Parents: b55365d
Author: sboikov 
Authored: Wed Aug 19 15:18:50 2015 +0300
Committer: sboikov 
Committed: Wed Aug 19 15:18:50 2015 +0300

--
 .../IgniteCacheCrossCacheTxFailoverTest.java| 396 +++
 1 file changed, 396 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/b398474a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/IgniteCacheCrossCacheTxFailoverTest.java
--
diff --git 
a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/IgniteCacheCrossCacheTxFailoverTest.java
 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/IgniteCacheCrossCacheTxFailoverTest.java
new file mode 100644
index 000..8ebcba5
--- /dev/null
+++ 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/IgniteCacheCrossCacheTxFailoverTest.java
@@ -0,0 +1,396 @@
+/*
+ * 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.dht;
+
+import org.apache.ignite.*;
+import org.apache.ignite.cache.*;
+import org.apache.ignite.cache.affinity.rendezvous.*;
+import org.apache.ignite.configuration.*;
+import org.apache.ignite.internal.*;
+import org.apache.ignite.internal.processors.affinity.*;
+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 org.apache.ignite.transactions.*;
+
+import javax.cache.*;
+import java.io.*;
+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.*;
+import static org.apache.ignite.transactions.TransactionConcurrency.*;
+import static org.apache.ignite.transactions.TransactionIsolation.*;
+
+/**
+ *
+ */
+public class IgniteCacheCrossCacheTxFailoverTest extends 
GridCommonAbstractTest {
+/** */
+private static final TcpDiscoveryIpFinder IP_FINDER = new 
TcpDiscoveryVmIpFinder(true);
+
+/** */
+private static final String CACHE1 = "cache1";
+
+/** */
+private static final String CACHE2 = "cache2";
+
+/** */
+private static final int GRID_CNT = 4;
+
+/** */
+private static final int KEY_RANGE = 1000;
+
+/** {@inheritDoc} */
+@Override protected IgniteConfiguration getConfiguration(String gridName) 
throws Exception {
+IgniteConfiguration cfg = super.getConfiguration(gridName);
+
+((TcpDiscoverySpi)cfg.getDiscoverySpi()).setIpFinder(IP_FINDER);
+
+if (gridName.equals(getTestGridName(GRID_CNT - 1)))
+cfg.setClientMode(true);
+
+return cfg;
+}
+
+/** {@inheritDoc} */
+@Override protected void beforeTestsStarted() throws Exception {
+super.beforeTestsStarted();
+
+startGrids(4);
+}
+
+/** {@inheritDoc} */
+@Override protected void afterTestsStopped() throws Exception {
+super.afterTestsStopped();
+
+stopAllGrids();
+}
+
+/**
+ * @param name Cache name.
+ * @param cacheMode Cache mode.
+ * @param parts Number of partitions.
+ * @return Cache configuration.
+ */
+private CacheConfiguration cacheConfiguration(String name, 

[3/8] incubator-ignite git commit: IGNITE-1265 - EntryProcessorTest when nodes joining topology.

2015-08-19 Thread sboikov
IGNITE-1265 - EntryProcessorTest when nodes joining topology.


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

Branch: refs/heads/ignite-1.3.3-p3
Commit: 013d7075853d4728739f3dfb2647ce6001d723c8
Parents: 574c679
Author: Alexey Goncharuk 
Authored: Tue Aug 18 18:18:43 2015 -0700
Committer: Alexey Goncharuk 
Committed: Tue Aug 18 18:18:43 2015 -0700

--
 .../IgniteCacheEntryProcessorRestartTest.java   | 185 +++
 1 file changed, 185 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/013d7075/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheEntryProcessorRestartTest.java
--
diff --git 
a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheEntryProcessorRestartTest.java
 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheEntryProcessorRestartTest.java
new file mode 100644
index 000..c027ee4
--- /dev/null
+++ 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheEntryProcessorRestartTest.java
@@ -0,0 +1,185 @@
+/*
+ * 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.configuration.*;
+import org.apache.ignite.internal.*;
+import org.apache.ignite.internal.util.typedef.internal.*;
+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 javax.cache.processor.*;
+import java.io.*;
+import java.util.*;
+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.CacheRebalanceMode.*;
+import static org.apache.ignite.cache.CacheWriteSynchronizationMode.*;
+
+/**
+ * Tests cache in-place modification logic with iterative value increment.
+ */
+public class IgniteCacheEntryProcessorRestartTest extends 
GridCommonAbstractTest {
+/** IP finder. */
+private static final TcpDiscoveryIpFinder IP_FINDER = new 
TcpDiscoveryVmIpFinder(true);
+
+/** Number of nodes to test on. */
+private static final int GRID_CNT = 2;
+
+/** Number of increment iterations. */
+private static final int NUM_SETS = 50;
+
+/** Helper for excluding stopped node from iteration logic. */
+private AtomicReferenceArray grids;
+
+/** {@inheritDoc} */
+@Override protected IgniteConfiguration getConfiguration(String gridName) 
throws Exception {
+IgniteConfiguration cfg = super.getConfiguration(gridName);
+
+CacheConfiguration cache = new CacheConfiguration();
+
+cache.setCacheMode(PARTITIONED);
+cache.setAtomicityMode(TRANSACTIONAL);
+cache.setWriteSynchronizationMode(FULL_SYNC);
+cache.setBackups(1);
+cache.setRebalanceMode(SYNC);
+
+cfg.setCacheConfiguration(cache);
+
+TcpDiscoverySpi disco = new TcpDiscoverySpi();
+
+disco.setIpFinder(IP_FINDER);
+
+TcpCommunicationSpi commSpi = new TcpCommunicationSpi();
+
+commSpi.setSharedMemoryPort(-1);
+
+cfg.setCommunicationSpi(commSpi);
+
+cfg.setDiscoverySpi(disco);
+
+return cfg;
+}
+
+/** {@inheritDoc} */
+@Override protected void beforeTest() throws Exception {
+startGrids(GRID_CNT);
+
+grids = new AtomicReferenceArray<>(GRID_CNT);
+
+for (int i = 0; i < GRID_CNT; i++)
+grids.set(i, grid(i));
+}
+
+/** {@inheritDoc} */
+  

[1/8] incubator-ignite git commit: IGNITE-1265 - Properly handle invalid partitions in DHT prepare response.

2015-08-19 Thread sboikov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-1.3.3-p3 ac670f923 -> 7d1a550dc


IGNITE-1265 - Properly handle invalid partitions in DHT prepare response.


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

Branch: refs/heads/ignite-1.3.3-p3
Commit: 7a43dde77b47478e6b02bbab9d81ad70a2299c51
Parents: 5faffb9
Author: Alexey Goncharuk 
Authored: Tue Aug 18 10:35:59 2015 -0700
Committer: Alexey Goncharuk 
Committed: Tue Aug 18 10:35:59 2015 -0700

--
 .../processors/cache/GridCacheIoManager.java|  1 -
 .../processors/cache/GridCacheUtils.java| 20 +
 .../distributed/dht/GridDhtTxPrepareFuture.java | 23 +++-
 .../dht/GridDhtTxPrepareResponse.java   | 17 +++
 .../near/GridNearTxPrepareResponse.java |  3 ---
 .../cache/transactions/IgniteInternalTx.java|  2 +-
 .../cache/transactions/IgniteTxAdapter.java | 19 +++-
 .../cache/transactions/IgniteTxHandler.java |  5 ++---
 .../ignite/internal/util/lang/GridFunc.java | 14 
 9 files changed, 90 insertions(+), 14 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/7a43dde7/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheIoManager.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheIoManager.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheIoManager.java
index 29e3551..c128aa6 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheIoManager.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheIoManager.java
@@ -493,7 +493,6 @@ public class GridCacheIoManager extends 
GridCacheSharedManagerAdapter {
 req.version(),
 null,
 null,
-null,
 null);
 
 res.error(req.classError());

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/7a43dde7/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
index 41e3896..1e3cd67 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
@@ -1681,6 +1681,26 @@ public class GridCacheUtils {
 }
 
 /**
+ * @param partsMap Cache ID to partition IDs collection map.
+ * @return Cache ID to partition ID array map.
+ */
+public static Map 
convertInvalidPartitions(Map> partsMap) {
+Map res = new HashMap<>(partsMap.size());
+
+for (Map.Entry> entry : partsMap.entrySet()) {
+Set parts = entry.getValue();
+
+Integer[] partsArray = new Integer[parts.size()];
+
+partsArray = parts.toArray(partsArray);
+
+res.put(entry.getKey(), partsArray);
+}
+
+return res;
+}
+
+/**
  * Stops store session listeners.
  *
  * @param ctx Kernal context.

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/7a43dde7/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
index af0fbdf..27de8cf 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
@@ -574,13 +574,14 @@ public final class GridDhtTxPrepareFuture extends 
GridCompoundFuture it = 
dhtMapping.entries().iterator(); it.hasNext();) {
 IgniteTxEntry entry  = it.next();
@@ -1206,6 +1208,25 @@ public final class GridDhtTxPrepareFuture extends 
GridCompoundFuturehttp://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/7a43dde7/modu

[7/8] incubator-ignite git commit: # ignite-1265 set topology version for mvcc candidate

2015-08-19 Thread sboikov
# ignite-1265 set topology version for mvcc candidate


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

Branch: refs/heads/ignite-1.3.3-p3
Commit: b55365d316febf834cde553fbb55b33d42194069
Parents: 8b3fed8
Author: sboikov 
Authored: Wed Aug 19 13:30:06 2015 +0300
Committer: sboikov 
Committed: Wed Aug 19 13:53:41 2015 +0300

--
 .../distributed/GridDistributedCacheEntry.java  |  7 ++
 .../distributed/dht/GridDhtTxPrepareFuture.java |  7 +-
 .../distributed/near/GridNearCacheEntry.java|  6 ++
 .../distributed/near/GridNearLockFuture.java|  4 +-
 .../cache/IgniteCacheInvokeReadThroughTest.java |  2 +-
 .../near/GridCacheNearOnlyTopologySelfTest.java |  4 +-
 .../near/GridCacheNearTxForceKeyTest.java   | 76 
 .../testsuites/IgniteCacheTestSuite2.java   |  1 +
 8 files changed, 100 insertions(+), 7 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/b55365d3/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/GridDistributedCacheEntry.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/GridDistributedCacheEntry.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/GridDistributedCacheEntry.java
index bd72764..e007190 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/GridDistributedCacheEntry.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/GridDistributedCacheEntry.java
@@ -17,6 +17,7 @@
 
 package org.apache.ignite.internal.processors.cache.distributed;
 
+import org.apache.ignite.internal.processors.affinity.*;
 import org.apache.ignite.internal.processors.cache.*;
 import org.apache.ignite.internal.processors.cache.transactions.*;
 import org.apache.ignite.internal.processors.cache.version.*;
@@ -68,6 +69,7 @@ public class GridDistributedCacheEntry extends 
GridCacheMapEntry {
  *
  * @param threadId Owning thread ID.
  * @param ver Lock version.
+ * @param topVer Topology version.
  * @param timeout Timeout to acquire lock.
  * @param reenter Reentry flag.
  * @param tx Transaction flag.
@@ -78,6 +80,7 @@ public class GridDistributedCacheEntry extends 
GridCacheMapEntry {
 @Nullable public GridCacheMvccCandidate addLocal(
 long threadId,
 GridCacheVersion ver,
+AffinityTopologyVersion topVer,
 long timeout,
 boolean reenter,
 boolean tx,
@@ -105,6 +108,9 @@ public class GridDistributedCacheEntry extends 
GridCacheMapEntry {
 
 cand = mvcc.addLocal(this, threadId, ver, timeout, reenter, tx, 
implicitSingle);
 
+if (cand != null)
+cand.topologyVersion(topVer);
+
 owner = mvcc.anyOwner();
 
 boolean emptyAfter = mvcc.isEmpty();
@@ -732,6 +738,7 @@ public class GridDistributedCacheEntry extends 
GridCacheMapEntry {
 return addLocal(
 tx.threadId(),
 tx.xidVersion(),
+tx.topologyVersion(),
 timeout,
 false,
 true,

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/b55365d3/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
index ad1023f..1539a2a 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
@@ -797,6 +797,10 @@ public final class GridDhtTxPrepareFuture extends 
GridCompoundFuture forceRebalanceKeys(Map> keysMap) {
 if (F.isEmpty(keysMap))
 return null;
@@ -978,7 +982,8 @@ public final class GridDhtTxPrepareFuture extends 
GridCompoundFuturehttp://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/b55365d3/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearCacheEntry.java
--
diff --git 
a/modules/core/src/main/java/org/apa

[5/8] incubator-ignite git commit: IGNITE-1265 - Entry processor must always have the correct cache value.

2015-08-19 Thread sboikov
IGNITE-1265 - Entry processor must always have the correct cache value.


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

Branch: refs/heads/ignite-1.3.3-p3
Commit: 5065a1eccb3d71b2573d37bb6ff2c78a1bbc107c
Parents: ccaa2b2
Author: Alexey Goncharuk 
Authored: Tue Aug 18 19:35:50 2015 -0700
Committer: Alexey Goncharuk 
Committed: Tue Aug 18 19:35:50 2015 -0700

--
 .../dht/GridClientPartitionTopology.java|  20 +++
 .../dht/GridDhtPartitionTopology.java   |   7 +
 .../dht/GridDhtPartitionTopologyImpl.java   |  20 +++
 .../cache/distributed/dht/GridDhtTxLocal.java   |   4 +-
 .../distributed/dht/GridDhtTxPrepareFuture.java | 136 +--
 .../cache/transactions/IgniteTxEntry.java   |  18 +++
 .../IgniteCacheEntryProcessorNodeJoinTest.java  |  54 
 .../cache/IgniteCacheInvokeReadThroughTest.java |   2 +-
 8 files changed, 223 insertions(+), 38 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/5065a1ec/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridClientPartitionTopology.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridClientPartitionTopology.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridClientPartitionTopology.java
index c3f3e7f..531678e 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridClientPartitionTopology.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridClientPartitionTopology.java
@@ -331,6 +331,26 @@ public class GridClientPartitionTopology implements 
GridDhtPartitionTopology {
 }
 
 /** {@inheritDoc} */
+@Override public GridDhtPartitionState partitionState(UUID nodeId, int 
part) {
+lock.readLock().lock();
+
+try {
+GridDhtPartitionMap partMap = node2part.get(nodeId);
+
+if (partMap != null) {
+GridDhtPartitionState state = partMap.get(part);
+
+return state == null ? EVICTED : state;
+}
+
+return EVICTED;
+}
+finally {
+lock.readLock().unlock();
+}
+}
+
+/** {@inheritDoc} */
 @Override public Collection nodes(int p, 
AffinityTopologyVersion topVer) {
 lock.readLock().lock();
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/5065a1ec/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtPartitionTopology.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtPartitionTopology.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtPartitionTopology.java
index c551fb3..7b08510 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtPartitionTopology.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtPartitionTopology.java
@@ -129,6 +129,13 @@ public interface GridDhtPartitionTopology {
 public GridDhtPartitionMap localPartitionMap();
 
 /**
+ * @param nodeId Node ID.
+ * @param part Partition.
+ * @return Partition state.
+ */
+public GridDhtPartitionState partitionState(UUID nodeId, int part);
+
+/**
  * @return Current update sequence.
  */
 public long updateSequence();

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/5065a1ec/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtPartitionTopologyImpl.java
--
diff --git 
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
index de7f876..f356138 100644
--- 
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
@@ -614,6 +614,26 @@ class GridDhtPartitionTopologyImpl implements 
GridDhtPartitionTopology {
 }
 
 /** {@i

[8/8] incubator-ignite git commit: Merge remote-tracking branch 'remotes/origin/ignite-1265' into ignite-1.3.3-p3

2015-08-19 Thread sboikov
Merge remote-tracking branch 'remotes/origin/ignite-1265' into ignite-1.3.3-p3


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

Branch: refs/heads/ignite-1.3.3-p3
Commit: 7d1a550dcac96dc2028aaeab5632c9d35f99489b
Parents: ac670f9 b55365d
Author: sboikov 
Authored: Wed Aug 19 15:20:13 2015 +0300
Committer: sboikov 
Committed: Wed Aug 19 15:20:13 2015 +0300

--
 .../CachePartialUpdateCheckedException.java |  11 +-
 .../processors/cache/GridCacheIoManager.java|   1 -
 .../processors/cache/GridCacheUtils.java|  23 ++
 .../distributed/GridDistributedCacheEntry.java  |   7 +
 .../dht/GridClientPartitionTopology.java|  20 ++
 .../dht/GridDhtPartitionTopology.java   |   7 +
 .../dht/GridDhtPartitionTopologyImpl.java   |  20 ++
 .../cache/distributed/dht/GridDhtTxLocal.java   |   4 +-
 .../distributed/dht/GridDhtTxPrepareFuture.java | 166 --
 .../dht/GridDhtTxPrepareResponse.java   |  42 +++-
 .../distributed/near/GridNearCacheEntry.java|   6 +
 .../distributed/near/GridNearLockFuture.java|   4 +-
 .../near/GridNearTxPrepareResponse.java |   3 -
 .../cache/transactions/IgniteInternalTx.java|   2 +-
 .../cache/transactions/IgniteTxAdapter.java |  19 +-
 .../cache/transactions/IgniteTxEntry.java   |  18 ++
 .../cache/transactions/IgniteTxHandler.java |   5 +-
 .../ignite/internal/util/lang/GridFunc.java |  14 ++
 ...teAtomicCacheEntryProcessorNodeJoinTest.java |  32 +++
 .../IgniteCacheEntryProcessorNodeJoinTest.java  | 225 +++
 .../near/GridCacheNearOnlyTopologySelfTest.java |   4 +-
 .../near/GridCacheNearTxForceKeyTest.java   |  76 +++
 .../testsuites/IgniteCacheTestSuite2.java   |   4 +
 23 files changed, 670 insertions(+), 43 deletions(-)
--




[4/8] incubator-ignite git commit: IGNITE-1265 - EntryProcessorTest when nodes joining topology.

2015-08-19 Thread sboikov
IGNITE-1265 - EntryProcessorTest when nodes joining topology.


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

Branch: refs/heads/ignite-1.3.3-p3
Commit: ccaa2b20dab5438603471796b7155f309261a41f
Parents: 013d707
Author: Alexey Goncharuk 
Authored: Tue Aug 18 18:38:36 2015 -0700
Committer: Alexey Goncharuk 
Committed: Tue Aug 18 18:38:36 2015 -0700

--
 .../IgniteCacheEntryProcessorNodeJoinTest.java  | 216 +++
 .../IgniteCacheEntryProcessorRestartTest.java   | 185 
 2 files changed, 216 insertions(+), 185 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/ccaa2b20/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheEntryProcessorNodeJoinTest.java
--
diff --git 
a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheEntryProcessorNodeJoinTest.java
 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheEntryProcessorNodeJoinTest.java
new file mode 100644
index 000..9c17ebd
--- /dev/null
+++ 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheEntryProcessorNodeJoinTest.java
@@ -0,0 +1,216 @@
+/*
+ * 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.configuration.*;
+import org.apache.ignite.internal.*;
+import org.apache.ignite.internal.util.typedef.internal.*;
+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 javax.cache.processor.*;
+import java.io.*;
+import java.util.*;
+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.CacheRebalanceMode.*;
+import static org.apache.ignite.cache.CacheWriteSynchronizationMode.*;
+
+/**
+ * Tests cache in-place modification logic with iterative value increment.
+ */
+public class IgniteCacheEntryProcessorNodeJoinTest extends 
GridCommonAbstractTest {
+/** IP finder. */
+private static final TcpDiscoveryIpFinder IP_FINDER = new 
TcpDiscoveryVmIpFinder(true);
+
+/** Number of nodes to test on. */
+private static final int GRID_CNT = 2;
+
+/** Number of increment iterations. */
+private static final int NUM_SETS = 50;
+
+/** Helper for excluding stopped node from iteration logic. */
+private AtomicReferenceArray grids;
+
+/** {@inheritDoc} */
+@Override protected IgniteConfiguration getConfiguration(String gridName) 
throws Exception {
+IgniteConfiguration cfg = super.getConfiguration(gridName);
+
+CacheConfiguration cache = new CacheConfiguration();
+
+cache.setCacheMode(PARTITIONED);
+cache.setAtomicityMode(TRANSACTIONAL);
+cache.setWriteSynchronizationMode(FULL_SYNC);
+cache.setBackups(1);
+cache.setRebalanceMode(SYNC);
+
+cfg.setCacheConfiguration(cache);
+
+TcpDiscoverySpi disco = new TcpDiscoverySpi();
+
+disco.setIpFinder(IP_FINDER);
+
+TcpCommunicationSpi commSpi = new TcpCommunicationSpi();
+
+commSpi.setSharedMemoryPort(-1);
+
+cfg.setCommunicationSpi(commSpi);
+
+cfg.setDiscoverySpi(disco);
+
+return cfg;
+}
+
+/** {@inheritDoc} */
+@Override protected void beforeTest() throws Exception {
+startGrids(GRID_CNT);
+
+grids = new AtomicReferenceArray<>(GRID_CNT);
+
+for (int i = 

[6/8] incubator-ignite git commit: # ignite-1265

2015-08-19 Thread sboikov
# ignite-1265


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

Branch: refs/heads/ignite-1.3.3-p3
Commit: 8b3fed850ccc4527a6593c5ec4e596ca6c08b61f
Parents: 5065a1e
Author: sboikov 
Authored: Wed Aug 19 09:32:54 2015 +0300
Committer: sboikov 
Committed: Wed Aug 19 10:26:10 2015 +0300

--
 .../CachePartialUpdateCheckedException.java | 11 ---
 ...teAtomicCacheEntryProcessorNodeJoinTest.java | 32 
 .../IgniteCacheEntryProcessorNodeJoinTest.java  | 25 ---
 .../testsuites/IgniteCacheTestSuite2.java   |  3 ++
 4 files changed, 55 insertions(+), 16 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8b3fed85/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CachePartialUpdateCheckedException.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CachePartialUpdateCheckedException.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CachePartialUpdateCheckedException.java
index c2259df..fc846f1 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CachePartialUpdateCheckedException.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CachePartialUpdateCheckedException.java
@@ -47,8 +47,9 @@ public class CachePartialUpdateCheckedException extends 
IgniteCheckedException {
  * Gets collection of failed keys.
  * @return Collection of failed keys.
  */
-public  Collection failedKeys() {
-return (Collection)failedKeys;
+@SuppressWarnings("unchecked")
+public synchronized  Collection failedKeys() {
+return new HashSet<>((Collection)failedKeys);
 }
 
 /**
@@ -56,7 +57,7 @@ public class CachePartialUpdateCheckedException extends 
IgniteCheckedException {
  * @param err Error.
  * @param topVer Topology version for failed update.
  */
-public void add(Collection failedKeys, Throwable err, 
AffinityTopologyVersion topVer) {
+public synchronized void add(Collection failedKeys, Throwable err, 
AffinityTopologyVersion topVer) {
 if (topVer != null) {
 AffinityTopologyVersion topVer0 = this.topVer;
 
@@ -72,7 +73,7 @@ public class CachePartialUpdateCheckedException extends 
IgniteCheckedException {
 /**
  * @return Topology version.
  */
-public AffinityTopologyVersion topologyVersion() {
+public synchronized AffinityTopologyVersion topologyVersion() {
 return topVer;
 }
 
@@ -80,7 +81,7 @@ public class CachePartialUpdateCheckedException extends 
IgniteCheckedException {
  * @param failedKeys Failed keys.
  * @param err Error.
  */
-public void add(Collection failedKeys, Throwable err) {
+public synchronized void add(Collection failedKeys, Throwable err) {
 add(failedKeys, err, null);
 }
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8b3fed85/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteAtomicCacheEntryProcessorNodeJoinTest.java
--
diff --git 
a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteAtomicCacheEntryProcessorNodeJoinTest.java
 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteAtomicCacheEntryProcessorNodeJoinTest.java
new file mode 100644
index 000..af87a7d
--- /dev/null
+++ 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteAtomicCacheEntryProcessorNodeJoinTest.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;
+
+import org.apache.ignite.cache.*;
+
+import static org.a

[2/8] incubator-ignite git commit: IGNITE-1265 - Rebuilt messages.

2015-08-19 Thread sboikov
IGNITE-1265 - Rebuilt messages.


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

Branch: refs/heads/ignite-1.3.3-p3
Commit: 574c6793adb96caa614b9c0c540f4812cfc52ee5
Parents: 7a43dde
Author: Alexey Goncharuk 
Authored: Tue Aug 18 11:11:43 2015 -0700
Committer: Alexey Goncharuk 
Committed: Tue Aug 18 11:11:43 2015 -0700

--
 .../processors/cache/GridCacheUtils.java| 11 +---
 .../distributed/dht/GridDhtTxPrepareFuture.java |  6 ++--
 .../dht/GridDhtTxPrepareResponse.java   | 29 +++-
 3 files changed, 32 insertions(+), 14 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/574c6793/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
index 1e3cd67..80e0d69 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
@@ -1684,15 +1684,18 @@ public class GridCacheUtils {
  * @param partsMap Cache ID to partition IDs collection map.
  * @return Cache ID to partition ID array map.
  */
-public static Map 
convertInvalidPartitions(Map> partsMap) {
-Map res = new HashMap<>(partsMap.size());
+public static Map convertInvalidPartitions(Map> partsMap) {
+Map res = new HashMap<>(partsMap.size());
 
 for (Map.Entry> entry : partsMap.entrySet()) {
 Set parts = entry.getValue();
 
-Integer[] partsArray = new Integer[parts.size()];
+int[] partsArray = new int[parts.size()];
 
-partsArray = parts.toArray(partsArray);
+int idx = 0;
+
+for (Integer part : parts)
+partsArray[idx++] = part;
 
 res.put(entry.getKey(), partsArray);
 }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/574c6793/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
index 27de8cf..2b7e1bc 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
@@ -1212,14 +1212,14 @@ public final class GridDhtTxPrepareFuture extends 
GridCompoundFuture invalidPartsMap = 
res.invalidPartitionsByCacheId();
+Map invalidPartsMap = 
res.invalidPartitionsByCacheId();
 
 for (Iterator it = 
dhtMapping.entries().iterator(); it.hasNext();) {
 IgniteTxEntry entry  = it.next();
 
-Integer[] invalidParts = 
invalidPartsMap.get(entry.cacheId());
+int[] invalidParts = 
invalidPartsMap.get(entry.cacheId());
 
-if (F.contains(invalidParts, 
entry.cached().partition())) {
+if (invalidParts != null && F.contains(invalidParts, 
entry.cached().partition())) {
 it.remove();
 
 if (log.isDebugEnabled())

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/574c6793/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareResponse.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareResponse.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareResponse.java
index cc85628..bcf7f8b 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareResponse.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareResponse.java
@@ -56,7 +56,8 @@ public class GridDhtTxPrepareResponse extends 
GridDistributedTxPrepare

incubator-ignite git commit: Minor (log message fix)

2015-08-19 Thread yzhdanov
Repository: incubator-ignite
Updated Branches:
  refs/heads/master e9a0d06ff -> e18147dd2


Minor (log message fix)


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

Branch: refs/heads/master
Commit: e18147dd219d01c26e4cd969c31d2984f96d6f1a
Parents: e9a0d06
Author: Yakov Zhdanov 
Authored: Wed Aug 19 16:36:23 2015 +0300
Committer: Yakov Zhdanov 
Committed: Wed Aug 19 16:36:23 2015 +0300

--
 .../main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java  | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/e18147dd/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 4f354ab..6c70eb1 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
@@ -4141,7 +4141,7 @@ class ServerImpl extends TcpDiscoveryImpl {
 (hasRemoteSrvNodes = ring.hasRemoteServerNodes())) {
 
 log.info("Local node seems to be disconnected from topology 
(failure detection timeout " +
-"is reached): [failureDetectionTimeout=" + 
spi.failureDetectionTimeout() +
+"is reached) [failureDetectionTimeout=" + 
spi.failureDetectionTimeout() +
 ", connCheckFreq=" + connCheckFreq + ']');
 
 failureThresholdReached = true;



[2/2] incubator-ignite git commit: Merge remote-tracking branch 'remotes/origin/master' into ignite-gg-9615-1

2015-08-19 Thread vozerov
Merge remote-tracking branch 'remotes/origin/master' into ignite-gg-9615-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/9e5fc85a
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/9e5fc85a
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/9e5fc85a

Branch: refs/heads/ignite-gg-9615-1
Commit: 9e5fc85ac20151c30e9bb4a69600aa2de09e4c14
Parents: 0a5f5e3 e18147d
Author: ptupitsyn 
Authored: Wed Aug 19 17:30:21 2015 +0300
Committer: ptupitsyn 
Committed: Wed Aug 19 17:30:21 2015 +0300

--
 .../main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java  | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
--




[1/2] incubator-ignite git commit: Minor (log message fix)

2015-08-19 Thread vozerov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-gg-9615-1 0a5f5e336 -> 9e5fc85ac


Minor (log message fix)


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

Branch: refs/heads/ignite-gg-9615-1
Commit: e18147dd219d01c26e4cd969c31d2984f96d6f1a
Parents: e9a0d06
Author: Yakov Zhdanov 
Authored: Wed Aug 19 16:36:23 2015 +0300
Committer: Yakov Zhdanov 
Committed: Wed Aug 19 16:36:23 2015 +0300

--
 .../main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java  | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/e18147dd/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 4f354ab..6c70eb1 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
@@ -4141,7 +4141,7 @@ class ServerImpl extends TcpDiscoveryImpl {
 (hasRemoteSrvNodes = ring.hasRemoteServerNodes())) {
 
 log.info("Local node seems to be disconnected from topology 
(failure detection timeout " +
-"is reached): [failureDetectionTimeout=" + 
spi.failureDetectionTimeout() +
+"is reached) [failureDetectionTimeout=" + 
spi.failureDetectionTimeout() +
 ", connCheckFreq=" + connCheckFreq + ']');
 
 failureThresholdReached = true;



incubator-ignite git commit: # ignite-1265 fix test

2015-08-19 Thread sboikov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-1.3.3-p3 7d1a550dc -> 7f928dc04


# ignite-1265 fix test


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

Branch: refs/heads/ignite-1.3.3-p3
Commit: 7f928dc048a9536e5c020b9baebe5637b0fd4ba6
Parents: 7d1a550
Author: sboikov 
Authored: Wed Aug 19 15:47:18 2015 +0300
Committer: sboikov 
Committed: Wed Aug 19 17:30:06 2015 +0300

--
 .../distributed/dht/GridDhtTxPrepareFuture.java |  52 ++-
 .../GridCacheTransformEventSelfTest.java|   2 +
 .../IgniteCacheCrossCacheTxFailoverTest.java| 433 +++
 ...idCachePartitionedHitsAndMissesSelfTest.java |  20 +-
 4 files changed, 475 insertions(+), 32 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/7f928dc0/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
index 1539a2a..08d02f2 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
@@ -295,25 +295,31 @@ public final class GridDhtTxPrepareFuture extends 
GridCompoundFuturehttp://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/7f928dc0/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheTransformEventSelfTest.java
--
diff --git 
a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheTransformEventSelfTest.java
 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheTransformEventSelfTest.java
index 459e015..d05764c 100644
--- 
a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheTransformEventSelfTest.java
+++ 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheTransformEventSelfTest.java
@@ -165,6 +165,8 @@ public class GridCacheTransformEventSelfTest extends 
GridCommonAbstractTest {
 
 startGrids(GRID_CNT);
 
+awaitPartitionMapExchange();
+
 ignites = new Ignite[GRID_CNT];
 ids = new UUID[GRID_CNT];
 caches = new IgniteCache[GRID_CNT];

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/7f928dc0/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/IgniteCacheCrossCacheTxFailoverTest.java
--
diff --git 
a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/IgniteCacheCrossCacheTxFailoverTest.java
 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/IgniteCacheCrossCacheTxFailoverTest.java
new file mode 100644
index 000..5432e76
--- /dev/null
+++ 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/IgniteCacheCrossCacheTxFailoverTest.java
@@ -0,0 +1,433 @@
+/*
+ * 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.dht;
+
+import org.apache.ignite.*;
+import org.apache.ignite.cache.*;
+import org.apache.ignite.cache.affinity.rendezvous.*;
+import org.apache.ignite.configuration.*;
+import org.apache.ignite.internal.*;
+import org.apache.ignite.internal.processors.affinity.*;
+import org.apache.ignite.spi

incubator-ignite git commit: IGNITE-843 WIP save/load db presets to/from mongo.

2015-08-19 Thread akuznetsov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-843 0993b4df0 -> e77e24567


IGNITE-843 WIP save/load db presets to/from mongo.


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

Branch: refs/heads/ignite-843
Commit: e77e245670a997a162968c6eae2406513edd9d90
Parents: 0993b4d
Author: AKuznetsov 
Authored: Wed Aug 19 21:46:36 2015 +0700
Committer: AKuznetsov 
Committed: Wed Aug 19 21:46:36 2015 +0700

--
 .../main/js/controllers/metadata-controller.js  | 25 
 .../src/main/js/public/stylesheets/style.scss   | 18 ++
 .../src/main/js/routes/presets.js   |  6 ++---
 .../js/views/configuration/metadata-load.jade   |  7 +++---
 4 files changed, 49 insertions(+), 7 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/e77e2456/modules/control-center-web/src/main/js/controllers/metadata-controller.js
--
diff --git 
a/modules/control-center-web/src/main/js/controllers/metadata-controller.js 
b/modules/control-center-web/src/main/js/controllers/metadata-controller.js
index cb0c501..3bedebe 100644
--- a/modules/control-center-web/src/main/js/controllers/metadata-controller.js
+++ b/modules/control-center-web/src/main/js/controllers/metadata-controller.js
@@ -229,6 +229,14 @@ controlCenterModule.controller('metadataController', [
 };
 
 $scope.loadMetadataFromDb = function () {
+$scope.preset.space = $scope.spaces[0];
+
+$http.post('presets/save', $scope.preset)
+.error(function (errMsg) {
+$common.showError(errMsg);
+});
+
+
 $http.post('/agent/metadata', $scope.preset)
 .success(function (tables) {
 $scope.loadMeta.tables = _.map(tables, function (tbl) {
@@ -315,6 +323,23 @@ controlCenterModule.controller('metadataController', [
 $common.showError(errMsg);
 });
 
+$http.post('presets/list')
+.success(function (data) {
+_.forEach(data.presets, function (restoredPreset) {
+var preset = _.find(presets, function (dfltPreset) {
+return dfltPreset.jdbcDriverClass == 
restoredPreset.jdbcDriverClass;
+});
+
+if (preset) {
+preset.jdbcUrl = restoredPreset.jdbcUrl;
+preset.user = restoredPreset.user;
+}
+});
+})
+.error(function (errMsg) {
+$common.showError(errMsg);
+});
+
 $scope.selectItem = function (item) {
 setSelectedAndBackupItem(item, angular.copy(item));
 };

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/e77e2456/modules/control-center-web/src/main/js/public/stylesheets/style.scss
--
diff --git 
a/modules/control-center-web/src/main/js/public/stylesheets/style.scss 
b/modules/control-center-web/src/main/js/public/stylesheets/style.scss
index 2b4a878..8447a9a 100644
--- a/modules/control-center-web/src/main/js/public/stylesheets/style.scss
+++ b/modules/control-center-web/src/main/js/public/stylesheets/style.scss
@@ -781,6 +781,10 @@ button .caret, .btn .caret {
 div {
 padding: 0
 }
+
+input[type="text"] {
+font-weight: normal;
+}
 }
 
 margin-bottom: 10px;
@@ -814,6 +818,20 @@ button .caret, .btn .caret {
 }
 }
 
+.theme-line table.metadata {
+tr:hover {
+cursor: default;
+}
+
+thead > tr th.header {
+input[type="text"] {
+font-weight: normal;
+}
+}
+
+margin-bottom: 10px;
+}
+
 .theme-line table.sql-results {
 [class*="col-"] {
 padding-left: 0 !important;

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/e77e2456/modules/control-center-web/src/main/js/routes/presets.js
--
diff --git a/modules/control-center-web/src/main/js/routes/presets.js 
b/modules/control-center-web/src/main/js/routes/presets.js
index 119102a..6bfdc48 100644
--- a/modules/control-center-web/src/main/js/routes/presets.js
+++ b/modules/control-center-web/src/main/js/routes/presets.js
@@ -49,15 +49,15 @@ router.post('/list', function (req, res) {
 router.post

incubator-ignite git commit: # ignite-1265 fix prepare future

2015-08-19 Thread sboikov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-1.3.3-p3 7f928dc04 -> 00417376c


# ignite-1265 fix prepare future


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

Branch: refs/heads/ignite-1.3.3-p3
Commit: 00417376c829c8a01cfc6ccbe5d328f01e23bf45
Parents: 7f928dc
Author: sboikov 
Authored: Wed Aug 19 17:48:47 2015 +0300
Committer: sboikov 
Committed: Wed Aug 19 17:48:47 2015 +0300

--
 .../distributed/dht/GridDhtTxPrepareFuture.java | 41 ++--
 1 file changed, 20 insertions(+), 21 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/00417376/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
index 08d02f2..cd51b7b 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
@@ -297,34 +297,33 @@ public final class GridDhtTxPrepareFuture extends 
GridCompoundFuture

Git Push Summary

2015-08-19 Thread sboikov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-1016 [deleted] 08597ac81


incubator-ignite git commit: ignite-1093

2015-08-19 Thread av
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-1093 9da4b9367 -> bd317a016


ignite-1093


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

Branch: refs/heads/ignite-1093
Commit: bd317a01658c8ad9a1cc30df3a000375e38c8666
Parents: 9da4b93
Author: Anton Vinogradov 
Authored: Wed Aug 19 13:07:28 2015 +0300
Committer: Anton Vinogradov 
Committed: Wed Aug 19 13:07:28 2015 +0300

--
 .../org/apache/ignite/configuration/CacheConfiguration.java   | 7 +--
 1 file changed, 5 insertions(+), 2 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/bd317a01/modules/core/src/main/java/org/apache/ignite/configuration/CacheConfiguration.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/configuration/CacheConfiguration.java
 
b/modules/core/src/main/java/org/apache/ignite/configuration/CacheConfiguration.java
index a19e136..0699124 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/configuration/CacheConfiguration.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/configuration/CacheConfiguration.java
@@ -1762,7 +1762,7 @@ public class CacheConfiguration extends 
MutableConfiguration {
  *
  * Gets number of batches generated by supply node at rebalancing start.
  *
- * @return
+ * @return batches count
  */
 public long getRebalanceBatchesCount() {
 return rebalanceBatchesCount;
@@ -1772,9 +1772,12 @@ public class CacheConfiguration extends 
MutableConfiguration {
  * Sets number of batches generated by supply node at rebalancing start.
  *
  * @param rebalanceBatchesCnt batches count.
+ * @return {@code this} for chaining.
  */
-public void setRebalanceBatchesCount(long rebalanceBatchesCnt) {
+public CacheConfiguration setRebalanceBatchesCount(long 
rebalanceBatchesCnt) {
 this.rebalanceBatchesCount = rebalanceBatchesCnt;
+
+return this;
 }
 
 /**



incubator-ignite git commit: IGNITE-843 WIP generate metadata from db tables meta.

2015-08-19 Thread akuznetsov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-843 e77e24567 -> 8a4334838


IGNITE-843 WIP generate metadata from db tables meta.


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

Branch: refs/heads/ignite-843
Commit: 8a43348381d577d3dc2a2ef278ffbcc49936e003
Parents: e77e245
Author: AKuznetsov 
Authored: Thu Aug 20 00:37:45 2015 +0700
Committer: AKuznetsov 
Committed: Thu Aug 20 00:37:45 2015 +0700

--
 .../main/js/controllers/metadata-controller.js  | 109 ---
 .../js/views/configuration/metadata-load.jade   |   2 +-
 2 files changed, 96 insertions(+), 15 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8a433483/modules/control-center-web/src/main/js/controllers/metadata-controller.js
--
diff --git 
a/modules/control-center-web/src/main/js/controllers/metadata-controller.js 
b/modules/control-center-web/src/main/js/controllers/metadata-controller.js
index 3bedebe..2d9b251 100644
--- a/modules/control-center-web/src/main/js/controllers/metadata-controller.js
+++ b/modules/control-center-web/src/main/js/controllers/metadata-controller.js
@@ -47,6 +47,53 @@ controlCenterModule.controller('metadataController', [
 $scope.hidePopover = $common.hidePopover;
 var showPopoverMessage = $common.showPopoverMessage;
 
+var JDBC_TYPES = [
+{dbName: 'BIT', dbType: -7, javaType: 'Boolean'},
+{dbName: 'TINYINT', dbType: -6, javaType: 'Byte'},
+{dbName: 'SMALLINT', dbType:  5, javaType: 'Short'},
+{dbName: 'INTEGER', dbType: 4, javaType: 'Integer'},
+{dbName: 'BIGINT', dbType: -5, javaType: 'Long'},
+{dbName: 'FLOAT', dbType: 6, javaType: 'Float'},
+{dbName: 'REAL', dbType: 7, javaType: 'Double'},
+{dbName: 'DOUBLE', dbType: 8, javaType: 'Double'},
+{dbName: 'NUMERIC', dbType: 2, javaType: 'BigDecimal'},
+{dbName: 'DECIMAL', dbType: 3, javaType: 'BigDecimal'},
+{dbName: 'CHAR', dbType: 1, javaType: 'String'},
+{dbName: 'VARCHAR', dbType: 12, javaType: 'String'},
+{dbName: 'LONGVARCHAR', dbType: -1, javaType: 'String'},
+{dbName: 'DATE', dbType: 91, javaType: 'Date'},
+{dbName: 'TIME', dbType: 92, javaType: 'Time'},
+{dbName: 'TIMESTAMP', dbType: 93, javaType: 'Timestamp'},
+{dbName: 'BINARY', dbType: -2, javaType: 'Object'},
+{dbName: 'VARBINARY', dbType: -3, javaType: 'Object'},
+{dbName: 'LONGVARBINARY', dbType: -4, javaType: 'Object'},
+{dbName: 'NULL', dbType: 0, javaType: 'Object'},
+{dbName: 'OTHER', dbType: , javaType: 'Object'},
+{dbName: 'JAVA_OBJECT', dbType: 2000, javaType: 'Object'},
+{dbName: 'DISTINCT', dbType: 2001, javaType: 'Object'},
+{dbName: 'STRUCT', dbType: 2002, javaType: 'Object'},
+{dbName: 'ARRAY', dbType: 2003, javaType: 'Object'},
+{dbName: 'BLOB', dbType: 2004, javaType: 'Object'},
+{dbName: 'CLOB', dbType: 2005, javaType: 'String'},
+{dbName: 'REF', dbType: 2006, javaType: 'Object'},
+{dbName: 'DATALINK', dbType: 70, javaType: 'Object'},
+{dbName: 'BOOLEAN', dbType: 16, javaType: 'Boolean'},
+{dbName: 'ROWID', dbType: -8, javaType: 'Object'},
+{dbName: 'NCHAR', dbType: -15, javaType: 'String'},
+{dbName: 'NVARCHAR', dbType: -9, javaType: 'String'},
+{dbName: 'LONGNVARCHAR', dbType: -16, javaType: 'String'},
+{dbName: 'NCLOB', dbType: 2011, javaType: 'String'},
+{dbName: 'SQLXML', dbType: 2009, javaType: 'Object'}
+];
+
+function _findJdbcType(jdbcType) {
+var res =  _.find(JDBC_TYPES, function (item) {
+return item.code == jdbcCode;
+});
+
+return res ? res : {dbName: 'Unknown', javaType: 'Unknown'}
+}
+
 var presets = [
 {
 db: 'oracle',
@@ -239,9 +286,7 @@ controlCenterModule.controller('metadataController', [
 
 $http.post('/agent/metadata', $scope.preset)
 .success(function (tables) {
-$scope.loadMeta.tables = _.map(tables, function (tbl) {
-  

[2/2] incubator-ignite git commit: IGNITE-1265 - Limit the node log output in a case of partition exchange timeout.

2015-08-19 Thread agoncharuk
IGNITE-1265 - Limit the node log output in a case of partition exchange timeout.


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

Branch: refs/heads/ignite-1.3.3-p3
Commit: 8ced20733da65bbd224d7dea61ab09d8dcfa2efc
Parents: d384d29
Author: Alexey Goncharuk 
Authored: Wed Aug 19 12:21:24 2015 -0700
Committer: Alexey Goncharuk 
Committed: Wed Aug 19 12:21:24 2015 -0700

--
 .../apache/ignite/IgniteSystemProperties.java   |  3 ++
 .../GridDhtPartitionsExchangeFuture.java| 32 +++-
 2 files changed, 27 insertions(+), 8 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8ced2073/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 7e96b29..7c808df 100644
--- a/modules/core/src/main/java/org/apache/ignite/IgniteSystemProperties.java
+++ b/modules/core/src/main/java/org/apache/ignite/IgniteSystemProperties.java
@@ -354,6 +354,9 @@ public final class IgniteSystemProperties {
 /** Number of cache operation retries in case of topology exceptions. */
 public static final String IGNITE_CACHE_RETRIES_COUNT = 
"IGNITE_CACHE_RETRIES_COUNT";
 
+/** Number of times pending cache objects will be dumped to the log in 
case of partition exchange timeout. */
+public static final String IGNITE_DUMP_PENDING_OBJECTS_THRESHOLD = 
"IGNITE_DUMP_PENDING_OBJECTS_THRESHOLD";
+
 /**
  * Enforces singleton.
  */

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8ced2073/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPartitionsExchangeFuture.java
--
diff --git 
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
index 5701749..4971ca6 100644
--- 
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
@@ -54,6 +54,10 @@ import static 
org.apache.ignite.internal.managers.communication.GridIoPolicy.*;
 public class GridDhtPartitionsExchangeFuture extends 
GridFutureAdapter
 implements Comparable, 
GridDhtTopologyFuture {
 /** */
+private static final int DUMP_PENDING_OBJECTS_THRESHOLD =
+
IgniteSystemProperties.getInteger(IgniteSystemProperties.IGNITE_DUMP_PENDING_OBJECTS_THRESHOLD,
 10);
+
+/** */
 private static final long serialVersionUID = 0L;
 
 /** Dummy flag. */
@@ -722,6 +726,8 @@ public class GridDhtPartitionsExchangeFuture extends 
GridFutureAdapter locksFut = 
cctx.mvcc().finishLocks(exchId.topologyVersion());
 
+dumpedObjects = 0;
+
 while (true) {
 try {
 locksFut.get(2 * 
cctx.gridConfig().getNetworkTimeout(), TimeUnit.MILLISECONDS);
@@ -749,16 +761,20 @@ public class GridDhtPartitionsExchangeFuture extends 
GridFutureAdapter> 
locks =
-
cctx.mvcc().unfinishedLocks(exchId.topologyVersion());
+Map> locks =
+
cctx.mvcc().unfinishedLocks(exchId.topologyVersion());
 
-for (Map.Entry> e : locks.entrySet())
-U.warn(log, "Locked entry [key=" + e.getKey() + ", 
mvcc=" + e.getValue() + ']');
+for (Map.Entry> e : locks.entrySet())
+U.warn(log, "Locked entry [key=" + e.getKey() 
+ ", mvcc=" + e.getValue() + ']');
+
+dumpedObjects++;
+}
 }
 }
 



[1/2] incubator-ignite git commit: IGNITE-1265 - Corrected assertion in marshaller cache.

2015-08-19 Thread agoncharuk
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-1.3.3-p3 00417376c -> 8ced20733


IGNITE-1265 - Corrected assertion in marshaller cache.


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

Branch: refs/heads/ignite-1.3.3-p3
Commit: d384d2901250f64e470feda9e4b34763b9420976
Parents: 0041737
Author: Alexey Goncharuk 
Authored: Wed Aug 19 11:47:19 2015 -0700
Committer: Alexey Goncharuk 
Committed: Wed Aug 19 11:47:19 2015 -0700

--
 .../ignite/internal/MarshallerContextImpl.java  | 22 
 1 file changed, 13 insertions(+), 9 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/d384d290/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 9f7c983..87bd3b6 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
@@ -19,6 +19,7 @@ package org.apache.ignite.internal;
 
 import org.apache.ignite.*;
 import org.apache.ignite.internal.processors.cache.*;
+import org.apache.ignite.internal.util.typedef.*;
 import org.apache.ignite.internal.util.typedef.internal.*;
 import org.apache.ignite.plugin.*;
 
@@ -177,18 +178,21 @@ public class MarshallerContextImpl extends 
MarshallerContextAdapter {
 @Override public void onUpdated(Iterable> events)
 throws CacheEntryListenerException {
 for (CacheEntryEvent evt : 
events) {
-assert evt.getOldValue() == null : "Received non-null old 
value for system marshaller cache: " + evt;
+assert evt.getOldValue() == null || F.eq(evt.getOldValue(), 
evt.getValue()):
+"Received cache entry update for system marshaller cache: 
" + evt;
 
-File file = new File(workDir, evt.getKey() + ".classname");
+if (evt.getOldValue() == null) {
+File file = new File(workDir, evt.getKey() + ".classname");
 
-try (Writer writer = new FileWriter(file)) {
-writer.write(evt.getValue());
+try (Writer writer = new FileWriter(file)) {
+writer.write(evt.getValue());
 
-writer.flush();
-}
-catch (IOException e) {
-U.error(log, "Failed to write class name to file [id=" + 
evt.getKey() +
-", clsName=" + evt.getValue() + ", file=" + 
file.getAbsolutePath() + ']', e);
+writer.flush();
+}
+catch (IOException e) {
+U.error(log, "Failed to write class name to file [id=" 
+ evt.getKey() +
+", clsName=" + evt.getValue() + ", file=" + 
file.getAbsolutePath() + ']', e);
+}
 }
 }
 }



incubator-ignite git commit: # IGNITE-843 Rename rest.

2015-08-19 Thread anovikov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-843 8a4334838 -> a9af67435


# IGNITE-843 Rename rest.


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

Branch: refs/heads/ignite-843
Commit: a9af6743599e04ea7b5fac6c70f3f5ccdd55cfaa
Parents: 8a43348
Author: Andrey 
Authored: Thu Aug 20 10:41:07 2015 +0700
Committer: Andrey 
Committed: Thu Aug 20 10:41:07 2015 +0700

--
 .../src/main/js/controllers/common-module.js| 51 +++-
 .../main/js/controllers/profile-controller.js   |  4 +-
 .../src/main/js/controllers/sql-controller.js   | 34 +++--
 .../src/main/js/public/stylesheets/style.scss   |  8 +++
 .../src/main/js/routes/agent.js |  4 +-
 .../src/main/js/routes/notebooks.js | 39 +--
 .../src/main/js/routes/profile.js   | 13 +
 .../src/main/js/routes/public.js| 10 ++--
 .../src/main/js/views/includes/header.jade  |  6 +--
 .../src/main/js/views/login.jade| 14 +++---
 .../src/main/js/views/sql/sql.jade  | 10 ++--
 11 files changed, 128 insertions(+), 65 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/a9af6743/modules/control-center-web/src/main/js/controllers/common-module.js
--
diff --git 
a/modules/control-center-web/src/main/js/controllers/common-module.js 
b/modules/control-center-web/src/main/js/controllers/common-module.js
index d30292f..674940f 100644
--- a/modules/control-center-web/src/main/js/controllers/common-module.js
+++ b/modules/control-center-web/src/main/js/controllers/common-module.js
@@ -1100,7 +1100,7 @@ controlCenterModule.controller('auth', [
 if (status == 403) {
 loginModal.hide();
 
-$window.location = '/reset';
+$window.location = '/password/reset';
 }
 else
 $common.showError(data, 'top', '#errors-container');
@@ -1109,7 +1109,7 @@ controlCenterModule.controller('auth', [
 
 // Try to reset user password for provided token.
 $scope.resetPassword = function (reset_info) {
-$http.post('/reset_password', reset_info)
+$http.post('/password/reset', reset_info)
 .success(function (data) {
 $scope.user_info = {email: data};
 $scope.login();
@@ -1129,7 +1129,7 @@ controlCenterModule.controller('auth', [
 controlCenterModule.controller('agent-download', [
 '$scope', '$modal', function ($scope, $modal) {
 // Pre-fetch modal dialogs.
-var _agentDownloadModal = $modal({scope: $scope, templateUrl: 
'/agent/agent-download', show: false});
+var _agentDownloadModal = $modal({scope: $scope, templateUrl: 
'/agent/download', show: false});
 
 $scope.downloadAgent = function () {
 _agentDownloadModal.hide();
@@ -1152,31 +1152,36 @@ controlCenterModule.controller('agent-download', [
 }]);
 
 // Navigation bar controller.
-controlCenterModule.controller('notebooks', [
-'$scope', '$http', '$common', function ($scope, $http, $common) {
-$scope.notebooks = [];
+controlCenterModule.controller('notebooks', ['$scope', '$http', '$common', 
function ($scope, $http, $common) {
+$scope.$root.notebooks = [];
 
+$scope.$root.rebuildDropdown = function () {
+$scope.notebookDropdown = [
+{text: 'Create new notebook', href: '/notebooks/new', target: 
'_self'},
+{divider: true}
+];
+
+_.forEach($scope.$root.notebooks, function (notebook) {
+$scope.notebookDropdown.push({
+text: notebook.name,
+href: '/sql/' + notebook._id,
+target: '_self'
+});
+});
+};
+
+$scope.$root.reloadNotebooks = function () {
 // When landing on the page, get clusters and show them.
 $http.post('/notebooks/list')
 .success(function (data) {
-$scope.notebooks = data;
-
-if ($scope.notebooks.length > 0) {
-$scope.notebookDropdown = [
-{text: 'Create new notebook', href: '/notebooks/new', 
target: '_self'},
-{divider: true}
-];
-
-_.forEach($scope.notebooks, function (notebook) {
-$scope.notebookDropdown.push({
-text: notebook.name,
- 

[3/4] incubator-ignite git commit: Merge remote-tracking branch 'origin/ignite-843' into ignite-843

2015-08-19 Thread akuznetsov
Merge remote-tracking branch 'origin/ignite-843' into ignite-843


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

Branch: refs/heads/ignite-843
Commit: c43eb9b3c42a462c53ad3a148da8a6e1034a4bc7
Parents: 900e4b8 a9af674
Author: Alexey Kuznetsov 
Authored: Thu Aug 20 10:42:57 2015 +0700
Committer: Alexey Kuznetsov 
Committed: Thu Aug 20 10:42:57 2015 +0700

--
 .../src/main/js/controllers/common-module.js| 51 +++-
 .../main/js/controllers/profile-controller.js   |  4 +-
 .../src/main/js/controllers/sql-controller.js   | 34 +++--
 .../src/main/js/public/stylesheets/style.scss   |  8 +++
 .../src/main/js/routes/agent.js |  4 +-
 .../src/main/js/routes/notebooks.js | 39 +--
 .../src/main/js/routes/profile.js   | 13 +
 .../src/main/js/routes/public.js| 10 ++--
 .../src/main/js/views/includes/header.jade  |  6 +--
 .../src/main/js/views/login.jade| 14 +++---
 .../src/main/js/views/sql/sql.jade  | 10 ++--
 11 files changed, 128 insertions(+), 65 deletions(-)
--




[4/4] incubator-ignite git commit: IGNITE-843: WIP load metadata from db.

2015-08-19 Thread akuznetsov
IGNITE-843: WIP load metadata from db.


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

Branch: refs/heads/ignite-843
Commit: 76d999b3d2458c40f3454f3dcf0cd9e10f5b0d9d
Parents: c43eb9b
Author: Alexey Kuznetsov 
Authored: Thu Aug 20 11:38:18 2015 +0700
Committer: Alexey Kuznetsov 
Committed: Thu Aug 20 11:38:18 2015 +0700

--
 .../main/js/controllers/clusters-controller.js  |  35 ++-
 .../src/main/js/controllers/common-module.js|  52 +-
 .../main/js/controllers/metadata-controller.js  | 102 +--
 .../js/views/configuration/metadata-load.jade   |  17 +++-
 .../src/main/js/views/includes/controls.jade|   4 +-
 5 files changed, 117 insertions(+), 93 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/76d999b3/modules/control-center-web/src/main/js/controllers/clusters-controller.js
--
diff --git 
a/modules/control-center-web/src/main/js/controllers/clusters-controller.js 
b/modules/control-center-web/src/main/js/controllers/clusters-controller.js
index 1ad20d7..3ed69f3 100644
--- a/modules/control-center-web/src/main/js/controllers/clusters-controller.js
+++ b/modules/control-center-web/src/main/js/controllers/clusters-controller.js
@@ -66,40 +66,17 @@ controlCenterModule.controller('clustersController', 
['$scope', '$http', '$commo
 }
 }
 
-$scope.cacheModes = [
-{value: 'LOCAL', label: 'LOCAL'},
-{value: 'REPLICATED', label: 'REPLICATED'},
-{value: 'PARTITIONED', label: 'PARTITIONED'}
-];
+$scope.cacheModes = $common.mkOptions(['LOCAL', 'REPLICATED', 
'PARTITIONED']);
 
-$scope.deploymentModes = [
-{value: 'PRIVATE', label: 'PRIVATE'},
-{value: 'ISOLATED', label: 'ISOLATED'},
-{value: 'SHARED', label: 'SHARED'},
-{value: 'CONTINUOUS', label: 'CONTINUOUS'}
-];
+$scope.deploymentModes = $common.mkOptions(['PRIVATE', 'ISOLATED', 
'SHARED', 'CONTINUOUS']);
 
-$scope.transactionConcurrency = [
-{value: 'OPTIMISTIC', label: 'OPTIMISTIC'},
-{value: 'PESSIMISTIC', label: 'PESSIMISTIC'}
-];
+$scope.transactionConcurrency = $common.mkOptions(['OPTIMISTIC', 
'PESSIMISTIC']);
 
-$scope.transactionIsolation = [
-{value: 'READ_COMMITTED', label: 'READ_COMMITTED'},
-{value: 'REPEATABLE_READ', label: 'REPEATABLE_READ'},
-{value: 'SERIALIZABLE', label: 'SERIALIZABLE'}
-];
+$scope.transactionIsolation = $common.mkOptions(['READ_COMMITTED', 
'REPEATABLE_READ', 'SERIALIZABLE']);
 
-$scope.segmentationPolicy = [
-{value: 'RESTART_JVM', label: 'RESTART_JVM'},
-{value: 'STOP', label: 'STOP'},
-{value: 'NOOP', label: 'NOOP'}
-];
+$scope.segmentationPolicy = $common.mkOptions(['RESTART_JVM', 'STOP', 
'NOOP']);
 
-$scope.marshallers = [
-{value: 'OptimizedMarshaller', label: 'OptimizedMarshaller'},
-{value: 'JdkMarshaller', label: 'JdkMarshaller'}
-];
+$scope.marshallers = $common.mkOptions(['OptimizedMarshaller', 
'JdkMarshaller']);
 
 $scope.ui = {expanded: false};
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/76d999b3/modules/control-center-web/src/main/js/controllers/common-module.js
--
diff --git 
a/modules/control-center-web/src/main/js/controllers/common-module.js 
b/modules/control-center-web/src/main/js/controllers/common-module.js
index 674940f..8ddec82 100644
--- a/modules/control-center-web/src/main/js/controllers/common-module.js
+++ b/modules/control-center-web/src/main/js/controllers/common-module.js
@@ -123,12 +123,51 @@ controlCenterModule.service('$common', [
 return _.contains(javaBuildInClasses, cls) || 
_.contains(javaBuildInFullNameClasses, cls);
 }
 
-var JDBC_TYPES = [
+var SUPPORTED_JDBC_TYPES = [
 'BIT', 'BOOLEAN', 'TINYINT', 'SMALLINT', 'INTEGER', 'BIGINT', 
'REAL', 'FLOAT', 'DOUBLE',
 'NUMERIC', 'DECIMAL', 'CHAR', 'VARCHAR', 'LONGVARCHAR', 'NCHAR', 
'NVARCHAR', 'LONGNVARCHAR',
 'DATE', 'TIME', 'TIMESTAMP'
 ];
 
+var ALL_JDBC_TYPES = [
+{dbName: 'BIT', dbType: -7, javaType: 'Boolean'},
+{dbName: 'TINYINT', dbType: -6, javaType: 'Byte'},
+{dbName: 'SMALLINT', dbType:  5, javaType: 'Short'},
+{dbName: 'INTEGER',

[1/4] incubator-ignite git commit: Minor (log message fix)

2015-08-19 Thread akuznetsov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-843 a9af67435 -> 76d999b3d


Minor (log message fix)


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

Branch: refs/heads/ignite-843
Commit: e18147dd219d01c26e4cd969c31d2984f96d6f1a
Parents: e9a0d06
Author: Yakov Zhdanov 
Authored: Wed Aug 19 16:36:23 2015 +0300
Committer: Yakov Zhdanov 
Committed: Wed Aug 19 16:36:23 2015 +0300

--
 .../main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java  | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/e18147dd/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 4f354ab..6c70eb1 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
@@ -4141,7 +4141,7 @@ class ServerImpl extends TcpDiscoveryImpl {
 (hasRemoteSrvNodes = ring.hasRemoteServerNodes())) {
 
 log.info("Local node seems to be disconnected from topology 
(failure detection timeout " +
-"is reached): [failureDetectionTimeout=" + 
spi.failureDetectionTimeout() +
+"is reached) [failureDetectionTimeout=" + 
spi.failureDetectionTimeout() +
 ", connCheckFreq=" + connCheckFreq + ']');
 
 failureThresholdReached = true;



[2/4] incubator-ignite git commit: Merge branches 'ignite-843' and 'master' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-843

2015-08-19 Thread akuznetsov
Merge branches 'ignite-843' and 'master' of 
https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-843


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

Branch: refs/heads/ignite-843
Commit: 900e4b824f8cc530f7df99f6e7e7bf132fef8d17
Parents: 8a43348 e18147d
Author: Alexey Kuznetsov 
Authored: Thu Aug 20 09:52:56 2015 +0700
Committer: Alexey Kuznetsov 
Committed: Thu Aug 20 09:52:56 2015 +0700

--
 .../main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java  | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
--




incubator-ignite git commit: IGNITE-1265 - Added ready future to ClusterTopologyException, added test for correct explicit transaction retries.

2015-08-19 Thread agoncharuk
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-1.3.3-p3 8ced20733 -> 8f1c1c0d7


IGNITE-1265 - Added ready future to ClusterTopologyException, added test for 
correct explicit transaction retries.


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

Branch: refs/heads/ignite-1.3.3-p3
Commit: 8f1c1c0d7406f9b43681a6da69560c8ba6bbb737
Parents: 8ced207
Author: Alexey Goncharuk 
Authored: Wed Aug 19 22:55:48 2015 -0700
Committer: Alexey Goncharuk 
Committed: Wed Aug 19 22:55:48 2015 -0700

--
 .../cluster/ClusterTopologyException.java   |  18 ++
 .../ClusterTopologyCheckedException.java|  18 ++
 .../cache/GridCacheSharedContext.java   |  15 ++
 .../colocated/GridDhtColocatedLockFuture.java   |   8 +-
 .../distributed/near/GridNearLockFuture.java|   8 +-
 .../near/GridNearOptimisticTxPrepareFuture.java |   7 +-
 .../GridNearPessimisticTxPrepareFuture.java |   7 +-
 .../ignite/internal/util/IgniteUtils.java   |   9 +-
 .../IgniteCachePutRetryAbstractSelfTest.java|   1 +
 ...gniteCachePutRetryTransactionalSelfTest.java | 179 +++
 10 files changed, 263 insertions(+), 7 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8f1c1c0d/modules/core/src/main/java/org/apache/ignite/cluster/ClusterTopologyException.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/cluster/ClusterTopologyException.java
 
b/modules/core/src/main/java/org/apache/ignite/cluster/ClusterTopologyException.java
index d28c409..61bc367 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/cluster/ClusterTopologyException.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/cluster/ClusterTopologyException.java
@@ -18,6 +18,7 @@
 package org.apache.ignite.cluster;
 
 import org.apache.ignite.*;
+import org.apache.ignite.lang.*;
 import org.jetbrains.annotations.*;
 
 /**
@@ -27,6 +28,9 @@ public class ClusterTopologyException extends IgniteException 
{
 /** */
 private static final long serialVersionUID = 0L;
 
+/** Retry ready future. */
+private transient IgniteFuture readyFut;
+
 /**
  * Creates new topology exception with given error message.
  *
@@ -46,4 +50,18 @@ public class ClusterTopologyException extends 
IgniteException {
 public ClusterTopologyException(String msg, @Nullable Throwable cause) {
 super(msg, cause);
 }
+
+/**
+ * @return Retry ready future.
+ */
+public IgniteFuture retryReadyFuture() {
+return readyFut;
+}
+
+/**
+ * @param readyFut Retry ready future.
+ */
+public void retryReadyFuture(IgniteFuture readyFut) {
+this.readyFut = readyFut;
+}
 }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8f1c1c0d/modules/core/src/main/java/org/apache/ignite/internal/cluster/ClusterTopologyCheckedException.java
--
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/cluster/ClusterTopologyCheckedException.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/cluster/ClusterTopologyCheckedException.java
index 8f985b4..2d7b0de 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/cluster/ClusterTopologyCheckedException.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/cluster/ClusterTopologyCheckedException.java
@@ -18,6 +18,7 @@
 package org.apache.ignite.internal.cluster;
 
 import org.apache.ignite.*;
+import org.apache.ignite.internal.*;
 import org.jetbrains.annotations.*;
 
 /**
@@ -27,6 +28,9 @@ public class ClusterTopologyCheckedException extends 
IgniteCheckedException {
 /** */
 private static final long serialVersionUID = 0L;
 
+/** Next topology version to wait. */
+private transient IgniteInternalFuture readyFut;
+
 /**
  * Creates new topology exception with given error message.
  *
@@ -46,4 +50,18 @@ public class ClusterTopologyCheckedException extends 
IgniteCheckedException {
 public ClusterTopologyCheckedException(String msg, @Nullable Throwable 
cause) {
 super(msg, cause);
 }
+
+/**
+ * @return Retry ready future.
+ */
+public IgniteInternalFuture retryReadyFuture() {
+return readyFut;
+}
+
+/**
+ * @param readyFut Retry ready future.
+ */
+public void retryReadyFuture(IgniteInternalFuture readyFut) {
+this.readyFut = readyFut;
+}
 }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8f1c1c0d/modules/core/src/mai

incubator-ignite git commit: IGNITE-843: WIP load metadata from db.

2015-08-19 Thread akuznetsov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-843 76d999b3d -> 903e23467


IGNITE-843: WIP load metadata from db.


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

Branch: refs/heads/ignite-843
Commit: 903e2346777a7a6b5cf85ec0d9ff286095623662
Parents: 76d999b
Author: Alexey Kuznetsov 
Authored: Thu Aug 20 13:13:25 2015 +0700
Committer: Alexey Kuznetsov 
Committed: Thu Aug 20 13:13:25 2015 +0700

--
 .../src/main/js/controllers/metadata-controller.js| 10 ++
 1 file changed, 10 insertions(+)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/903e2346/modules/control-center-web/src/main/js/controllers/metadata-controller.js
--
diff --git 
a/modules/control-center-web/src/main/js/controllers/metadata-controller.js 
b/modules/control-center-web/src/main/js/controllers/metadata-controller.js
index 42d115e..5eab839 100644
--- a/modules/control-center-web/src/main/js/controllers/metadata-controller.js
+++ b/modules/control-center-web/src/main/js/controllers/metadata-controller.js
@@ -309,6 +309,11 @@ controlCenterModule.controller('metadataController', [
 return {name: toJavaName(name), className: 
jdbcType.javaType}
 }
 
+function dbField(name, jdbcType) {
+return {databaseName: name, databaseType: 
jdbcType.dbName,
+javaName: toJavaName(name), javaType: 
jdbcType.javaType}
+}
+
 _.forEach(table.cols, function(col) {
 var name = col.name;
 var jdbcType = $common.findJdbcType(col.type);
@@ -320,6 +325,11 @@ controlCenterModule.controller('metadataController', [
 
 if (_.includes(table.descCols, name))
 descFields.push(queryField(name, jdbcType));
+
+if (col.key)
+keyFields.push(dbField(name, jdbcType));
+
+valFields.push(dbField(name, jdbcType));
 });
 
 var newItem = {



[2/2] incubator-ignite git commit: Merge remote-tracking branch 'origin/ignite-843' into ignite-843

2015-08-19 Thread anovikov
Merge remote-tracking branch 'origin/ignite-843' into ignite-843


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

Branch: refs/heads/ignite-843
Commit: c50535dbf6a051a0985ebdd39bb4507a1b665203
Parents: fb0f317 903e234
Author: Andrey 
Authored: Thu Aug 20 13:21:21 2015 +0700
Committer: Andrey 
Committed: Thu Aug 20 13:21:21 2015 +0700

--
 .../main/js/controllers/clusters-controller.js  |  35 +-
 .../src/main/js/controllers/common-module.js|  52 -
 .../main/js/controllers/metadata-controller.js  | 112 ++-
 .../js/views/configuration/metadata-load.jade   |  17 ++-
 .../src/main/js/views/includes/controls.jade|   4 +-
 .../ignite/spi/discovery/tcp/ServerImpl.java|   2 +-
 6 files changed, 128 insertions(+), 94 deletions(-)
--




[1/2] incubator-ignite git commit: # IGNITE-843 Refactoring.

2015-08-19 Thread anovikov
Repository: incubator-ignite
Updated Branches:
  refs/heads/ignite-843 903e23467 -> c50535dbf


# IGNITE-843 Refactoring.


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

Branch: refs/heads/ignite-843
Commit: fb0f3178f733a2f13f5d2416c030c0f1852c3f05
Parents: a9af674
Author: Andrey 
Authored: Thu Aug 20 13:20:58 2015 +0700
Committer: Andrey 
Committed: Thu Aug 20 13:20:58 2015 +0700

--
 .../src/main/js/routes/generator/common.js  | 42 +---
 .../src/main/js/routes/generator/java.js|  9 +++--
 .../src/main/js/routes/generator/xml.js |  9 +++--
 .../src/main/js/routes/notebooks.js | 10 ++---
 .../src/main/js/routes/public.js|  6 +--
 .../src/main/js/routes/utils.js | 37 +
 6 files changed, 64 insertions(+), 49 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/fb0f3178/modules/control-center-web/src/main/js/routes/generator/common.js
--
diff --git a/modules/control-center-web/src/main/js/routes/generator/common.js 
b/modules/control-center-web/src/main/js/routes/generator/common.js
index 85b9331..a7a2399 100644
--- a/modules/control-center-web/src/main/js/routes/generator/common.js
+++ b/modules/control-center-web/src/main/js/routes/generator/common.js
@@ -16,21 +16,14 @@
  */
 
 var _ = require('lodash');
+var utils = require('../utils');
 
-function isDefined(v) {
-return !(v === undefined || v === null);
-}
-
-exports.isDefined = isDefined;
-
-exports.mainComment = mainComment;
-
-function mainComment() {
+exports.mainComment = function mainComment() {
 return 'This configuration was generated by Ignite Control Center ('
-+ formatDate(new Date()) + ')';
-}
++ exports.formatDate(new Date()) + ')';
+};
 
-function addLeadingZero(numberStr, minSize) {
+function _addLeadingZero(numberStr, minSize) {
 if (typeof (numberStr) != 'string')
 numberStr = '' + numberStr;
 
@@ -41,16 +34,14 @@ function addLeadingZero(numberStr, minSize) {
 return numberStr;
 }
 
-exports.formatDate = formatDate;
-
-function formatDate(date) {
-var dd = addLeadingZero(date.getDate(), 2);
-var mm = addLeadingZero(date.getMonth() + 1, 2);
+exports.formatDate = function formatDate(date) {
+var dd = _addLeadingZero(date.getDate(), 2);
+var mm = _addLeadingZero(date.getMonth() + 1, 2);
 
 var  = date.getFullYear();
 
-return mm + '/' + dd + '/' +  + ' ' + addLeadingZero(date.getHours(), 
2) + ':' + addLeadingZero(date.getMinutes(), 2);
-}
+return mm + '/' + dd + '/' +  + ' ' + _addLeadingZero(date.getHours(), 
2) + ':' + _addLeadingZero(date.getMinutes(), 2);
+};
 
 exports.builder = function () {
 var res = [];
@@ -209,7 +200,7 @@ exports.javaBuildInClass = javaBuildInClass;
  * @returns 'true' if given class name is a java build-in type.
  */
 exports.isJavaBuildInClass = function (className) {
-return isDefined(javaBuildInClasses[className]);
+return utils.isDefined(javaBuildInClasses[className]);
 };
 
 exports.knownClasses = {
@@ -275,17 +266,6 @@ exports.transactionConfiguration = new 
ClassDescriptor('org.apache.ignite.config
 txSerializableEnabled: null
 });
 
-exports.hasProperty = function (obj, props) {
-for (var propName in props) {
-if (props.hasOwnProperty(propName)) {
-if (obj[propName])
-return true;
-}
-}
-
-return false;
-};
-
 /**
  * Generate properties file with properties stubs for stores data sources.
  *

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/fb0f3178/modules/control-center-web/src/main/js/routes/generator/java.js
--
diff --git a/modules/control-center-web/src/main/js/routes/generator/java.js 
b/modules/control-center-web/src/main/js/routes/generator/java.js
index 4186573..d27fe6a 100644
--- a/modules/control-center-web/src/main/js/routes/generator/java.js
+++ b/modules/control-center-web/src/main/js/routes/generator/java.js
@@ -18,6 +18,7 @@
 var _ = require('lodash');
 
 var generatorCommon = require("./common");
+var utils = require("../utils");
 
 /**
  * Convert some name to valid java name.
@@ -138,7 +139,7 @@ exports.generateClusterConfiguration = function (cluster, 
javaClass, clientNearC
 
 declareVariable(res, true, 'ipFinder', 
'org.apache.ignite.spi.discovery.tcp.ipfinder.jdbc.TcpDiscoveryJdbcIpFinder');
 
-res.line('ipFinder.setInitSchema(' + 
(generatorCommon.i