[2/6] incubator-ignite git commit: # ignite-sprint-6 added test for lastSuccessfulAddress
# ignite-sprint-6 added test for lastSuccessfulAddress Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/d699faa3 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/d699faa3 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/d699faa3 Branch: refs/heads/ignite-965 Commit: d699faa34d66b8e5f1487daf3386c4d677d8c1e5 Parents: 4d9868a Author: sboikov Authored: Fri Jun 19 13:01:51 2015 +0300 Committer: sboikov Committed: Fri Jun 19 13:01:51 2015 +0300 -- .../spi/discovery/tcp/TcpDiscoverySelfTest.java | 44 ++-- 1 file changed, 41 insertions(+), 3 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/d699faa3/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySelfTest.java -- diff --git a/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySelfTest.java b/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySelfTest.java index ad12753..9a44c24 100644 --- a/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySelfTest.java @@ -149,9 +149,47 @@ public class TcpDiscoverySelfTest extends GridCommonAbstractTest { */ public void testThreeNodesStartStop() throws Exception { try { -startGrid(1); -startGrid(2); -startGrid(3); +IgniteEx ignite1 = startGrid(1); +IgniteEx ignite2 = startGrid(2); +IgniteEx ignite3 = startGrid(3); + +TcpDiscoverySpi spi1 = (TcpDiscoverySpi)ignite1.configuration().getDiscoverySpi(); +TcpDiscoverySpi spi2 = (TcpDiscoverySpi)ignite2.configuration().getDiscoverySpi(); +TcpDiscoverySpi spi3 = (TcpDiscoverySpi)ignite3.configuration().getDiscoverySpi(); + +TcpDiscoveryNode node = (TcpDiscoveryNode)spi1.getNode(ignite2.localNode().id()); + +assertNotNull(node); +assertNotNull(node.lastSuccessfulAddress()); + +LinkedHashSet addrs = spi1.getNodeAddresses(node); + +assertEquals(addrs.iterator().next(), node.lastSuccessfulAddress()); + +assertTrue(spi1.pingNode(ignite3.localNode().id())); + +node = (TcpDiscoveryNode)spi1.getNode(ignite3.localNode().id()); + +assertNotNull(node); +assertNotNull(node.lastSuccessfulAddress()); + +addrs = spi1.getNodeAddresses(node); +assertEquals(addrs.iterator().next(), node.lastSuccessfulAddress()); + +node = (TcpDiscoveryNode)spi2.getNode(ignite1.localNode().id()); + +assertNotNull(node); +assertNotNull(node.lastSuccessfulAddress()); + +node = (TcpDiscoveryNode)spi2.getNode(ignite3.localNode().id()); + +assertNotNull(node); +assertNotNull(node.lastSuccessfulAddress()); + +node = (TcpDiscoveryNode)spi3.getNode(ignite1.localNode().id()); + +assertNotNull(node); +assertNotNull(node.lastSuccessfulAddress()); } finally { stopAllGrids();
[6/6] incubator-ignite git commit: #ignite-965: IgniteCompute.affinityRun nodejs run script on node with key.
#ignite-965: IgniteCompute.affinityRun nodejs run script on node with key. Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/4a1db957 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/4a1db957 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/4a1db957 Branch: refs/heads/ignite-965 Commit: 4a1db957c59a8cf25dd443b3f77016db7e1519e7 Parents: eb5cc43 Author: ivasilinets Authored: Sun Jun 21 19:45:43 2015 +0300 Committer: ivasilinets Committed: Sun Jun 21 19:45:43 2015 +0300 -- .../compute/IgniteComputeCommandHandler.java| 23 + .../rest/request/RestComputeRequest.java| 34 modules/nodejs/src/main/js/compute.js | 8 +++-- .../ignite/internal/NodeJsComputeSelfTest.java | 7 +--- modules/nodejs/src/test/js/test-compute.js | 14 +++- .../http/jetty/GridJettyRestHandler.java| 2 ++ 6 files changed, 73 insertions(+), 15 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/4a1db957/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/handlers/compute/IgniteComputeCommandHandler.java -- diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/handlers/compute/IgniteComputeCommandHandler.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/handlers/compute/IgniteComputeCommandHandler.java index b48e2d4..f3da040 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/handlers/compute/IgniteComputeCommandHandler.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/handlers/compute/IgniteComputeCommandHandler.java @@ -24,6 +24,8 @@ import org.apache.ignite.internal.processors.rest.handlers.*; import org.apache.ignite.internal.processors.rest.request.*; import org.apache.ignite.internal.util.future.*; import org.apache.ignite.internal.util.typedef.internal.*; +import org.apache.ignite.lang.*; +import org.apache.ignite.resources.*; import javax.script.*; import java.util.*; @@ -57,12 +59,21 @@ public class IgniteComputeCommandHandler extends GridRestCommandHandlerAdapter { assert SUPPORTED_COMMANDS.contains(req.command()); -try { -ctx.scripting().runJS(((RestComputeRequest) req).function()); -} -catch (ScriptException e) { -throw new IgniteException(e); -} +final RestComputeRequest req0 = (RestComputeRequest) req; + +ctx.grid().compute().affinityRun(req0.cacheName(), req0.key(), new IgniteRunnable() { +@IgniteInstanceResource +private Ignite ignite; + +@Override public void run() { +try { + ((IgniteKernal)ignite).context().scripting().runJS(req0.function()); +} +catch (ScriptException e) { +throw new IgniteException(e); +} +} +}); return new GridFinishedFuture<>(new GridRestResponse("AFFINITY RUN " + req)); } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/4a1db957/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/request/RestComputeRequest.java -- diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/request/RestComputeRequest.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/request/RestComputeRequest.java index b046d78..809947e 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/request/RestComputeRequest.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/rest/request/RestComputeRequest.java @@ -24,6 +24,12 @@ public class RestComputeRequest extends GridRestRequest { /** Java script function. */ private String func; +/** Cache name. */ +private String cacheName; + +/** Key. */ +private Object key; + /** * @return Java script function. */ @@ -37,4 +43,32 @@ public class RestComputeRequest extends GridRestRequest { public void function(String func) { this.func = func; } + +/** + * @return Cache name. + */ +public String cacheName() { +return cacheName; +} + +/** + * @param cacheName Cache name. + */ +public void cacheName(String cacheName) { +this.cacheName = cacheName; +} + +/** + * @param key Key. + */ +public void key(Object key) { +this.key = key; +} + +/** + * @return Key. + */ +public Object key() { +return key; +
[3/6] incubator-ignite git commit: # ignite-sprint-7 do not call ping from exchange worker
# ignite-sprint-7 do not call ping from exchange worker Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/8fa9d3dd Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/8fa9d3dd Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/8fa9d3dd Branch: refs/heads/ignite-965 Commit: 8fa9d3dd9214e85748a6b7b900fa2433079ce246 Parents: d006389 Author: sboikov Authored: Fri Jun 19 14:37:37 2015 +0300 Committer: sboikov Committed: Fri Jun 19 14:37:37 2015 +0300 -- .../processors/cache/GridCacheIoManager.java| 64 -- .../GridCachePartitionExchangeManager.java | 70 +--- .../GridCacheAbstractFailoverSelfTest.java | 6 +- 3 files changed, 79 insertions(+), 61 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8fa9d3dd/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 eef9fde..74a4512 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 @@ -323,7 +323,7 @@ public class GridCacheIoManager extends GridCacheSharedManagerAdapter { * Processes failed messages. * @param nodeId niode id. * @param msg message. - * @throws IgniteCheckedException + * @throws IgniteCheckedException If failed. */ private void processFailedMessage(UUID nodeId, GridCacheMessage msg) throws IgniteCheckedException { GridCacheContext ctx = cctx.cacheContext(msg.cacheId()); @@ -511,6 +511,7 @@ public class GridCacheIoManager extends GridCacheSharedManagerAdapter { * @param cacheMsg Cache message to get start future. * @return Preloader start future. */ +@SuppressWarnings("unchecked") private IgniteInternalFuture startFuture(GridCacheMessage cacheMsg) { int cacheId = cacheMsg.cacheId(); @@ -574,6 +575,7 @@ public class GridCacheIoManager extends GridCacheSharedManagerAdapter { * * @param node Node to send the message to. * @param msg Message to send. + * @param plc IO policy. * @throws IgniteCheckedException If sending failed. * @throws ClusterTopologyCheckedException If receiver left. */ @@ -734,6 +736,7 @@ public class GridCacheIoManager extends GridCacheSharedManagerAdapter { * * @param nodeId ID of node to send the message to. * @param msg Message to send. + * @param plc IO policy. * @throws IgniteCheckedException If sending failed. */ public void send(UUID nodeId, GridCacheMessage msg, GridIoPolicy plc) throws IgniteCheckedException { @@ -795,8 +798,41 @@ public class GridCacheIoManager extends GridCacheSharedManagerAdapter { } /** + * Sends message without retries and node ping in case of error. + * + * @param node Node to send message to. + * @param msg Message. + * @param plc IO policy. + * @throws IgniteCheckedException If send failed. + */ +public void sendNoRetry(ClusterNode node, +GridCacheMessage msg, +GridIoPolicy plc) +throws IgniteCheckedException +{ +assert node != null; +assert msg != null; + +onSend(msg, null); + +try { +cctx.gridIO().send(node, TOPIC_CACHE, msg, plc); + +if (log.isDebugEnabled()) +log.debug("Sent cache message [msg=" + msg + ", node=" + U.toShortString(node) + ']'); +} +catch (IgniteCheckedException e) { +if (!cctx.discovery().alive(node.id())) +throw new ClusterTopologyCheckedException("Node left grid while sending message to: " + node.id(), e); +else +throw e; +} +} + +/** * Adds message handler. * + * @param cacheId Cache ID. * @param type Type of message. * @param c Handler. */ @@ -846,29 +882,15 @@ public class GridCacheIoManager extends GridCacheSharedManagerAdapter { idxClsHandlers.remove(cacheId); -for (Iterator iterator = clsHandlers.keySet().iterator(); iterator.hasNext(); ) { -ListenerKey key = iterator.next(); +for (Iterator iter = clsHandlers.keySet().iterator(); iter.hasNext(); ) { +ListenerKey key = iter.next(); if (key.cacheId == cacheId) -iterator.remove(); +iter.r
[5/6] incubator-ignite git commit: Merge remote-tracking branch 'remotes/origin/ignite-sprint-7' into ignite-965
Merge remote-tracking branch 'remotes/origin/ignite-sprint-7' into ignite-965 Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/eb5cc43c Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/eb5cc43c Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/eb5cc43c Branch: refs/heads/ignite-965 Commit: eb5cc43c84508981936c3bac8184013b7f72631d Parents: e77e76a ec9cfca Author: ivasilinets Authored: Sun Jun 21 18:52:17 2015 +0300 Committer: ivasilinets Committed: Sun Jun 21 18:52:17 2015 +0300 -- .../processors/cache/GridCacheIoManager.java| 64 -- .../GridCachePartitionExchangeManager.java | 70 +--- .../GridCacheAbstractFailoverSelfTest.java | 6 +- .../spi/discovery/tcp/TcpDiscoverySelfTest.java | 44 +++- 4 files changed, 120 insertions(+), 64 deletions(-) --
[1/6] incubator-ignite git commit: 1.1.4-SNAPSHOT
Repository: incubator-ignite Updated Branches: refs/heads/ignite-965 e77e76acc -> 4a1db957c 1.1.4-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/4d9868a0 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/4d9868a0 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/4d9868a0 Branch: refs/heads/ignite-965 Commit: 4d9868a0efd8a55cc7ec4abc9472053bf17c05be Parents: ad0a026 Author: Ignite Teamcity Authored: Fri Jun 19 12:24:27 2015 +0300 Committer: Ignite Teamcity Committed: Fri Jun 19 12:24:27 2015 +0300 -- examples/pom.xml | 2 +- modules/aop/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/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/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 +- pom.xml | 2 +- 37 files changed, 37 insertions(+), 37 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/4d9868a0/examples/pom.xml -- diff --git a/examples/pom.xml b/examples/pom.xml index 8422402..834b5b4 100644 --- a/examples/pom.xml +++ b/examples/pom.xml @@ -28,7 +28,7 @@ ignite-examples -1.1.3-SNAPSHOT +1.1.4-SNAPSHOT http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/4d9868a0/modules/aop/pom.xml -- diff --git a/modules/aop/pom.xml b/modules/aop/pom.xml index 1119301..e9cc980 100644 --- a/modules/aop/pom.xml +++ b/modules/aop/pom.xml @@ -31,7 +31,7 @@ ignite-aop -1.1.3-SNAPSHOT +1.1.4-SNAPSHOT http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/4d9868a0/modules/aws/pom.xml -- diff --git a/modules/aws/pom.xml b/modules/aws/pom.xml index 3b1f3c6..1d3b1f3 100644 --- a/modules/aws/pom.xml +++ b/modules/aws/pom.xml @@ -31,7 +31,7 @@ ignite-aws -1.1.3-SNAPSHOT +1.1.4-SNAPSHOT http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/4d9868a0/modules/clients/pom.xml -- diff --git a/modules/clients/pom.xml b/modules/clients/pom.xml index dfde946..6b28630 100644 --- a/modules/clients/pom.xml +++ b/modules/clients/pom.xml @@ -31,7 +31,7 @@ ignite-clients -1.1.3-SNAPSHOT +1.1.4-SNAPSHOT http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/4d9868a0/modules/cloud/pom.xml -- diff --git a/modules/cloud/pom.xml b/modules/cloud/pom.xml index b45b503..0c9cd3d 100644 --- a/modules/cloud/pom.xml +++ b/modules/cloud/pom.xml @@ -29,7 +29,7 @@ ignite-cloud -1.1.3-SNAPSHOT +1.1.4-SNAPSHOT
[4/6] incubator-ignite git commit: Merge branch 'ignite-sprint-6' into ignite-sprint-7
Merge branch 'ignite-sprint-6' into ignite-sprint-7 Conflicts: examples/pom.xml modules/aop/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/resources/ignite.properties modules/extdata/p2p/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/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 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/ec9cfcaf Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/ec9cfcaf Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/ec9cfcaf Branch: refs/heads/ignite-965 Commit: ec9cfcaf8b245be6fe4723b1e2d08526d3a6d4cb Parents: 8fa9d3d d699faa Author: vozerov-gridgain Authored: Fri Jun 19 15:32:21 2015 +0300 Committer: vozerov-gridgain Committed: Fri Jun 19 15:32:21 2015 +0300 -- .../spi/discovery/tcp/TcpDiscoverySelfTest.java | 44 ++-- 1 file changed, 41 insertions(+), 3 deletions(-) --
incubator-ignite git commit: IGNITE-621 - Added automatic retries for atomics.
Repository: incubator-ignite Updated Branches: refs/heads/ignite-621 3787a9d33 -> 5505b4d3d IGNITE-621 - Added automatic retries for atomics. Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/5505b4d3 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/5505b4d3 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/5505b4d3 Branch: refs/heads/ignite-621 Commit: 5505b4d3d50caf41246d1194c52298a6df47a239 Parents: 3787a9d Author: Alexey Goncharuk Authored: Sun Jun 21 13:09:24 2015 -0700 Committer: Alexey Goncharuk Committed: Sun Jun 21 13:09:24 2015 -0700 -- .../processors/cache/GridCacheUtils.java| 42 .../datastructures/GridCacheAtomicLongImpl.java | 25 ++-- .../GridCacheAtomicSequenceImpl.java| 11 ++--- .../GridCacheAtomicStampedImpl.java | 21 +- .../GridCacheCountDownLatchImpl.java| 16 +++- .../IgniteCachePutRetryAbstractSelfTest.java| 13 ++ ...gniteCachePutRetryTransactionalSelfTest.java | 39 ++ .../IgniteCacheFailoverTestSuite.java | 3 ++ 8 files changed, 131 insertions(+), 39 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/5505b4d3/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 8c26046..f88e288 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 @@ -30,6 +30,7 @@ import org.apache.ignite.internal.processors.cache.distributed.*; import org.apache.ignite.internal.processors.cache.distributed.dht.*; import org.apache.ignite.internal.processors.cache.transactions.*; import org.apache.ignite.internal.processors.cache.version.*; +import org.apache.ignite.internal.transactions.*; import org.apache.ignite.internal.util.lang.*; import org.apache.ignite.internal.util.typedef.*; import org.apache.ignite.internal.util.typedef.T2; @@ -1699,4 +1700,45 @@ public class GridCacheUtils { ctx.resource().cleanupGeneric(lsnr); } } + +/** + * @param c Closure to retry. + * @param Closure type. + * @return Wrapped closure. + */ +public static Callable retryTopologySafe(final Callable c ) { +return new Callable() { +@Override public S call() throws Exception { +int retries = GridCacheAdapter.MAX_RETRIES; + +IgniteCheckedException err = null; + +for (int i = 0; i < retries; i++) { +try { +return c.call(); +} +catch (IgniteCheckedException e) { +if (X.hasCause(e, ClusterTopologyCheckedException.class) || +X.hasCause(e, IgniteTxRollbackCheckedException.class) || +X.hasCause(e, CachePartialUpdateCheckedException.class)) { +if (i < retries - 1) { +err = e; + +U.sleep(1); + +continue; +} + +throw e; +} +else +throw e; +} +} + +// Should never happen. +throw err; +} +}; +} } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/5505b4d3/modules/core/src/main/java/org/apache/ignite/internal/processors/datastructures/GridCacheAtomicLongImpl.java -- diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/datastructures/GridCacheAtomicLongImpl.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/datastructures/GridCacheAtomicLongImpl.java index b18d35a..5e9245d 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/datastructures/GridCacheAtomicLongImpl.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/datastructures/GridCacheAtomicLongImpl.java @@ -31,6 +31,7 @@ import java.util.concurrent.*; import static org.apache.ignite.transactions.TransactionConcurrency.*; import static org.apache.ignite.transactions.TransactionIsolation.*; +import static org.apache.
[15/50] incubator-ignite git commit: # ignite-sprint-6 more info in assert
# ignite-sprint-6 more info in assert Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/fffc2ecc Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/fffc2ecc Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/fffc2ecc Branch: refs/heads/ignite-843 Commit: fffc2ecc86628a9a25c6f855d89277d124711873 Parents: af829d0 Author: sboikov Authored: Thu Jun 18 08:57:39 2015 +0300 Committer: sboikov Committed: Thu Jun 18 08:57:39 2015 +0300 -- .../dht/GridDhtPartitionTopologyImpl.java| 4 +++- .../IgniteCacheP2pUnmarshallingTxErrorTest.java | 19 ++- .../junits/common/GridCommonAbstractTest.java| 8 ++-- 3 files changed, 19 insertions(+), 12 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/fffc2ecc/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 374ab87..de7f876 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 @@ -620,7 +620,9 @@ class GridDhtPartitionTopologyImpl implements GridDhtPartitionTopology { lock.readLock().lock(); try { -assert node2part != null && node2part.valid() : "Invalid node-to-partitions map [topVer=" + topVer + +assert node2part != null && node2part.valid() : "Invalid node-to-partitions map [topVer1=" + topVer + +", topVer2=" + this.topVer + +", cache=" + cctx.name() + ", node2part=" + node2part + ']'; Collection nodes = null; http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/fffc2ecc/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheP2pUnmarshallingTxErrorTest.java -- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheP2pUnmarshallingTxErrorTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheP2pUnmarshallingTxErrorTest.java index 017f7db..356d67b 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheP2pUnmarshallingTxErrorTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheP2pUnmarshallingTxErrorTest.java @@ -26,11 +26,13 @@ import org.apache.ignite.transactions.*; import javax.cache.*; import java.io.*; +import static org.apache.ignite.transactions.TransactionConcurrency.*; +import static org.apache.ignite.transactions.TransactionIsolation.*; + /** * Checks behavior on exception while unmarshalling key. */ public class IgniteCacheP2pUnmarshallingTxErrorTest extends IgniteCacheP2pUnmarshallingErrorTest { - /** {@inheritDoc} */ @Override protected CacheAtomicityMode atomicityMode() { return CacheAtomicityMode.TRANSACTIONAL; @@ -41,7 +43,7 @@ public class IgniteCacheP2pUnmarshallingTxErrorTest extends IgniteCacheP2pUnmars IgniteConfiguration cfg = super.getConfiguration(gridName); if (!gridName.endsWith("0")) -cfg.getCacheConfiguration()[0].setRebalanceDelay(-1); //allows to check GridDhtLockRequest fail. +cfg.getCacheConfiguration()[0].setRebalanceDelay(-1); // Allows to check GridDhtLockRequest fail. return cfg; } @@ -52,8 +54,7 @@ public class IgniteCacheP2pUnmarshallingTxErrorTest extends IgniteCacheP2pUnmars protected void failOptimistic() { IgniteCache cache = jcache(0); -try (Transaction tx = grid(0).transactions().txStart(TransactionConcurrency.OPTIMISTIC, -TransactionIsolation.REPEATABLE_READ)) { +try (Transaction tx = grid(0).transactions().txStart(OPTIMISTIC, REPEATABLE_READ)) { cache.put(new TestKey(String.valueOf(++key)), ""); @@ -65,7 +66,7 @@ public class IgniteCacheP2pUnmarshallingTxErrorTest extends IgniteCacheP2pUnmars assert X.hasCause(e, IOException.class); } -assert readCnt.get() == 0; //ensure we have read count as expected. +assert readCnt.get() == 0; // Ensure we have read count as expected. } /** @@ -74,8 +75,8 @@ public class IgniteCacheP2p
[21/50] incubator-ignite git commit: #Fixed aws tests. (Changed bucket name)
#Fixed aws tests. (Changed bucket name) Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/45939ace Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/45939ace Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/45939ace Branch: refs/heads/ignite-843 Commit: 45939ace51cd081ac1c755ca0b6076a22f00cfb5 Parents: de53189 Author: nikolay_tikhonov Authored: Thu Jun 18 10:30:33 2015 +0300 Committer: nikolay_tikhonov Committed: Thu Jun 18 10:31:31 2015 +0300 -- .../ignite/spi/checkpoint/s3/S3CheckpointManagerSelfTest.java| 2 +- .../apache/ignite/spi/checkpoint/s3/S3CheckpointSpiSelfTest.java | 4 ++-- .../spi/checkpoint/s3/S3CheckpointSpiStartStopSelfTest.java | 2 +- .../ignite/spi/checkpoint/s3/S3SessionCheckpointSelfTest.java| 2 +- .../tcp/ipfinder/s3/TcpDiscoveryS3IpFinderSelfTest.java | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/45939ace/modules/aws/src/test/java/org/apache/ignite/spi/checkpoint/s3/S3CheckpointManagerSelfTest.java -- diff --git a/modules/aws/src/test/java/org/apache/ignite/spi/checkpoint/s3/S3CheckpointManagerSelfTest.java b/modules/aws/src/test/java/org/apache/ignite/spi/checkpoint/s3/S3CheckpointManagerSelfTest.java index a354e67..b01ba81 100644 --- a/modules/aws/src/test/java/org/apache/ignite/spi/checkpoint/s3/S3CheckpointManagerSelfTest.java +++ b/modules/aws/src/test/java/org/apache/ignite/spi/checkpoint/s3/S3CheckpointManagerSelfTest.java @@ -39,7 +39,7 @@ public class S3CheckpointManagerSelfTest extends GridCheckpointManagerAbstractSe spi.setAwsCredentials(cred); -spi.setBucketNameSuffix("test-bucket"); +spi.setBucketNameSuffix("unit-test-bucket"); cfg.setCheckpointSpi(spi); http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/45939ace/modules/aws/src/test/java/org/apache/ignite/spi/checkpoint/s3/S3CheckpointSpiSelfTest.java -- diff --git a/modules/aws/src/test/java/org/apache/ignite/spi/checkpoint/s3/S3CheckpointSpiSelfTest.java b/modules/aws/src/test/java/org/apache/ignite/spi/checkpoint/s3/S3CheckpointSpiSelfTest.java index 5cf0f2e..5894678 100644 --- a/modules/aws/src/test/java/org/apache/ignite/spi/checkpoint/s3/S3CheckpointSpiSelfTest.java +++ b/modules/aws/src/test/java/org/apache/ignite/spi/checkpoint/s3/S3CheckpointSpiSelfTest.java @@ -48,7 +48,7 @@ public class S3CheckpointSpiSelfTest extends GridSpiAbstractTesthttp://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/45939ace/modules/aws/src/test/java/org/apache/ignite/spi/checkpoint/s3/S3CheckpointSpiStartStopSelfTest.java -- diff --git a/modules/aws/src/test/java/org/apache/ignite/spi/checkpoint/s3/S3CheckpointSpiStartStopSelfTest.java b/modules/aws/src/test/java/org/apache/ignite/spi/checkpoint/s3/S3CheckpointSpiStartStopSelfTest.java index 7de2124..34f25ad 100644 --- a/modules/aws/src/test/java/org/apache/ignite/spi/checkpoint/s3/S3CheckpointSpiStartStopSelfTest.java +++ b/modules/aws/src/test/java/org/apache/ignite/spi/checkpoint/s3/S3CheckpointSpiStartStopSelfTest.java @@ -34,7 +34,7 @@ public class S3CheckpointSpiStartStopSelfTest extends GridSpiStartStopAbstractTe spi.setAwsCredentials(cred); -spi.setBucketNameSuffix("test-bucket"); +spi.setBucketNameSuffix("unit-test-bucket"); super.spiConfigure(spi); } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/45939ace/modules/aws/src/test/java/org/apache/ignite/spi/checkpoint/s3/S3SessionCheckpointSelfTest.java -- diff --git a/modules/aws/src/test/java/org/apache/ignite/spi/checkpoint/s3/S3SessionCheckpointSelfTest.java b/modules/aws/src/test/java/org/apache/ignite/spi/checkpoint/s3/S3SessionCheckpointSelfTest.java index 56f39de..c683cb3 100644 --- a/modules/aws/src/test/java/org/apache/ignite/spi/checkpoint/s3/S3SessionCheckpointSelfTest.java +++ b/modules/aws/src/test/java/org/apache/ignite/spi/checkpoint/s3/S3SessionCheckpointSelfTest.java @@ -39,7 +39,7 @@ public class S3SessionCheckpointSelfTest extends GridSessionCheckpointAbstractSe spi.setAwsCredentials(cred); -spi.setBucketNameSuffix("test-bucket"); +spi.setBucketNameSuffix("unit-test-bucket"); cfg.setCheckpointSpi(spi); http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/45939ace/modules/aws/src/test/java/org/apache/ignite/spi/discovery/tcp/ipfinder/s3/TcpDiscoveryS3IpFinderSelfTest.java -
[47/50] incubator-ignite git commit: # ignite-sprint-7 do not call ping from exchange worker
# ignite-sprint-7 do not call ping from exchange worker Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/8fa9d3dd Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/8fa9d3dd Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/8fa9d3dd Branch: refs/heads/ignite-843 Commit: 8fa9d3dd9214e85748a6b7b900fa2433079ce246 Parents: d006389 Author: sboikov Authored: Fri Jun 19 14:37:37 2015 +0300 Committer: sboikov Committed: Fri Jun 19 14:37:37 2015 +0300 -- .../processors/cache/GridCacheIoManager.java| 64 -- .../GridCachePartitionExchangeManager.java | 70 +--- .../GridCacheAbstractFailoverSelfTest.java | 6 +- 3 files changed, 79 insertions(+), 61 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8fa9d3dd/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 eef9fde..74a4512 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 @@ -323,7 +323,7 @@ public class GridCacheIoManager extends GridCacheSharedManagerAdapter { * Processes failed messages. * @param nodeId niode id. * @param msg message. - * @throws IgniteCheckedException + * @throws IgniteCheckedException If failed. */ private void processFailedMessage(UUID nodeId, GridCacheMessage msg) throws IgniteCheckedException { GridCacheContext ctx = cctx.cacheContext(msg.cacheId()); @@ -511,6 +511,7 @@ public class GridCacheIoManager extends GridCacheSharedManagerAdapter { * @param cacheMsg Cache message to get start future. * @return Preloader start future. */ +@SuppressWarnings("unchecked") private IgniteInternalFuture startFuture(GridCacheMessage cacheMsg) { int cacheId = cacheMsg.cacheId(); @@ -574,6 +575,7 @@ public class GridCacheIoManager extends GridCacheSharedManagerAdapter { * * @param node Node to send the message to. * @param msg Message to send. + * @param plc IO policy. * @throws IgniteCheckedException If sending failed. * @throws ClusterTopologyCheckedException If receiver left. */ @@ -734,6 +736,7 @@ public class GridCacheIoManager extends GridCacheSharedManagerAdapter { * * @param nodeId ID of node to send the message to. * @param msg Message to send. + * @param plc IO policy. * @throws IgniteCheckedException If sending failed. */ public void send(UUID nodeId, GridCacheMessage msg, GridIoPolicy plc) throws IgniteCheckedException { @@ -795,8 +798,41 @@ public class GridCacheIoManager extends GridCacheSharedManagerAdapter { } /** + * Sends message without retries and node ping in case of error. + * + * @param node Node to send message to. + * @param msg Message. + * @param plc IO policy. + * @throws IgniteCheckedException If send failed. + */ +public void sendNoRetry(ClusterNode node, +GridCacheMessage msg, +GridIoPolicy plc) +throws IgniteCheckedException +{ +assert node != null; +assert msg != null; + +onSend(msg, null); + +try { +cctx.gridIO().send(node, TOPIC_CACHE, msg, plc); + +if (log.isDebugEnabled()) +log.debug("Sent cache message [msg=" + msg + ", node=" + U.toShortString(node) + ']'); +} +catch (IgniteCheckedException e) { +if (!cctx.discovery().alive(node.id())) +throw new ClusterTopologyCheckedException("Node left grid while sending message to: " + node.id(), e); +else +throw e; +} +} + +/** * Adds message handler. * + * @param cacheId Cache ID. * @param type Type of message. * @param c Handler. */ @@ -846,29 +882,15 @@ public class GridCacheIoManager extends GridCacheSharedManagerAdapter { idxClsHandlers.remove(cacheId); -for (Iterator iterator = clsHandlers.keySet().iterator(); iterator.hasNext(); ) { -ListenerKey key = iterator.next(); +for (Iterator iter = clsHandlers.keySet().iterator(); iter.hasNext(); ) { +ListenerKey key = iter.next(); if (key.cacheId == cacheId) -iterator.remove(); +iter.r
[50/50] incubator-ignite git commit: # ignite-850 Added marshaler settings.
# ignite-850 Added marshaler settings. Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/7e5141eb Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/7e5141eb Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/7e5141eb Branch: refs/heads/ignite-843 Commit: 7e5141ebe97fac352324490ef00d4057c2a2599e Parents: 08ac7ea Author: Andrey Authored: Mon Jun 22 10:39:52 2015 +0700 Committer: Andrey Committed: Mon Jun 22 10:39:52 2015 +0700 -- .../nodejs/public/form-models/clusters.json | 60 +--- .../public/javascripts/controllers/clusters.js | 5 ++ .../public/javascripts/controllers/common.js| 3 + .../nodejs/views/includes/controls.jade | 5 +- 4 files changed, 64 insertions(+), 9 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/7e5141eb/modules/webconfig/nodejs/public/form-models/clusters.json -- diff --git a/modules/webconfig/nodejs/public/form-models/clusters.json b/modules/webconfig/nodejs/public/form-models/clusters.json index 3dfc446..b8c7bf1 100644 --- a/modules/webconfig/nodejs/public/form-models/clusters.json +++ b/modules/webconfig/nodejs/public/form-models/clusters.json @@ -1,5 +1,5 @@ { - "templateTip" : [ + "templateTip": [ "Use following template for add cluster:", "", " blank - Empty configuration.", @@ -69,8 +69,8 @@ ] }, "Multicast": { -"expanded": false, -"fields": [ + "expanded": false, + "fields": [ { "label": "IP address", "type": "text", @@ -386,6 +386,46 @@ "label": "Marshaller", "fields": [ { + "label": "Marshaller", + "type": "dropdown-details", + "group": "marshaller", + "model": "kind", + "placeholder": "Choose marshaller", + "items": "marshallers", + "tip": [ +"Cache expiration policy." + ], + "details": { +"OptimizedMarshaller": { + "expanded": false, + "fields": [ +{ + "label": "Streams pool size", + "type": "text", + "model": "poolSize", + "placeholder": "0", + "tip": [ +"Specifies size of cached object streams used by marshaller.", +"Object streams are cached for performance reason to avoid costly recreation for every serialization routine.", +"If 0 (default), pool is not used and each thread has its own cached object stream which it keeps reusing.", +"Since each stream has an internal buffer, creating a stream for each thread can lead to high memory consumption if many large messages are marshalled or unmarshalled concurrently.", +"Consider using pool in this case. This will limit number of streams that can be created and, therefore, decrease memory consumption.", +"NOTE: Using streams pool can decrease performance since streams will be shared between different threads which will lead to more frequent context switching." + ] +}, +{ + "label": "Require serializable", + "type": "check", + "model": "requireSerializable", + "tip": [ +"Whether marshaller should require Serializable interface or not." + ] +} + ] +} + } +}, +{ "label": "Marshal local jobs", "type": "check", "model": "marshalLocalJobs", @@ -397,14 +437,20 @@ { "label": "Keep alive time", "type": "text", - "model": "marshCacheKeepAliveTime", - "placeholder": "10,000" + "model": "marshallerCacheKeepAliveTime", + "placeholder": "10,000", + "tip": [ +"Keep alive time of thread pool that is in charge of processing marshaller messages." + ] }, { "label": "Pool size", "type": "text", - "model": "marshCachePoolSize", - "placeholder": "max(8, availableProcessors) * 2" + "model": "marshallerCacheThreadPoolSize", + "placeholder": "max(8, availableProcessors) * 2", + "tip": [ +"Default size of thread pool that is in charge of processing marshaller messages." + ] } ] }, http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/7e5141eb/modules/webconfig/nodejs/publ
[12/50] incubator-ignite git commit: Merge branches 'ignite-484-1' and 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-484-1
Merge branches 'ignite-484-1' and 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-484-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/efb42447 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/efb42447 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/efb42447 Branch: refs/heads/ignite-843 Commit: efb4244779b94c9c9f35c63708e4a41da2430bce Parents: 94060c9 4298238 af829d0 Author: S.Vladykin Authored: Wed Jun 17 19:50:12 2015 +0300 Committer: S.Vladykin Committed: Wed Jun 17 19:50:12 2015 +0300 -- .../processors/cache/GridCacheAdapter.java | 4 + .../processors/cache/IgniteCacheProxy.java | 7 + .../dht/GridDhtTransactionalCacheAdapter.java | 2 +- .../cache/transactions/IgniteTxHandler.java | 2 +- .../transactions/IgniteTxLocalAdapter.java | 12 +- .../dr/IgniteDrDataStreamerCacheUpdater.java| 7 +- .../CacheStoreUsageMultinodeAbstractTest.java | 305 +++ ...eUsageMultinodeDynamicStartAbstractTest.java | 169 ++ ...oreUsageMultinodeDynamicStartAtomicTest.java | 32 ++ ...heStoreUsageMultinodeDynamicStartTxTest.java | 32 ++ ...reUsageMultinodeStaticStartAbstractTest.java | 158 ++ ...toreUsageMultinodeStaticStartAtomicTest.java | 32 ++ ...cheStoreUsageMultinodeStaticStartTxTest.java | 32 ++ .../testsuites/IgniteCacheTestSuite4.java | 4 + .../h2/twostep/GridReduceQueryExecutor.java | 3 +- 15 files changed, 793 insertions(+), 8 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/efb42447/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridReduceQueryExecutor.java -- diff --cc modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridReduceQueryExecutor.java index 6635dde,6c407d9,11054b7..b956167 --- a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridReduceQueryExecutor.java +++ b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridReduceQueryExecutor.java -273,514 -273,477 -265,113 +273,515 public class GridReduceQueryExecutor } /** + * @param r Query run. + * @param retryVer Retry version. + * @param nodeId Node ID. + */ +private void retry(QueryRun r, AffinityTopologyVersion retryVer, UUID nodeId) { +r.state(retryVer, nodeId); +} + +/** + * @param cctx Cache context for main space. + * @param extraSpaces Extra spaces. + * @return {@code true} If preloading is active. + */ +private boolean isPreloadingActive(final GridCacheContext cctx, List extraSpaces) { +if (hasMovingPartitions(cctx)) +return true; + +if (extraSpaces != null) { +for (String extraSpace : extraSpaces) { +if (hasMovingPartitions(cacheContext(extraSpace))) +return true; +} +} + +return false; +} + +/** + * @return {@code true} If cache context + */ +private boolean hasMovingPartitions(GridCacheContext cctx) { +GridDhtPartitionFullMap fullMap = cctx.topology().partitionMap(false); + +for (GridDhtPartitionMap map : fullMap.values()) { +if (map.hasMovingPartitions()) +return true; +} + +return false; +} + +/** + * @param name Cache name. + * @return Cache context. + */ +private GridCacheContext cacheContext(String name) { +return ctx.cache().internalCache(name).context(); +} + +/** + * @param topVer Topology version. + * @param cctx Cache context for main space. + * @param extraSpaces Extra spaces. + * @return Data nodes or {@code null} if repartitioning started and we need to retry.. + */ +private Collection stableDataNodes( +AffinityTopologyVersion topVer, +final GridCacheContext cctx, +List extraSpaces +) { +String space = cctx.name(); + - Set nodes = new HashSet<>(ctx.discovery().cacheAffinityNodes(space, topVer)); ++Set nodes = new HashSet<>(dataNodes(space, topVer)); + +if (F.isEmpty(nodes)) +throw new CacheException("No data nodes found for cache: " + space); + +if (!F.isEmpty(extraSpaces)) { +for (String extraSpace : extraSpaces) { +GridCacheContext extraCctx = cacheContext(extraSpace); + +if (extraC
[35/50] incubator-ignite git commit: Fixed test.
Fixed 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/4f3292d5 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/4f3292d5 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/4f3292d5 Branch: refs/heads/ignite-843 Commit: 4f3292d5d8b29c04fcc1bf1fa9b88e5f19ceddfe Parents: d874b00 Author: nikolay tikhonov Authored: Thu Jun 18 15:19:03 2015 +0300 Committer: nikolay tikhonov Committed: Thu Jun 18 15:19:03 2015 +0300 -- .../apache/ignite/internal/GridSelfTest.java| 20 1 file changed, 12 insertions(+), 8 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/4f3292d5/modules/core/src/test/java/org/apache/ignite/internal/GridSelfTest.java -- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridSelfTest.java index eccae34..2de04b0 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/GridSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridSelfTest.java @@ -112,7 +112,9 @@ public class GridSelfTest extends GridProjectionAbstractTest { */ @SuppressWarnings({"TooBroadScope"}) public void testAsyncListen() throws Exception { -final String msg = "HELLO!"; +final String hello = "HELLO!"; + +final String bye = "BYE!"; final Ignite g = grid(0); @@ -120,10 +122,12 @@ public class GridSelfTest extends GridProjectionAbstractTest { g.message().remoteListen(null, new MessagingListenActor() { @Override protected void receive(UUID nodeId, String rcvMsg) throws Throwable { -assertEquals(locNodeId, nodeId); -assertEquals(msg, rcvMsg); +if (hello.equals(rcvMsg)) { +assertEquals(locNodeId, nodeId); +assertEquals(hello, rcvMsg); -stop(rcvMsg); +stop(bye); +} } }); @@ -131,22 +135,22 @@ public class GridSelfTest extends GridProjectionAbstractTest { g.message().localListen(null, new P2() { @Override public boolean apply(UUID nodeId, String msg) { -if (!locNodeId.equals(nodeId)) +if (msg.equals(bye)) cnt.incrementAndGet(); return true; } }); -g.message().send(null, msg); +g.message().send(null, hello); GridTestUtils.waitForCondition(new GridAbsPredicate() { @Override public boolean apply() { -return cnt.get() == g.cluster().forRemotes().nodes().size(); +return cnt.get() == g.cluster().nodes().size(); } }, 5000); -assertEquals(cnt.get(), g.cluster().forRemotes().nodes().size()); +assertEquals(cnt.get(), g.cluster().nodes().size()); } /**
[01/50] incubator-ignite git commit: Merge branches 'ignite-484-1' and 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-484-1
Repository: incubator-ignite Updated Branches: refs/heads/ignite-843 ac52e0dbc -> 7e5141ebe Merge branches 'ignite-484-1' and 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-484-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/0b8587ba Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/0b8587ba Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/0b8587ba Branch: refs/heads/ignite-843 Commit: 0b8587ba81400a5227e8d3bb8be52f8c0d7d179f Parents: c1fc7b5 5218210 Author: S.Vladykin Authored: Wed Jun 17 14:40:23 2015 +0300 Committer: S.Vladykin Committed: Wed Jun 17 14:40:23 2015 +0300 -- .../apache/ignite/internal/IgniteKernal.java| 13 +--- .../client/GridClientConfiguration.java | 2 +- .../GridClientOptimizedMarshaller.java | 21 .../impl/GridTcpRouterNioListenerAdapter.java | 2 +- .../rest/protocols/tcp/GridTcpRestProtocol.java | 3 ++- .../ignite/internal/util/IgniteUtils.java | 21 6 files changed, 47 insertions(+), 15 deletions(-) --
[27/50] incubator-ignite git commit: Merge remote-tracking branch 'origin/ignite-sprint-6' into ignite-sprint-6
Merge remote-tracking branch 'origin/ignite-sprint-6' into ignite-sprint-6 Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/b23ea747 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/b23ea747 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/b23ea747 Branch: refs/heads/ignite-843 Commit: b23ea747d9cf351f607d60f520781f5d46e98715 Parents: 08d134d c1eee18 Author: Yakov Zhdanov Authored: Thu Jun 18 13:47:19 2015 +0300 Committer: Yakov Zhdanov Committed: Thu Jun 18 13:47:19 2015 +0300 -- .../ignite/internal/processors/cache/IgniteCacheProxy.java| 5 + .../ignite/internal/processors/query/GridQueryProcessor.java | 7 +++ 2 files changed, 12 insertions(+) --
[44/50] incubator-ignite git commit: Merge remote-tracking branch 'origin/ignite-sprint-7' into ignite-sprint-7
Merge remote-tracking branch 'origin/ignite-sprint-7' into ignite-sprint-7 Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/188cd823 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/188cd823 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/188cd823 Branch: refs/heads/ignite-843 Commit: 188cd82327a41833c7884ef8b437652999a0e113 Parents: 27fbf02 6974a8e Author: ashutak Authored: Fri Jun 19 12:54:39 2015 +0300 Committer: ashutak Committed: Fri Jun 19 12:54:39 2015 +0300 -- .../processors/cache/GridCacheUtils.java| 9 + .../processors/cache/IgniteCacheProxy.java | 5 +++ .../processors/query/GridQueryProcessor.java| 7 .../processors/task/GridTaskProcessor.java | 3 +- .../communication/tcp/TcpCommunicationSpi.java | 42 ++-- .../ignite/spi/discovery/tcp/ServerImpl.java| 35 .../spi/discovery/tcp/TcpDiscoverySpi.java | 42 ++-- .../tcp/internal/TcpDiscoveryNode.java | 18 + .../apache/ignite/internal/GridSelfTest.java| 20 ++ .../DataStreamerMultiThreadedSelfTest.java | 3 ++ 10 files changed, 134 insertions(+), 50 deletions(-) --
[34/50] incubator-ignite git commit: Merge remote-tracking branch 'remotes/origin/ignite-1003' into ignite-sprint-6
Merge remote-tracking branch 'remotes/origin/ignite-1003' into ignite-sprint-6 Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/4d1fa723 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/4d1fa723 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/4d1fa723 Branch: refs/heads/ignite-843 Commit: 4d1fa7235c1381bacaaeaf458658675d2ba34923 Parents: 31cf802 b23f930 Author: sboikov Authored: Thu Jun 18 15:15:49 2015 +0300 Committer: sboikov Committed: Thu Jun 18 15:15:49 2015 +0300 -- .../communication/tcp/TcpCommunicationSpi.java | 38 ++-- .../ignite/spi/discovery/tcp/ServerImpl.java| 21 +++ .../spi/discovery/tcp/TcpDiscoverySpi.java | 9 - .../tcp/internal/TcpDiscoveryNode.java | 18 ++ 4 files changed, 60 insertions(+), 26 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/4d1fa723/modules/core/src/main/java/org/apache/ignite/spi/communication/tcp/TcpCommunicationSpi.java -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/4d1fa723/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/4d1fa723/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpi.java --
[43/50] incubator-ignite git commit: # ignite-695: Fix (the rest of todos)
# ignite-695: Fix (the rest of todos) Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/27fbf022 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/27fbf022 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/27fbf022 Branch: refs/heads/ignite-843 Commit: 27fbf022fce03b1577f1ea7afe2bd3ea8fa11c0f Parents: edc9a1c Author: ashutak Authored: Fri Jun 19 12:54:09 2015 +0300 Committer: ashutak Committed: Fri Jun 19 12:54:09 2015 +0300 -- .../cache/distributed/IgniteCacheTxMessageRecoveryTest.java | 5 + .../near/GridCacheNearOnlyMultiNodeFullApiSelfTest.java | 2 +- .../java/org/apache/ignite/testsuites/IgniteCacheTestSuite.java | 4 ++-- .../IgniteCacheQueryOffheapEvictsMultiThreadedSelfTest.java | 5 + .../apache/ignite/testsuites/IgniteCacheQuerySelfTestSuite.java | 2 +- .../internal/websession/IgniteWebSessionSelfTestSuite.java | 2 +- 6 files changed, 15 insertions(+), 5 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/27fbf022/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheTxMessageRecoveryTest.java -- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheTxMessageRecoveryTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheTxMessageRecoveryTest.java index f26948a..fab1bf3 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheTxMessageRecoveryTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheTxMessageRecoveryTest.java @@ -26,6 +26,11 @@ import static org.apache.ignite.cache.CacheAtomicityMode.*; */ public class IgniteCacheTxMessageRecoveryTest extends IgniteCacheMessageRecoveryAbstractTest { /** {@inheritDoc} */ +@Override protected void beforeTest() throws Exception { +fail("https://issues.apache.org/jira/browse/IGNITE-795";); +} + +/** {@inheritDoc} */ @Override protected CacheAtomicityMode atomicityMode() { return TRANSACTIONAL; } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/27fbf022/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/GridCacheNearOnlyMultiNodeFullApiSelfTest.java -- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/GridCacheNearOnlyMultiNodeFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/GridCacheNearOnlyMultiNodeFullApiSelfTest.java index e78b782..8343c64 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/GridCacheNearOnlyMultiNodeFullApiSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/GridCacheNearOnlyMultiNodeFullApiSelfTest.java @@ -194,7 +194,7 @@ public class GridCacheNearOnlyMultiNodeFullApiSelfTest extends GridCachePartitio /** {@inheritDoc} */ @Override public void testNearDhtKeySize() throws Exception { -// TODO fix this test for client mode. +fail("https://issues.apache.org/jira/browse/IGNITE-1029";); } /** http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/27fbf022/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite.java -- diff --git a/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite.java b/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite.java index 6245308..0a31f49 100644 --- a/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite.java +++ b/modules/core/src/test/java/org/apache/ignite/testsuites/IgniteCacheTestSuite.java @@ -113,7 +113,7 @@ public class IgniteCacheTestSuite extends TestSuite { GridTestUtils.addTestIfNeeded(suite, GridCacheMvccSelfTest.class, ignoredTests); suite.addTestSuite(GridCacheMvccPartitionedSelfTest.class); suite.addTestSuite(GridCacheMvccManagerSelfTest.class); -//suite.addTestSuite(GridCacheP2PUndeploySelfTest.class); TODO uncomment in DR branch. +suite.addTestSuite(GridCacheP2PUndeploySelfTest.class); suite.addTestSuite(GridCacheConfigurationValidationSelfTest.class); suite.addTestSuite(GridCacheConfigurationConsistencySelfTest.class); suite.addTestSuite(GridCacheJdbcBlobStoreSelfTest.class); @@ -151,7 +151,7
[32/50] incubator-ignite git commit: # changed discovery error message
# changed discovery 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/31cf8027 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/31cf8027 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/31cf8027 Branch: refs/heads/ignite-843 Commit: 31cf8027216afca3d02461caa4f4245bdd8d0e73 Parents: cb862b6 Author: Yakov Zhdanov Authored: Thu Jun 18 14:56:12 2015 +0300 Committer: Yakov Zhdanov Committed: Thu Jun 18 14:56:12 2015 +0300 -- .../org/apache/ignite/spi/discovery/tcp/ServerImpl.java | 10 -- 1 file changed, 8 insertions(+), 2 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/31cf8027/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 63f165d..e9a949a 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 @@ -4103,8 +4103,14 @@ class ServerImpl extends TcpDiscoveryImpl { if (U.isMacInvalidArgumentError(e)) LT.error(log, e, "Failed to initialize connection [sock=" + sock + "]\n\t" + U.MAC_INVALID_ARG_MSG); -else -LT.error(log, e, "Failed to initialize connection [sock=" + sock + ']'); +else { +U.error( +log, +"Failed to initialize connection (this can happen due to short time " + +"network problems and can be ignored if does not affect node discovery) " + +"[sock=" + sock + ']', +e); +} } onException("Caught exception on handshake [err=" + e + ", sock=" + sock + ']', e);
[08/50] incubator-ignite git commit: ignite-484-1 - replicated client cache test added
ignite-484-1 - replicated client cache test added Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/10febf28 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/10febf28 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/10febf28 Branch: refs/heads/ignite-843 Commit: 10febf28fdf3966ffcb369c5725792b604be6c18 Parents: 1fe215e Author: S.Vladykin Authored: Wed Jun 17 17:11:00 2015 +0300 Committer: S.Vladykin Committed: Wed Jun 17 17:11:00 2015 +0300 -- ...lientQueryReplicatedNodeRestartSelfTest.java | 381 +++ .../IgniteCacheQuerySelfTestSuite.java | 1 + 2 files changed, 382 insertions(+) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/10febf28/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/IgniteCacheClientQueryReplicatedNodeRestartSelfTest.java -- diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/IgniteCacheClientQueryReplicatedNodeRestartSelfTest.java b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/IgniteCacheClientQueryReplicatedNodeRestartSelfTest.java new file mode 100644 index 000..23f44c0 --- /dev/null +++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/IgniteCacheClientQueryReplicatedNodeRestartSelfTest.java @@ -0,0 +1,381 @@ +/* + * 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.near; + +import org.apache.ignite.*; +import org.apache.ignite.cache.affinity.*; +import org.apache.ignite.cache.affinity.rendezvous.*; +import org.apache.ignite.cache.query.*; +import org.apache.ignite.cache.query.annotations.*; +import org.apache.ignite.cluster.*; +import org.apache.ignite.configuration.*; +import org.apache.ignite.internal.*; +import org.apache.ignite.internal.processors.cache.*; +import org.apache.ignite.internal.util.*; +import org.apache.ignite.internal.util.typedef.*; +import org.apache.ignite.spi.discovery.tcp.*; +import org.apache.ignite.spi.discovery.tcp.ipfinder.*; +import org.apache.ignite.spi.discovery.tcp.ipfinder.vm.*; +import org.apache.ignite.testframework.junits.common.*; + +import javax.cache.*; +import java.io.*; +import java.util.*; +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.CacheRebalanceMode.*; +import static org.apache.ignite.cache.CacheWriteSynchronizationMode.*; + +/** + * Test for distributed queries with replicated client cache and node restarts. + */ +public class IgniteCacheClientQueryReplicatedNodeRestartSelfTest extends GridCommonAbstractTest { +/** */ +private static final String QRY = "select co.id, count(*) cnt\n" + +"from \"pe\".Person pe, \"pr\".Product pr, \"co\".Company co, \"pu\".Purchase pu\n" + +"where pe.id = pu.personId and pu.productId = pr.id and pr.companyId = co.id \n" + +"group by co.id order by cnt desc, co.id"; + +/** */ +private static final P1 DATA_NODES_FILTER = new P1() { +@Override public boolean apply(ClusterNode clusterNode) { +String gridName = clusterNode.attribute(IgniteNodeAttributes.ATTR_GRID_NAME); + +return !gridName.endsWith(String.valueOf(GRID_CNT - 1)); // The last one is client only. +} +}; + +/** */ +private static final int GRID_CNT = 5; + +/** */ +private static final int PERS_CNT = 600; + +/** */ +private static final int PURCHASE_CNT = 6000; + +/** */ +private static final int COMPANY_CNT = 25; + +/** */ +private static final int PRODUCT_CNT = 100; + +/** */ +private static TcpDiscoveryIpFinder ipFinder = new TcpDiscove
[36/50] incubator-ignite git commit: Merge remote-tracking branch 'origin/ignite-sprint-6' into ignite-sprint-6
Merge remote-tracking branch 'origin/ignite-sprint-6' into ignite-sprint-6 Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/8c404f78 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/8c404f78 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/8c404f78 Branch: refs/heads/ignite-843 Commit: 8c404f78cc264ddf43c71904b9fbac40ce0ee418 Parents: 4f3292d 4d1fa72 Author: nikolay tikhonov Authored: Thu Jun 18 15:19:58 2015 +0300 Committer: nikolay tikhonov Committed: Thu Jun 18 15:19:58 2015 +0300 -- .../processors/cache/GridCacheUtils.java| 9 + .../processors/cache/IgniteCacheProxy.java | 5 +++ .../processors/query/GridQueryProcessor.java| 7 .../communication/tcp/TcpCommunicationSpi.java | 42 ++-- .../ignite/spi/discovery/tcp/ServerImpl.java| 31 +++ .../spi/discovery/tcp/TcpDiscoverySpi.java | 41 +-- .../tcp/internal/TcpDiscoveryNode.java | 18 + .../DataStreamerMultiThreadedSelfTest.java | 3 ++ 8 files changed, 115 insertions(+), 41 deletions(-) --
[37/50] incubator-ignite git commit: # ignite-sprint-7 do not run TaskDiscoveryListener in discovery thread
# ignite-sprint-7 do not run TaskDiscoveryListener in discovery thread Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/044f17de Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/044f17de Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/044f17de Branch: refs/heads/ignite-843 Commit: 044f17deae5a16c0d463633b75640d04a125f5d2 Parents: c6a0f24 Author: sboikov Authored: Thu Jun 18 15:36:44 2015 +0300 Committer: sboikov Committed: Thu Jun 18 15:36:44 2015 +0300 -- .../processors/task/GridTaskProcessor.java | 22 ++- .../GridTaskFailoverAffinityRunTest.java| 170 +++ .../testsuites/IgniteComputeGridTestSuite.java | 1 + 3 files changed, 184 insertions(+), 9 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/044f17de/modules/core/src/main/java/org/apache/ignite/internal/processors/task/GridTaskProcessor.java -- diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/task/GridTaskProcessor.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/task/GridTaskProcessor.java index 88713a1..bb9ff50 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/task/GridTaskProcessor.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/task/GridTaskProcessor.java @@ -1171,17 +1171,21 @@ public class GridTaskProcessor extends GridProcessorAdapter { @Override public void onEvent(Event evt) { assert evt.type() == EVT_NODE_FAILED || evt.type() == EVT_NODE_LEFT; -UUID nodeId = ((DiscoveryEvent)evt).eventNode().id(); +final UUID nodeId = ((DiscoveryEvent)evt).eventNode().id(); -lock.readLock(); +ctx.closure().runLocalSafe(new Runnable() { +@Override public void run() { +lock.readLock(); -try { -for (GridTaskWorker task : tasks.values()) -task.onNodeLeft(nodeId); -} -finally { -lock.readUnlock(); -} +try { +for (GridTaskWorker task : tasks.values()) +task.onNodeLeft(nodeId); +} +finally { +lock.readUnlock(); +} +} +}, false); } } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/044f17de/modules/core/src/test/java/org/apache/ignite/internal/GridTaskFailoverAffinityRunTest.java -- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/GridTaskFailoverAffinityRunTest.java b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskFailoverAffinityRunTest.java new file mode 100644 index 000..7ddd966 --- /dev/null +++ b/modules/core/src/test/java/org/apache/ignite/internal/GridTaskFailoverAffinityRunTest.java @@ -0,0 +1,170 @@ +/* + * 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; + +import org.apache.ignite.*; +import org.apache.ignite.configuration.*; +import org.apache.ignite.lang.*; +import org.apache.ignite.spi.discovery.tcp.*; +import org.apache.ignite.spi.discovery.tcp.ipfinder.*; +import org.apache.ignite.spi.discovery.tcp.ipfinder.vm.*; +import org.apache.ignite.testframework.*; +import org.apache.ignite.testframework.junits.common.*; + +import java.util.*; +import java.util.concurrent.*; +import java.util.concurrent.atomic.*; + +import static org.apache.ignite.cache.CacheAtomicityMode.*; +import static org.apache.ignite.cache.CacheMode.*; +import static org.apache.ignite.cache.CacheRebalanceMode.*; + +/** + * + */ +public class GridTaskFailoverAffinityRunTest extends GridCommonAbstractTest { +/** */ +private static TcpDiscoveryIpFinder ipFinder =
[38/50] incubator-ignite git commit: Merge remote-tracking branch 'origin/ignite-sprint-6' into ignite-sprint-6
Merge remote-tracking branch 'origin/ignite-sprint-6' into ignite-sprint-6 Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/ad0a026f Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/ad0a026f Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/ad0a026f Branch: refs/heads/ignite-843 Commit: ad0a026f480ff67025b39737c2e068b20035feb6 Parents: fc81bcf 8c404f7 Author: Yakov Zhdanov Authored: Thu Jun 18 15:54:59 2015 +0300 Committer: Yakov Zhdanov Committed: Thu Jun 18 15:54:59 2015 +0300 -- .../communication/tcp/TcpCommunicationSpi.java | 38 ++-- .../ignite/spi/discovery/tcp/ServerImpl.java| 21 +++ .../spi/discovery/tcp/TcpDiscoverySpi.java | 9 - .../tcp/internal/TcpDiscoveryNode.java | 18 ++ .../apache/ignite/internal/GridSelfTest.java| 20 ++- 5 files changed, 72 insertions(+), 34 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/ad0a026f/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/ad0a026f/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpi.java --
[41/50] incubator-ignite git commit: # ignite-sprint-7
# ignite-sprint-7 Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/6974a8e3 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/6974a8e3 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/6974a8e3 Branch: refs/heads/ignite-843 Commit: 6974a8e3d356a1e1b777064ae79cb0f67a50a077 Parents: 9458f12 Author: sboikov Authored: Fri Jun 19 12:16:49 2015 +0300 Committer: sboikov Committed: Fri Jun 19 12:16:49 2015 +0300 -- .../apache/ignite/internal/processors/task/GridTaskProcessor.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/6974a8e3/modules/core/src/main/java/org/apache/ignite/internal/processors/task/GridTaskProcessor.java -- diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/task/GridTaskProcessor.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/task/GridTaskProcessor.java index bb9ff50..d59a51d 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/task/GridTaskProcessor.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/task/GridTaskProcessor.java @@ -1175,7 +1175,8 @@ public class GridTaskProcessor extends GridProcessorAdapter { ctx.closure().runLocalSafe(new Runnable() { @Override public void run() { -lock.readLock(); +if (!lock.tryReadLock()) +return; try { for (GridTaskWorker task : tasks.values())
[46/50] incubator-ignite git commit: # ignite-sprint-6 added test for lastSuccessfulAddress
# ignite-sprint-6 added test for lastSuccessfulAddress Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/d699faa3 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/d699faa3 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/d699faa3 Branch: refs/heads/ignite-843 Commit: d699faa34d66b8e5f1487daf3386c4d677d8c1e5 Parents: 4d9868a Author: sboikov Authored: Fri Jun 19 13:01:51 2015 +0300 Committer: sboikov Committed: Fri Jun 19 13:01:51 2015 +0300 -- .../spi/discovery/tcp/TcpDiscoverySelfTest.java | 44 ++-- 1 file changed, 41 insertions(+), 3 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/d699faa3/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySelfTest.java -- diff --git a/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySelfTest.java b/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySelfTest.java index ad12753..9a44c24 100644 --- a/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySelfTest.java @@ -149,9 +149,47 @@ public class TcpDiscoverySelfTest extends GridCommonAbstractTest { */ public void testThreeNodesStartStop() throws Exception { try { -startGrid(1); -startGrid(2); -startGrid(3); +IgniteEx ignite1 = startGrid(1); +IgniteEx ignite2 = startGrid(2); +IgniteEx ignite3 = startGrid(3); + +TcpDiscoverySpi spi1 = (TcpDiscoverySpi)ignite1.configuration().getDiscoverySpi(); +TcpDiscoverySpi spi2 = (TcpDiscoverySpi)ignite2.configuration().getDiscoverySpi(); +TcpDiscoverySpi spi3 = (TcpDiscoverySpi)ignite3.configuration().getDiscoverySpi(); + +TcpDiscoveryNode node = (TcpDiscoveryNode)spi1.getNode(ignite2.localNode().id()); + +assertNotNull(node); +assertNotNull(node.lastSuccessfulAddress()); + +LinkedHashSet addrs = spi1.getNodeAddresses(node); + +assertEquals(addrs.iterator().next(), node.lastSuccessfulAddress()); + +assertTrue(spi1.pingNode(ignite3.localNode().id())); + +node = (TcpDiscoveryNode)spi1.getNode(ignite3.localNode().id()); + +assertNotNull(node); +assertNotNull(node.lastSuccessfulAddress()); + +addrs = spi1.getNodeAddresses(node); +assertEquals(addrs.iterator().next(), node.lastSuccessfulAddress()); + +node = (TcpDiscoveryNode)spi2.getNode(ignite1.localNode().id()); + +assertNotNull(node); +assertNotNull(node.lastSuccessfulAddress()); + +node = (TcpDiscoveryNode)spi2.getNode(ignite3.localNode().id()); + +assertNotNull(node); +assertNotNull(node.lastSuccessfulAddress()); + +node = (TcpDiscoveryNode)spi3.getNode(ignite1.localNode().id()); + +assertNotNull(node); +assertNotNull(node.lastSuccessfulAddress()); } finally { stopAllGrids();
[05/50] incubator-ignite git commit: ignite-484-1 - replicated cache group reservation fix + drop reservations group for dead nodes
ignite-484-1 - replicated cache group reservation fix + drop reservations group for dead nodes Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/1fe215e2 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/1fe215e2 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/1fe215e2 Branch: refs/heads/ignite-843 Commit: 1fe215e2cc83954f25cc7c2f0974dcf312694eb8 Parents: 68c35e7 Author: S.Vladykin Authored: Wed Jun 17 15:57:24 2015 +0300 Committer: S.Vladykin Committed: Wed Jun 17 15:57:24 2015 +0300 -- .../query/h2/twostep/GridMapQueryExecutor.java | 22 1 file changed, 18 insertions(+), 4 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/1fe215e2/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java -- diff --git a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java index 42f01cb..aaf64ee 100644 --- a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java +++ b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java @@ -123,6 +123,18 @@ public class GridMapQueryExecutor { } }, EventType.EVT_NODE_FAILED, EventType.EVT_NODE_LEFT); +// Drop group reservations for dead caches. +ctx.event().addLocalEventListener(new GridLocalEventListener() { +@Override public void onEvent(Event evt) { +String cacheName = ((CacheEvent)evt).cacheName(); + +for (T2 grpKey : reservations.keySet()) { +if (F.eq(grpKey.get1(), cacheName)) +reservations.remove(grpKey); +} +} +}, EventType.EVT_CACHE_STOPPED); + ctx.io().addMessageListener(GridTopic.TOPIC_QUERY, new GridMessageListener() { @Override public void onMessage(UUID nodeId, Object msg) { if (!busyLock.enterBusy()) @@ -244,7 +256,9 @@ public class GridMapQueryExecutor { if (cctx.isLocal()) continue; -final T2 grpKey = new T2<>(cctx.name(), topVer); +// For replicated cache topology version does not make sense. +final T2 grpKey = +new T2<>(cctx.name(), cctx.isReplicated() ? null : topVer); GridReservable r = reservations.get(grpKey); @@ -265,10 +279,10 @@ public class GridMapQueryExecutor { // We don't need to reserve partitions because they will not be evicted in replicated caches. if (part == null || part.state() != OWNING) return false; - -// Mark that we checked this replicated cache. -reservations.putIfAbsent(grpKey, ReplicatedReservation.INSTANCE); } + +// Mark that we checked this replicated cache. +reservations.putIfAbsent(grpKey, ReplicatedReservation.INSTANCE); } } else { // Reserve primary partitions for partitioned cache (if no explicit given).
[18/50] incubator-ignite git commit: Merge remote-tracking branch 'origin/ignite-sprint-6' into ignite-sprint-6
Merge remote-tracking branch 'origin/ignite-sprint-6' into ignite-sprint-6 Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/4cc376be Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/4cc376be Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/4cc376be Branch: refs/heads/ignite-843 Commit: 4cc376bedd63aee6cb5de434c435b3384431ed63 Parents: fa6615a fffc2ec Author: nikolay_tikhonov Authored: Thu Jun 18 09:45:26 2015 +0300 Committer: nikolay_tikhonov Committed: Thu Jun 18 09:45:26 2015 +0300 -- .../processors/cache/GridCacheAdapter.java | 4 + .../processors/cache/IgniteCacheProxy.java | 7 + .../dht/GridDhtPartitionTopologyImpl.java | 4 +- .../dht/GridDhtTransactionalCacheAdapter.java | 2 +- .../cache/transactions/IgniteTxHandler.java | 2 +- .../transactions/IgniteTxLocalAdapter.java | 12 +- .../dr/IgniteDrDataStreamerCacheUpdater.java| 7 +- .../CacheStoreUsageMultinodeAbstractTest.java | 305 +++ ...eUsageMultinodeDynamicStartAbstractTest.java | 169 ++ ...oreUsageMultinodeDynamicStartAtomicTest.java | 32 ++ ...heStoreUsageMultinodeDynamicStartTxTest.java | 32 ++ ...reUsageMultinodeStaticStartAbstractTest.java | 158 ++ ...toreUsageMultinodeStaticStartAtomicTest.java | 32 ++ ...cheStoreUsageMultinodeStaticStartTxTest.java | 32 ++ .../IgniteCacheP2pUnmarshallingTxErrorTest.java | 19 +- .../junits/common/GridCommonAbstractTest.java | 8 +- .../testsuites/IgniteCacheTestSuite4.java | 4 + 17 files changed, 810 insertions(+), 19 deletions(-) --
[42/50] incubator-ignite git commit: 1.1.4-SNAPSHOT
1.1.4-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/4d9868a0 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/4d9868a0 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/4d9868a0 Branch: refs/heads/ignite-843 Commit: 4d9868a0efd8a55cc7ec4abc9472053bf17c05be Parents: ad0a026 Author: Ignite Teamcity Authored: Fri Jun 19 12:24:27 2015 +0300 Committer: Ignite Teamcity Committed: Fri Jun 19 12:24:27 2015 +0300 -- examples/pom.xml | 2 +- modules/aop/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/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/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 +- pom.xml | 2 +- 37 files changed, 37 insertions(+), 37 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/4d9868a0/examples/pom.xml -- diff --git a/examples/pom.xml b/examples/pom.xml index 8422402..834b5b4 100644 --- a/examples/pom.xml +++ b/examples/pom.xml @@ -28,7 +28,7 @@ ignite-examples -1.1.3-SNAPSHOT +1.1.4-SNAPSHOT http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/4d9868a0/modules/aop/pom.xml -- diff --git a/modules/aop/pom.xml b/modules/aop/pom.xml index 1119301..e9cc980 100644 --- a/modules/aop/pom.xml +++ b/modules/aop/pom.xml @@ -31,7 +31,7 @@ ignite-aop -1.1.3-SNAPSHOT +1.1.4-SNAPSHOT http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/4d9868a0/modules/aws/pom.xml -- diff --git a/modules/aws/pom.xml b/modules/aws/pom.xml index 3b1f3c6..1d3b1f3 100644 --- a/modules/aws/pom.xml +++ b/modules/aws/pom.xml @@ -31,7 +31,7 @@ ignite-aws -1.1.3-SNAPSHOT +1.1.4-SNAPSHOT http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/4d9868a0/modules/clients/pom.xml -- diff --git a/modules/clients/pom.xml b/modules/clients/pom.xml index dfde946..6b28630 100644 --- a/modules/clients/pom.xml +++ b/modules/clients/pom.xml @@ -31,7 +31,7 @@ ignite-clients -1.1.3-SNAPSHOT +1.1.4-SNAPSHOT http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/4d9868a0/modules/cloud/pom.xml -- diff --git a/modules/cloud/pom.xml b/modules/cloud/pom.xml index b45b503..0c9cd3d 100644 --- a/modules/cloud/pom.xml +++ b/modules/cloud/pom.xml @@ -29,7 +29,7 @@ ignite-cloud -1.1.3-SNAPSHOT +1.1.4-SNAPSHOT 1.9.0 http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/4d9868a0/modules
[23/50] incubator-ignite git commit: # ignite-sprint-6 more info in test assert
# ignite-sprint-6 more info in test assert Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/d874b00d Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/d874b00d Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/d874b00d Branch: refs/heads/ignite-843 Commit: d874b00dcb1687339adc34b6212e8cbc5b9ffe16 Parents: 6c683c2 Author: sboikov Authored: Thu Jun 18 11:07:04 2015 +0300 Committer: sboikov Committed: Thu Jun 18 11:07:04 2015 +0300 -- .../IgniteCacheAbstractStopBusySelfTest.java| 30 .../IgniteCacheAtomicStopBusySelfTest.java | 8 +++--- ...gniteCacheTransactionalStopBusySelfTest.java | 8 +++--- 3 files changed, 26 insertions(+), 20 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/d874b00d/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheAbstractStopBusySelfTest.java -- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheAbstractStopBusySelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheAbstractStopBusySelfTest.java index 10b14cc..074f6ff 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheAbstractStopBusySelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheAbstractStopBusySelfTest.java @@ -36,9 +36,13 @@ import org.apache.ignite.testframework.junits.common.*; import org.jetbrains.annotations.*; import java.io.*; +import java.util.*; import java.util.concurrent.*; import java.util.concurrent.atomic.*; +import static org.apache.ignite.cache.CacheRebalanceMode.*; +import static org.apache.ignite.cache.CacheWriteSynchronizationMode.*; + /** * */ @@ -53,7 +57,7 @@ public abstract class IgniteCacheAbstractStopBusySelfTest extends GridCommonAbst public static final String CACHE_NAME = "StopTest"; /** */ -public static final TcpDiscoveryIpFinder finder = new TcpDiscoveryVmIpFinder(true); +public final TcpDiscoveryIpFinder finder = new TcpDiscoveryVmIpFinder(true); /** */ private AtomicBoolean suspended = new AtomicBoolean(false); @@ -62,7 +66,7 @@ public abstract class IgniteCacheAbstractStopBusySelfTest extends GridCommonAbst private CountDownLatch blocked; /** */ -protected AtomicReference bannedMessage = new AtomicReference<>(); +protected AtomicReference bannedMsg = new AtomicReference<>(); /** * @return Cache mode. @@ -93,9 +97,9 @@ public abstract class IgniteCacheAbstractStopBusySelfTest extends GridCommonAbst if (gridName.endsWith(String.valueOf(CLN_GRD))) cfg.setClientMode(true); -cacheCfg.setRebalanceMode(CacheRebalanceMode.SYNC); +cacheCfg.setRebalanceMode(SYNC); - cacheCfg.setWriteSynchronizationMode(CacheWriteSynchronizationMode.FULL_SYNC); +cacheCfg.setWriteSynchronizationMode(FULL_SYNC); cacheCfg.setBackups(1); @@ -125,14 +129,14 @@ public abstract class IgniteCacheAbstractStopBusySelfTest extends GridCommonAbst TimeUnit.MILLISECONDS.sleep(100L); } -assert clientNode().cluster().nodes().size() == 2; +assertEquals(2, clientNode().cluster().nodes().size()); } /** {@inheritDoc} */ @Override protected void afterTest() throws Exception { suspended.set(false); -bannedMessage.set(null); +bannedMsg.set(null); afterTestsStopped(); @@ -140,7 +144,9 @@ public abstract class IgniteCacheAbstractStopBusySelfTest extends GridCommonAbst stopGrid(CLN_GRD); -assert G.allGrids().isEmpty(); +List nodes = G.allGrids(); + +assertTrue("Unexpected nodes: " + nodes, nodes.isEmpty()); } /** @@ -203,12 +209,11 @@ public abstract class IgniteCacheAbstractStopBusySelfTest extends GridCommonAbst * @throws Exception If failed. */ public void testGet() throws Exception { -bannedMessage.set(GridNearGetRequest.class); +bannedMsg.set(GridNearGetRequest.class); executeTest(new Callable() { /** {@inheritDoc} */ -@Override -public Integer call() throws Exception { +@Override public Integer call() throws Exception { info("Start operation."); Integer put = (Integer) clientCache().get(1); @@ -318,6 +323,7 @@ public abstract class IgniteCacheAbstractStopBusySelfTest extends GridCommonAbst * @return Cache configuration. * @throws Exception In case of error. */ +@SuppressWarnings("unchecked
[03/50] incubator-ignite git commit: ignite-484-1 - get rid of owning future
ignite-484-1 - get rid of owning 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/68c35e73 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/68c35e73 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/68c35e73 Branch: refs/heads/ignite-843 Commit: 68c35e734b3754460c4ad807e154ea94066600a0 Parents: 642f1c7 Author: S.Vladykin Authored: Wed Jun 17 15:24:13 2015 +0300 Committer: S.Vladykin Committed: Wed Jun 17 15:24:13 2015 +0300 -- .../distributed/dht/GridDhtLocalPartition.java | 19 --- 1 file changed, 19 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/68c35e73/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtLocalPartition.java -- diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtLocalPartition.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtLocalPartition.java index 1392f5e..3a577a7 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtLocalPartition.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtLocalPartition.java @@ -70,10 +70,6 @@ public class GridDhtLocalPartition implements Comparable, @GridToStringExclude private final GridFutureAdapter rent; -/** Rent future. */ -@GridToStringExclude -private final GridFutureAdapter own; - /** Entries map. */ private final ConcurrentMap map; @@ -118,12 +114,6 @@ public class GridDhtLocalPartition implements Comparable, } }; -own = new GridFutureAdapter() { -@Override public String toString() { -return "PartitionOwnFuture [part=" + GridDhtLocalPartition.this + ", map=" + map + ']'; -} -}; - map = new ConcurrentHashMap8<>(cctx.config().getStartSize() / cctx.affinity().partitions()); @@ -426,8 +416,6 @@ public class GridDhtLocalPartition implements Comparable, // No need to keep history any more. evictHist = null; -own.onDone(); - return true; } } @@ -462,13 +450,6 @@ public class GridDhtLocalPartition implements Comparable, } /** - * @return The future which will be completed when partition will have state {@link GridDhtPartitionState#OWNING}. - */ -public IgniteInternalFuture owningFuture() { -return own; -} - -/** * @param updateSeq Update sequence. * @return Future for evict attempt. */
[24/50] incubator-ignite git commit: Merge branch 'ignite-sprint-6' into ignite-sprint-7
Merge branch 'ignite-sprint-6' into ignite-sprint-7 Conflicts: examples/pom.xml modules/aop/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/resources/ignite.properties modules/extdata/p2p/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/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 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/c6a0f24a Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/c6a0f24a Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/c6a0f24a Branch: refs/heads/ignite-843 Commit: c6a0f24adf62c58eb0b739183bbd8d572827ad14 Parents: 489ab0f d874b00 Author: vozerov-gridgain Authored: Thu Jun 18 11:21:44 2015 +0300 Committer: vozerov-gridgain Committed: Thu Jun 18 11:21:44 2015 +0300 -- .../s3/S3CheckpointManagerSelfTest.java | 2 +- .../checkpoint/s3/S3CheckpointSpiSelfTest.java | 4 +- .../s3/S3CheckpointSpiStartStopSelfTest.java| 2 +- .../s3/S3SessionCheckpointSelfTest.java | 2 +- .../s3/TcpDiscoveryS3IpFinderSelfTest.java | 2 +- .../client/GridClientConfiguration.java | 4 +- .../affinity/AffinityTopologyVersion.java | 7 - .../processors/cache/GridCacheAdapter.java | 4 + .../processors/cache/IgniteCacheProxy.java | 7 + .../distributed/dht/GridDhtLocalPartition.java | 56 +- .../dht/GridDhtPartitionTopologyImpl.java | 4 +- .../dht/GridDhtPartitionsReservation.java | 292 + .../dht/GridDhtTransactionalCacheAdapter.java | 2 +- .../cache/distributed/dht/GridReservable.java | 35 + .../dht/preloader/GridDhtPartitionMap.java | 26 +- .../cache/query/GridCacheQueryManager.java | 33 - .../cache/query/GridCacheTwoStepQuery.java | 22 +- .../cache/transactions/IgniteTxHandler.java | 2 +- .../transactions/IgniteTxLocalAdapter.java | 12 +- .../dr/IgniteDrDataStreamerCacheUpdater.java| 7 +- .../processors/query/GridQueryIndexing.java | 14 +- .../processors/query/GridQueryProcessor.java| 14 +- .../messages/GridQueryNextPageResponse.java | 34 +- .../h2/twostep/messages/GridQueryRequest.java | 111 +++- .../apache/ignite/internal/util/GridDebug.java | 19 + .../CacheStoreUsageMultinodeAbstractTest.java | 305 + ...eUsageMultinodeDynamicStartAbstractTest.java | 169 + ...oreUsageMultinodeDynamicStartAtomicTest.java | 32 + ...heStoreUsageMultinodeDynamicStartTxTest.java | 32 + ...reUsageMultinodeStaticStartAbstractTest.java | 158 + ...toreUsageMultinodeStaticStartAtomicTest.java | 32 + ...cheStoreUsageMultinodeStaticStartTxTest.java | 32 + .../cache/GridCacheAbstractFullApiSelfTest.java | 24 +- .../IgniteCacheAbstractStopBusySelfTest.java| 30 +- .../IgniteCacheAtomicStopBusySelfTest.java | 8 +- .../IgniteCacheP2pUnmarshallingTxErrorTest.java | 19 +- ...gniteCacheTransactionalStopBusySelfTest.java | 8 +- .../junits/GridTestKernalContext.java | 2 +- .../junits/common/GridCommonAbstractTest.java | 8 +- .../testsuites/IgniteCacheTestSuite4.java | 4 + .../processors/query/h2/IgniteH2Indexing.java | 79 ++- .../query/h2/sql/GridSqlQuerySplitter.java | 49 +- .../query/h2/twostep/GridMapQueryExecutor.java | 332 +++--- .../query/h2/twostep/GridMergeIndex.java| 17 +- .../h2/twostep/GridMergeIndexUnsorted.java | 7 +- .../h2/twostep/GridReduceQueryExecutor.java | 650 --- .../query/h2/twostep/GridResultPage.java| 21 +- .../cache/GridCacheCrossCacheQuerySelfTest.java | 3 +- .../IgniteCacheQueryMultiThreadedSelfTest.java | 1 - ...lientQueryReplicatedNodeRestartSelfTest.java | 419 .../IgniteCacheQueryNodeRestartSelfTest.java| 36 +- .../IgniteCacheQueryNodeRestartSelfTest2.java | 383 +++ .../IgniteCacheQuerySelfTestSuite.java
[25/50] incubator-ignite git commit: sprint-6 - ignite-indexing module check
sprint-6 - ignite-indexing module check Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/c1eee186 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/c1eee186 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/c1eee186 Branch: refs/heads/ignite-843 Commit: c1eee18615be56c7bb60d34614451612710b6cef Parents: d874b00 Author: S.Vladykin Authored: Thu Jun 18 13:39:19 2015 +0300 Committer: S.Vladykin Committed: Thu Jun 18 13:39:19 2015 +0300 -- .../ignite/internal/processors/cache/IgniteCacheProxy.java| 5 + .../ignite/internal/processors/query/GridQueryProcessor.java | 7 +++ 2 files changed, 12 insertions(+) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/c1eee186/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/IgniteCacheProxy.java -- diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/IgniteCacheProxy.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/IgniteCacheProxy.java index 0d70792..48fd259 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/IgniteCacheProxy.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/IgniteCacheProxy.java @@ -556,6 +556,11 @@ public class IgniteCacheProxy extends AsyncSupportAdapterhttp://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/c1eee186/modules/core/src/main/java/org/apache/ignite/internal/processors/query/GridQueryProcessor.java -- diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/query/GridQueryProcessor.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/query/GridQueryProcessor.java index 4f2486b..e080c6d 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/query/GridQueryProcessor.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/query/GridQueryProcessor.java @@ -107,6 +107,13 @@ public class GridQueryProcessor extends GridProcessorAdapter { } /** + * @return {@code true} If indexing module is in classpath and successfully initialized. + */ +public boolean moduleEnabled() { +return idx != null; +} + +/** * @param ccfg Cache configuration. * @throws IgniteCheckedException If failed. */
[26/50] incubator-ignite git commit: # minor
# minor Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/08d134dd Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/08d134dd Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/08d134dd Branch: refs/heads/ignite-843 Commit: 08d134dd43f143ee8d01f6394de27426c64a96ea Parents: d874b00 Author: Yakov Zhdanov Authored: Thu Jun 18 13:46:52 2015 +0300 Committer: Yakov Zhdanov Committed: Thu Jun 18 13:46:52 2015 +0300 -- .../ignite/internal/processors/cache/GridCacheUtils.java| 9 + 1 file changed, 9 insertions(+) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/08d134dd/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 3bd2a45..8c26046 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 @@ -391,6 +391,15 @@ public class GridCacheUtils { } /** + * Gets public cache name substituting null name by {@code 'default'}. + * + * @return Public cache name substituting null name by {@code 'default'}. + */ +public static String namexx(@Nullable String name) { +return name == null ? "default" : name; +} + +/** * @return Partition to state transformer. */ @SuppressWarnings({"unchecked"})
[14/50] incubator-ignite git commit: ignite-484-1 - relax test: 2 restarting nodes instead of 3
ignite-484-1 - relax test: 2 restarting nodes instead of 3 Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/ed43dfe1 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/ed43dfe1 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/ed43dfe1 Branch: refs/heads/ignite-843 Commit: ed43dfe1c7e9b7db3f6ef33a38dad9b28c41190c Parents: e602ca0 Author: S.Vladykin Authored: Wed Jun 17 20:33:54 2015 +0300 Committer: S.Vladykin Committed: Wed Jun 17 20:33:54 2015 +0300 -- .../near/IgniteCacheClientQueryReplicatedNodeRestartSelfTest.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/ed43dfe1/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/IgniteCacheClientQueryReplicatedNodeRestartSelfTest.java -- diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/IgniteCacheClientQueryReplicatedNodeRestartSelfTest.java b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/IgniteCacheClientQueryReplicatedNodeRestartSelfTest.java index 3f23005..b868cfb 100644 --- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/IgniteCacheClientQueryReplicatedNodeRestartSelfTest.java +++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/IgniteCacheClientQueryReplicatedNodeRestartSelfTest.java @@ -194,7 +194,7 @@ public class IgniteCacheClientQueryReplicatedNodeRestartSelfTest extends GridCom public void testRestarts() throws Exception { int duration = 90 * 1000; int qryThreadNum = 5; -int restartThreadsNum = 3; // 3 of 4 data nodes +int restartThreadsNum = 2; // 2 of 4 data nodes final int nodeLifeTime = 2 * 1000; final int logFreq = 10;
[19/50] incubator-ignite git commit: Merge branches 'ignite-484-1' and 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-sprint-6
Merge branches 'ignite-484-1' and 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-sprint-6 Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/de531896 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/de531896 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/de531896 Branch: refs/heads/ignite-843 Commit: de53189605c859a6eb9aa09c8181d5720c5dc28b Parents: 4cc376b eebf9c1 Author: S.Vladykin Authored: Thu Jun 18 09:51:50 2015 +0300 Committer: S.Vladykin Committed: Thu Jun 18 09:51:50 2015 +0300 -- .../affinity/AffinityTopologyVersion.java | 7 - .../distributed/dht/GridDhtLocalPartition.java | 56 +- .../dht/GridDhtPartitionsReservation.java | 292 + .../cache/distributed/dht/GridReservable.java | 35 + .../dht/preloader/GridDhtPartitionMap.java | 26 +- .../cache/query/GridCacheQueryManager.java | 33 - .../cache/query/GridCacheTwoStepQuery.java | 22 +- .../processors/query/GridQueryIndexing.java | 14 +- .../processors/query/GridQueryProcessor.java| 14 +- .../messages/GridQueryNextPageResponse.java | 34 +- .../h2/twostep/messages/GridQueryRequest.java | 111 +++- .../apache/ignite/internal/util/GridDebug.java | 19 + .../processors/query/h2/IgniteH2Indexing.java | 79 ++- .../query/h2/sql/GridSqlQuerySplitter.java | 49 +- .../query/h2/twostep/GridMapQueryExecutor.java | 332 +++--- .../query/h2/twostep/GridMergeIndex.java| 17 +- .../h2/twostep/GridMergeIndexUnsorted.java | 7 +- .../h2/twostep/GridReduceQueryExecutor.java | 650 --- .../query/h2/twostep/GridResultPage.java| 21 +- .../cache/GridCacheCrossCacheQuerySelfTest.java | 3 +- .../IgniteCacheQueryMultiThreadedSelfTest.java | 1 - ...lientQueryReplicatedNodeRestartSelfTest.java | 419 .../IgniteCacheQueryNodeRestartSelfTest.java| 36 +- .../IgniteCacheQueryNodeRestartSelfTest2.java | 383 +++ .../IgniteCacheQuerySelfTestSuite.java | 2 + 25 files changed, 2380 insertions(+), 282 deletions(-) --
[09/50] incubator-ignite git commit: Merge remote-tracking branch 'remotes/origin/ignite-1020' into ignite-sprint-6
Merge remote-tracking branch 'remotes/origin/ignite-1020' into ignite-sprint-6 Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/af829d0e Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/af829d0e Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/af829d0e Branch: refs/heads/ignite-843 Commit: af829d0ee0a646ac7ed96c65ddda7fc6f38212b0 Parents: 5218210 674072a Author: sboikov Authored: Wed Jun 17 17:19:58 2015 +0300 Committer: sboikov Committed: Wed Jun 17 17:19:58 2015 +0300 -- .../processors/cache/GridCacheAdapter.java | 4 + .../processors/cache/IgniteCacheProxy.java | 7 + .../dht/GridDhtTransactionalCacheAdapter.java | 2 +- .../cache/transactions/IgniteTxHandler.java | 2 +- .../transactions/IgniteTxLocalAdapter.java | 12 +- .../dr/IgniteDrDataStreamerCacheUpdater.java| 7 +- .../CacheStoreUsageMultinodeAbstractTest.java | 305 +++ ...eUsageMultinodeDynamicStartAbstractTest.java | 169 ++ ...oreUsageMultinodeDynamicStartAtomicTest.java | 32 ++ ...heStoreUsageMultinodeDynamicStartTxTest.java | 32 ++ ...reUsageMultinodeStaticStartAbstractTest.java | 158 ++ ...toreUsageMultinodeStaticStartAtomicTest.java | 32 ++ ...cheStoreUsageMultinodeStaticStartTxTest.java | 32 ++ .../testsuites/IgniteCacheTestSuite4.java | 4 + 14 files changed, 791 insertions(+), 7 deletions(-) --
[39/50] incubator-ignite git commit: # ignite-sprint-7 disabled shmem for test
# ignite-sprint-7 disabled shmem for 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/edc9a1c4 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/edc9a1c4 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/edc9a1c4 Branch: refs/heads/ignite-843 Commit: edc9a1c4b13afb8ef36a961f4d5b252135b916b6 Parents: 044f17d Author: sboikov Authored: Thu Jun 18 16:31:57 2015 +0300 Committer: sboikov Committed: Thu Jun 18 16:31:57 2015 +0300 -- .../processors/cache/distributed/IgniteCacheManyClientsTest.java| 1 + 1 file changed, 1 insertion(+) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/edc9a1c4/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java -- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java index c3223a2..48884de 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheManyClientsTest.java @@ -63,6 +63,7 @@ public class IgniteCacheManyClientsTest extends GridCommonAbstractTest { cfg.setTimeServerPortRange(200); ((TcpCommunicationSpi)cfg.getCommunicationSpi()).setLocalPortRange(200); + ((TcpCommunicationSpi)cfg.getCommunicationSpi()).setSharedMemoryPort(-1); ((TcpDiscoverySpi)cfg.getDiscoverySpi()).setIpFinder(ipFinder); ((TcpDiscoverySpi)cfg.getDiscoverySpi()).setJoinTimeout(2 * 60_000);
[28/50] incubator-ignite git commit: # ignite-1003 add lastSuccessfulAddr for ping
# ignite-1003 add lastSuccessfulAddr for ping Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/b23f9300 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/b23f9300 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/b23f9300 Branch: refs/heads/ignite-843 Commit: b23f9300794c7e84dfc83c1b8e49de673fa354e1 Parents: d874b00 Author: sboikov Authored: Thu Jun 18 13:52:45 2015 +0300 Committer: sboikov Committed: Thu Jun 18 13:52:45 2015 +0300 -- .../communication/tcp/TcpCommunicationSpi.java | 38 ++-- .../ignite/spi/discovery/tcp/ServerImpl.java| 21 +++ .../spi/discovery/tcp/TcpDiscoverySpi.java | 9 - .../tcp/internal/TcpDiscoveryNode.java | 18 ++ 4 files changed, 60 insertions(+), 26 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/b23f9300/modules/core/src/main/java/org/apache/ignite/spi/communication/tcp/TcpCommunicationSpi.java -- diff --git a/modules/core/src/main/java/org/apache/ignite/spi/communication/tcp/TcpCommunicationSpi.java b/modules/core/src/main/java/org/apache/ignite/spi/communication/tcp/TcpCommunicationSpi.java index 9e38788..39f4eeb 100644 --- a/modules/core/src/main/java/org/apache/ignite/spi/communication/tcp/TcpCommunicationSpi.java +++ b/modules/core/src/main/java/org/apache/ignite/spi/communication/tcp/TcpCommunicationSpi.java @@ -267,23 +267,19 @@ public class TcpCommunicationSpi extends IgniteSpiAdapter if (!isNodeStopping()) { GridNioRecoveryDescriptor recoveryData = ses.recoveryDescriptor(); -if (!getSpiContext().tryFailNode(id)) { -if (recoveryData != null) { -if (recoveryData.nodeAlive(getSpiContext().node(id))) { -if (!recoveryData.messagesFutures().isEmpty()) { -if (log.isDebugEnabled()) -log.debug("Session was closed but there are unacknowledged messages, " + -"will try to reconnect [rmtNode=" + recoveryData.node().id() + ']'); - - commWorker.addReconnectRequest(recoveryData); -} +if (recoveryData != null) { +if (recoveryData.nodeAlive(getSpiContext().node(id))) { +if (!recoveryData.messagesFutures().isEmpty()) { +if (log.isDebugEnabled()) +log.debug("Session was closed but there are unacknowledged messages, " + +"will try to reconnect [rmtNode=" + recoveryData.node().id() + ']'); + + commWorker.addReconnectRequest(recoveryData); } -else -recoveryData.onNodeLeft(); } +else +recoveryData.onNodeLeft(); } -else -recoveryData.onNodeLeft(); } } @@ -1884,18 +1880,20 @@ public class TcpCommunicationSpi extends IgniteSpiAdapter "TCP communication addresses or mapped external addresses. Check configuration and make sure " + "that you use the same communication SPI on all nodes. Remote node id: " + node.id()); -List addrs; +LinkedHashSet addrs; // Try to connect first on bound addresses. if (isRmtAddrsExist) { -addrs = new ArrayList<>(U.toSocketAddresses(rmtAddrs0, rmtHostNames0, boundPort)); +List addrs0 = new ArrayList<>(U.toSocketAddresses(rmtAddrs0, rmtHostNames0, boundPort)); boolean sameHost = U.sameMacs(getSpiContext().localNode(), node); -Collections.sort(addrs, U.inetAddressesComparator(sameHost)); +Collections.sort(addrs0, U.inetAddressesComparator(sameHost)); + +addrs = new LinkedHashSet<>(addrs0); } else -addrs = new ArrayList<>(); +addrs = new LinkedHashSet<>(); // Then on mapped external addresses. if (isExtAddrsExist) @@ -2610,7 +2608,9 @@ public class TcpCommunicationSpi extends IgniteSpiAdapter private vo
[22/50] incubator-ignite git commit: Merge remote-tracking branch 'origin/ignite-sprint-6' into ignite-sprint-6
Merge remote-tracking branch 'origin/ignite-sprint-6' into ignite-sprint-6 Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/6c683c28 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/6c683c28 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/6c683c28 Branch: refs/heads/ignite-843 Commit: 6c683c28f5bde0cf22ac7482bc381c861a2c6a62 Parents: cc20ef6 45939ac Author: sboikov Authored: Thu Jun 18 10:36:28 2015 +0300 Committer: sboikov Committed: Thu Jun 18 10:36:28 2015 +0300 -- .../ignite/spi/checkpoint/s3/S3CheckpointManagerSelfTest.java| 2 +- .../apache/ignite/spi/checkpoint/s3/S3CheckpointSpiSelfTest.java | 4 ++-- .../spi/checkpoint/s3/S3CheckpointSpiStartStopSelfTest.java | 2 +- .../ignite/spi/checkpoint/s3/S3SessionCheckpointSelfTest.java| 2 +- .../tcp/ipfinder/s3/TcpDiscoveryS3IpFinderSelfTest.java | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) --
[29/50] incubator-ignite git commit: # ignite-sprint-6 disabled shmem for test
# ignite-sprint-6 disabled shmem for 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/ca81476d Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/ca81476d Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/ca81476d Branch: refs/heads/ignite-843 Commit: ca81476d1ab66773815c7e3f91d61ea5b0651bb9 Parents: b23ea74 Author: sboikov Authored: Thu Jun 18 14:21:34 2015 +0300 Committer: sboikov Committed: Thu Jun 18 14:21:34 2015 +0300 -- .../datastreamer/DataStreamerMultiThreadedSelfTest.java | 3 +++ 1 file changed, 3 insertions(+) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/ca81476d/modules/core/src/test/java/org/apache/ignite/internal/processors/datastreamer/DataStreamerMultiThreadedSelfTest.java -- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/datastreamer/DataStreamerMultiThreadedSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/datastreamer/DataStreamerMultiThreadedSelfTest.java index e0092d4..c37219a 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/datastreamer/DataStreamerMultiThreadedSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/datastreamer/DataStreamerMultiThreadedSelfTest.java @@ -22,6 +22,7 @@ import org.apache.ignite.configuration.*; import org.apache.ignite.internal.*; import org.apache.ignite.internal.util.typedef.internal.*; import org.apache.ignite.lang.*; +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.*; @@ -48,6 +49,8 @@ public class DataStreamerMultiThreadedSelfTest extends GridCommonAbstractTest { @Override protected IgniteConfiguration getConfiguration(String gridName) throws Exception { IgniteConfiguration cfg = super.getConfiguration(gridName); + ((TcpCommunicationSpi)cfg.getCommunicationSpi()).setSharedMemoryPort(-1); + TcpDiscoverySpi discoSpi = new TcpDiscoverySpi(); discoSpi.setIpFinder(IP_FINDER);
[33/50] incubator-ignite git commit: # disco spi usability - doc and warning messages on failure detection speed up
# disco spi usability - doc and warning messages on failure detection speed up Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/fc81bcfd Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/fc81bcfd Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/fc81bcfd Branch: refs/heads/ignite-843 Commit: fc81bcfd0a4fd20e4322a060d7745754f14767e1 Parents: 31cf802 Author: Yakov Zhdanov Authored: Thu Jun 18 15:08:33 2015 +0300 Committer: Yakov Zhdanov Committed: Thu Jun 18 15:08:33 2015 +0300 -- .../java/org/apache/ignite/spi/discovery/tcp/ServerImpl.java | 4 .../org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpi.java | 7 --- 2 files changed, 8 insertions(+), 3 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/fc81bcfd/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 e9a949a..f7b6de9 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 @@ -2320,6 +2320,10 @@ class ServerImpl extends TcpDiscoveryImpl { for (TcpDiscoveryNode n : failedNodes) msgWorker.addMessage(new TcpDiscoveryNodeFailedMessage(locNodeId, n.id(), n.internalOrder())); + +LT.warn(log, null, "Local node has detected failed nodes and started cluster-wide procedure. " + +"To speed up failure detection please see 'Failure Detection' section under javadoc" + +"for 'TcpDiscoverySpi'"); } } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/fc81bcfd/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpi.java -- diff --git a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpi.java b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpi.java index 9a26867..d7c33a5 100644 --- a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpi.java +++ b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpi.java @@ -64,9 +64,9 @@ import java.util.concurrent.atomic.*; * {@link TcpDiscoveryIpFinder} about self start (stops when send succeeds) * and then this info goes to coordinator. When coordinator processes join request * and issues node added messages and all other nodes then receive info about new node. - * Configuration - * Important Notice - * Configuration defaults are chosen to make possible for discovery SPI to reliably work on + * Failure Detection + * Configuration defaults (see Configuration section below for details) + * are chosen to make possible for discovery SPI work reliably on * most of hardware and virtual deployments, but this has made failure detection time worse. * * For stable low-latency networks the following more aggressive settings are recommended @@ -76,6 +76,7 @@ import java.util.concurrent.atomic.*; * Socket timeout (see {@link #setSocketTimeout(long)}) - 200ms * Message acknowledgement timeout (see {@link #setAckTimeout(long)}) - 50ms * + * Configuration * Mandatory * There are no mandatory configuration parameters. * Optional
[02/50] incubator-ignite git commit: # i-484-1 review
# i-484-1 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/642f1c7a Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/642f1c7a Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/642f1c7a Branch: refs/heads/ignite-843 Commit: 642f1c7a2786fd95a43d97cc5b0d955ad890f0c4 Parents: 0b8587b Author: Yakov Zhdanov Authored: Wed Jun 17 15:14:16 2015 +0300 Committer: Yakov Zhdanov Committed: Wed Jun 17 15:14:16 2015 +0300 -- .../dht/GridDhtPartitionsReservation.java | 3 +- .../cache/query/GridCacheTwoStepQuery.java | 10 +++ .../IgniteCacheQueryNodeRestartSelfTest.java| 3 +- .../IgniteCacheQueryNodeRestartSelfTest2.java | 30 ++-- 4 files changed, 30 insertions(+), 16 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/642f1c7a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtPartitionsReservation.java -- diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtPartitionsReservation.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtPartitionsReservation.java index aced999..207c7f5 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtPartitionsReservation.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtPartitionsReservation.java @@ -218,7 +218,8 @@ public class GridDhtPartitionsReservation implements GridReservable { // Unregister from partitions. if (!F.isEmpty(arr) && parts.compareAndSet(arr, EMPTY)) { -// Reverse order makes sure that addReservation on the same topVer reservation will fail on the first partition. +// Reverse order makes sure that addReservation on the same topVer +// reservation will fail on the first partition. for (int i = arr.length - 1; i >= 0; i--) { GridDhtLocalPartition part = arr[i]; http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/642f1c7a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheTwoStepQuery.java -- diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheTwoStepQuery.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheTwoStepQuery.java index 1aa5890..1dacd10 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheTwoStepQuery.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheTwoStepQuery.java @@ -117,11 +117,6 @@ public class GridCacheTwoStepQuery { return mapQrys.values(); } -/** {@inheritDoc} */ -@Override public String toString() { -return S.toString(GridCacheTwoStepQuery.class, this); -} - /** * @return Spaces. */ @@ -135,4 +130,9 @@ public class GridCacheTwoStepQuery { public void spaces(Set spaces) { this.spaces = spaces; } + +/** {@inheritDoc} */ +@Override public String toString() { +return S.toString(GridCacheTwoStepQuery.class, this); +} } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/642f1c7a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/IgniteCacheQueryNodeRestartSelfTest.java -- diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/IgniteCacheQueryNodeRestartSelfTest.java b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/IgniteCacheQueryNodeRestartSelfTest.java index d729e4a..5c87603 100644 --- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/IgniteCacheQueryNodeRestartSelfTest.java +++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/distributed/near/IgniteCacheQueryNodeRestartSelfTest.java @@ -39,6 +39,7 @@ 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.*; /** * Test for distributed queries with node restarts. @@ -84,7 +85,7 @@ public class IgniteCacheQueryNodeRestartSelfTest extends GridCacheAbstractSelfTe cc.setBackups(1); cc.setWriteSynchronizationMode
[40/50] incubator-ignite git commit: Merge branch 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-sprint-7
Merge branch 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-sprint-7 Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/9458f125 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/9458f125 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/9458f125 Branch: refs/heads/ignite-843 Commit: 9458f12554579fd71a26f56d7bf191d0ec51173e Parents: edc9a1c ad0a026 Author: AKuznetsov Authored: Fri Jun 19 09:55:02 2015 +0700 Committer: AKuznetsov Committed: Fri Jun 19 09:55:02 2015 +0700 -- .../processors/cache/GridCacheUtils.java| 9 + .../processors/cache/IgniteCacheProxy.java | 5 +++ .../processors/query/GridQueryProcessor.java| 7 .../communication/tcp/TcpCommunicationSpi.java | 42 ++-- .../ignite/spi/discovery/tcp/ServerImpl.java| 35 .../spi/discovery/tcp/TcpDiscoverySpi.java | 42 ++-- .../tcp/internal/TcpDiscoveryNode.java | 18 + .../apache/ignite/internal/GridSelfTest.java| 20 ++ .../DataStreamerMultiThreadedSelfTest.java | 3 ++ 9 files changed, 132 insertions(+), 49 deletions(-) --
[31/50] incubator-ignite git commit: Merge remote-tracking branch 'origin/ignite-sprint-6' into ignite-sprint-6
Merge remote-tracking branch 'origin/ignite-sprint-6' into ignite-sprint-6 Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/cb862b65 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/cb862b65 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/cb862b65 Branch: refs/heads/ignite-843 Commit: cb862b65ffc1e0ecfc9a93b6af10881586df1ede Parents: 5011c2b ca81476 Author: Yakov Zhdanov Authored: Thu Jun 18 14:50:56 2015 +0300 Committer: Yakov Zhdanov Committed: Thu Jun 18 14:50:56 2015 +0300 -- .../datastreamer/DataStreamerMultiThreadedSelfTest.java | 3 +++ 1 file changed, 3 insertions(+) --
[20/50] incubator-ignite git commit: # ignite-sprint-6 fixed test to work in offheap mode
# ignite-sprint-6 fixed test to work in offheap mode Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/cc20ef6a Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/cc20ef6a Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/cc20ef6a Branch: refs/heads/ignite-843 Commit: cc20ef6adce9bdeea19d37f5817c0693e380cfa5 Parents: de53189 Author: sboikov Authored: Thu Jun 18 10:30:20 2015 +0300 Committer: sboikov Committed: Thu Jun 18 10:30:20 2015 +0300 -- .../cache/GridCacheAbstractFullApiSelfTest.java | 24 +++- 1 file changed, 13 insertions(+), 11 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/cc20ef6a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheAbstractFullApiSelfTest.java -- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheAbstractFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheAbstractFullApiSelfTest.java index 128d452..151c249 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheAbstractFullApiSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheAbstractFullApiSelfTest.java @@ -1020,25 +1020,27 @@ public abstract class GridCacheAbstractFullApiSelfTest extends GridCacheAbstract throws Exception { IgniteCache cache = jcache(); +final String key = primaryKeysForCache(cache, 1).get(0); + Transaction tx = txEnabled() ? ignite(0).transactions().txStart(concurrency, READ_COMMITTED) : null; try { if (startVal) -cache.put("key", 2); +cache.put(key, 2); else -assertEquals(null, cache.get("key")); +assertEquals(null, cache.get(key)); -Integer expectedRes = startVal ? 2 : null; +Integer expRes = startVal ? 2 : null; -assertEquals(String.valueOf(expectedRes), cache.invoke("key", INCR_PROCESSOR)); +assertEquals(String.valueOf(expRes), cache.invoke(key, INCR_PROCESSOR)); -expectedRes = startVal ? 3 : 1; +expRes = startVal ? 3 : 1; -assertEquals(String.valueOf(expectedRes), cache.invoke("key", INCR_PROCESSOR)); +assertEquals(String.valueOf(expRes), cache.invoke(key, INCR_PROCESSOR)); -expectedRes++; +expRes++; -assertEquals(String.valueOf(expectedRes), cache.invoke("key", INCR_PROCESSOR)); +assertEquals(String.valueOf(expRes), cache.invoke(key, INCR_PROCESSOR)); if (tx != null) tx.commit(); @@ -1050,11 +1052,11 @@ public abstract class GridCacheAbstractFullApiSelfTest extends GridCacheAbstract Integer exp = (startVal ? 2 : 0) + 3; -assertEquals(exp, cache.get("key")); +assertEquals(exp, cache.get(key)); for (int i = 0; i < gridCount(); i++) { -if (ignite(i).affinity(null).isPrimaryOrBackup(grid(i).localNode(), "key")) -assertEquals(exp, peek(jcache(i), "key")); +if (ignite(i).affinity(null).isPrimaryOrBackup(grid(i).localNode(), key)) +assertEquals(exp, peek(jcache(i), key)); } }
[49/50] incubator-ignite git commit: Merge branches 'ignite-843' and 'ignite-sprint-7' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-843
Merge branches 'ignite-843' and 'ignite-sprint-7' 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/08ac7ea4 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/08ac7ea4 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/08ac7ea4 Branch: refs/heads/ignite-843 Commit: 08ac7ea42fe1451c6158c459c0ac70b201fda3c5 Parents: ac52e0d ec9cfca Author: Andrey Authored: Mon Jun 22 08:47:36 2015 +0700 Committer: Andrey Committed: Mon Jun 22 08:47:36 2015 +0700 -- DEVNOTES.txt| 15 + RELEASE_NOTES.txt | 12 + examples/config/example-cache.xml | 2 + examples/pom.xml| 2 +- idea/ignite_codeStyle.xml | 147 + modules/aop/pom.xml | 2 +- modules/aws/pom.xml | 2 +- .../s3/S3CheckpointManagerSelfTest.java | 2 +- .../checkpoint/s3/S3CheckpointSpiSelfTest.java | 4 +- .../s3/S3CheckpointSpiStartStopSelfTest.java| 2 +- .../s3/S3SessionCheckpointSelfTest.java | 2 +- .../s3/TcpDiscoveryS3IpFinderSelfTest.java | 2 +- modules/clients/pom.xml | 2 +- .../client/router/TcpSslRouterSelfTest.java | 5 + .../client/suite/IgniteClientTestSuite.java | 3 +- modules/cloud/pom.xml | 2 +- .../cloud/TcpDiscoveryCloudIpFinder.java| 25 +- .../TcpDiscoveryCloudIpFinderSelfTest.java | 3 +- modules/codegen/pom.xml | 2 +- modules/core/pom.xml| 2 +- .../apache/ignite/cache/query/ScanQuery.java| 23 +- .../cache/store/jdbc/CacheJdbcBlobStore.java| 22 +- .../store/jdbc/CacheJdbcBlobStoreFactory.java | 290 + .../cache/store/jdbc/CacheJdbcPojoStore.java| 6 +- .../store/jdbc/CacheJdbcPojoStoreFactory.java | 148 + .../configuration/CacheConfiguration.java | 3 +- .../ignite/internal/GridKernalContextImpl.java | 5 +- .../ignite/internal/GridPluginContext.java | 6 + .../apache/ignite/internal/IgniteKernal.java| 13 +- .../internal/MarshallerContextAdapter.java | 48 +- .../ignite/internal/MarshallerContextImpl.java | 24 +- .../client/GridClientConfiguration.java | 2 +- .../GridClientOptimizedMarshaller.java | 26 + .../impl/GridTcpRouterNioListenerAdapter.java | 2 +- .../internal/interop/InteropBootstrap.java | 3 +- .../internal/interop/InteropIgnition.java | 57 +- .../internal/interop/InteropProcessor.java | 8 + .../discovery/GridDiscoveryManager.java | 9 +- .../affinity/AffinityTopologyVersion.java | 7 - .../processors/cache/GridCacheAdapter.java | 4 + .../processors/cache/GridCacheIoManager.java| 64 +- .../processors/cache/GridCacheMessage.java | 51 -- .../GridCachePartitionExchangeManager.java | 70 +- .../processors/cache/GridCacheProcessor.java| 61 +- .../processors/cache/GridCacheUtils.java| 9 + .../processors/cache/IgniteCacheProxy.java | 12 + .../processors/cache/KeyCacheObjectImpl.java| 11 +- .../distributed/GridCacheTxRecoveryRequest.java | 26 +- .../GridCacheTxRecoveryResponse.java| 14 +- .../distributed/GridDistributedBaseMessage.java | 77 +-- .../distributed/GridDistributedLockRequest.java | 54 +- .../GridDistributedLockResponse.java| 14 +- .../GridDistributedTxFinishRequest.java | 46 +- .../GridDistributedTxPrepareRequest.java| 62 +- .../GridDistributedTxPrepareResponse.java | 64 +- .../GridDistributedUnlockRequest.java | 6 +- .../distributed/dht/GridDhtLocalPartition.java | 56 +- .../distributed/dht/GridDhtLockRequest.java | 72 +- .../distributed/dht/GridDhtLockResponse.java| 18 +- .../dht/GridDhtPartitionTopologyImpl.java | 4 +- .../dht/GridDhtPartitionsReservation.java | 292 + .../dht/GridDhtTransactionalCacheAdapter.java | 2 +- .../distributed/dht/GridDhtTxFinishRequest.java | 38 +- .../dht/GridDhtTxPrepareRequest.java| 54 +- .../dht/GridDhtTxPrepareResponse.java | 22 +- .../distributed/dht/GridDhtUnlockRequest.java | 6 +- .../cache/distributed/dht/GridReservable.java | 35 + .../dht/preloader/GridDhtPartitionMap.java | 26 +- .../dht/preloader/GridDhtPreloader.java | 2 +- .../distributed/near/GridNearLockRequest.java | 58 +- .../distributed/near/GridNearLockResponse.java | 26 +- .../near/GridNearTxFinishRequest.java | 26 +- .../near/GridNearTxPrepareRequest.java | 50 +- .../near/GridNearTxPrepareRes
[13/50] incubator-ignite git commit: ignite-484-1 - error messages
ignite-484-1 - error 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/e602ca01 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/e602ca01 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/e602ca01 Branch: refs/heads/ignite-843 Commit: e602ca01e48fd43f4cc33b729078c105d84601f6 Parents: efb4244 Author: S.Vladykin Authored: Wed Jun 17 20:15:45 2015 +0300 Committer: S.Vladykin Committed: Wed Jun 17 20:15:45 2015 +0300 -- .../query/h2/twostep/GridMapQueryExecutor.java | 4 +-- .../h2/twostep/GridReduceQueryExecutor.java | 31 ++-- 2 files changed, 17 insertions(+), 18 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/e602ca01/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java -- diff --git a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java index 2503a87..ba95d43 100644 --- a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java +++ b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java @@ -401,7 +401,7 @@ public class GridMapQueryExecutor { } } catch (IgniteCheckedException e) { -throw new CacheException(e); +throw new CacheException("Failed to unmarshall parameters.", e); } List caches = (List)F.concat(true, req.space(), req.extraSpaces()); @@ -422,7 +422,7 @@ public class GridMapQueryExecutor { GridCacheContext mainCctx = cacheContext(req.space()); if (mainCctx == null) -throw new CacheException("Cache was destroyed: " + req.space()); +throw new CacheException("Failed to find cache: " + req.space()); qr = new QueryResults(req.requestId(), qrys.size(), mainCctx); http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/e602ca01/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridReduceQueryExecutor.java -- diff --git a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridReduceQueryExecutor.java b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridReduceQueryExecutor.java index b956167..32d1c95 100644 --- a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridReduceQueryExecutor.java +++ b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridReduceQueryExecutor.java @@ -338,7 +338,7 @@ public class GridReduceQueryExecutor { Set nodes = new HashSet<>(dataNodes(space, topVer)); if (F.isEmpty(nodes)) -throw new CacheException("No data nodes found for cache: " + space); +throw new CacheException("Failed to find data nodes for cache: " + space); if (!F.isEmpty(extraSpaces)) { for (String extraSpace : extraSpaces) { @@ -349,12 +349,12 @@ public class GridReduceQueryExecutor { if (cctx.isReplicated() && !extraCctx.isReplicated()) throw new CacheException("Queries running on replicated cache should not contain JOINs " + -"with partitioned tables."); +"with partitioned tables [rCache=" + cctx.name() + ", pCache=" + extraSpace + "]"); Collection extraNodes = dataNodes(extraSpace, topVer); if (F.isEmpty(extraNodes)) -throw new CacheException("No data nodes found for cache: " + extraSpace); +throw new CacheException("Failed to find data nodes for cache: " + extraSpace); if (cctx.isReplicated() && extraCctx.isReplicated()) { nodes.retainAll(extraNodes); @@ -363,8 +363,8 @@ public class GridReduceQueryExecutor { if (isPreloadingActive(cctx, extraSpaces)) return null; // Retry. else -throw new CacheException("Caches '" + cctx.name() + "' and '" + extraSpace + -"' have distinct set of data nodes."); +throw new CacheException("Caches have distinct sets of data nodes [cache1=" + cctx.name() + +
[48/50] incubator-ignite git commit: Merge branch 'ignite-sprint-6' into ignite-sprint-7
Merge branch 'ignite-sprint-6' into ignite-sprint-7 Conflicts: examples/pom.xml modules/aop/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/resources/ignite.properties modules/extdata/p2p/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/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 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/ec9cfcaf Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/ec9cfcaf Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/ec9cfcaf Branch: refs/heads/ignite-843 Commit: ec9cfcaf8b245be6fe4723b1e2d08526d3a6d4cb Parents: 8fa9d3d d699faa Author: vozerov-gridgain Authored: Fri Jun 19 15:32:21 2015 +0300 Committer: vozerov-gridgain Committed: Fri Jun 19 15:32:21 2015 +0300 -- .../spi/discovery/tcp/TcpDiscoverySelfTest.java | 44 ++-- 1 file changed, 41 insertions(+), 3 deletions(-) --
[16/50] incubator-ignite git commit: Merge branches 'ignite-484-1' and 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-484-1
Merge branches 'ignite-484-1' and 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-484-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/eebf9c1c Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/eebf9c1c Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/eebf9c1c Branch: refs/heads/ignite-843 Commit: eebf9c1c7fa07b442e4a341ffa2b5ce2828032c4 Parents: ed43dfe fffc2ec Author: S.Vladykin Authored: Thu Jun 18 09:43:45 2015 +0300 Committer: S.Vladykin Committed: Thu Jun 18 09:43:45 2015 +0300 -- .../dht/GridDhtPartitionTopologyImpl.java| 4 +++- .../IgniteCacheP2pUnmarshallingTxErrorTest.java | 19 ++- .../junits/common/GridCommonAbstractTest.java| 8 ++-- 3 files changed, 19 insertions(+), 12 deletions(-) --
[30/50] incubator-ignite git commit: # changed defaults for discovery
# changed defaults for discovery Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/5011c2b5 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/5011c2b5 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/5011c2b5 Branch: refs/heads/ignite-843 Commit: 5011c2b5e9671ced95e21f122c2e5ef9102c19fe Parents: b23ea74 Author: Yakov Zhdanov Authored: Thu Jun 18 14:50:43 2015 +0300 Committer: Yakov Zhdanov Committed: Thu Jun 18 14:50:43 2015 +0300 -- .../communication/tcp/TcpCommunicationSpi.java | 6 ++-- .../spi/discovery/tcp/TcpDiscoverySpi.java | 32 +--- 2 files changed, 24 insertions(+), 14 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/5011c2b5/modules/core/src/main/java/org/apache/ignite/spi/communication/tcp/TcpCommunicationSpi.java -- diff --git a/modules/core/src/main/java/org/apache/ignite/spi/communication/tcp/TcpCommunicationSpi.java b/modules/core/src/main/java/org/apache/ignite/spi/communication/tcp/TcpCommunicationSpi.java index 9e38788..fc504f4 100644 --- a/modules/core/src/main/java/org/apache/ignite/spi/communication/tcp/TcpCommunicationSpi.java +++ b/modules/core/src/main/java/org/apache/ignite/spi/communication/tcp/TcpCommunicationSpi.java @@ -174,8 +174,8 @@ public class TcpCommunicationSpi extends IgniteSpiAdapter /** Default socket send and receive buffer size. */ public static final int DFLT_SOCK_BUF_SIZE = 32 * 1024; -/** Default connection timeout (value is 1000ms). */ -public static final long DFLT_CONN_TIMEOUT = 1000; +/** Default connection timeout (value is 5000ms). */ +public static final long DFLT_CONN_TIMEOUT = 5000; /** Default Maximum connection timeout (value is 600,000ms). */ public static final long DFLT_MAX_CONN_TIMEOUT = 10 * 60 * 1000; @@ -680,7 +680,7 @@ public class TcpCommunicationSpi extends IgniteSpiAdapter /** Recovery and idle clients handler. */ private CommunicationWorker commWorker; - + /** Shared memory accept worker. */ private ShmemAcceptWorker shmemAcceptWorker; http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/5011c2b5/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpi.java -- diff --git a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpi.java b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpi.java index e4ef744..9a26867 100644 --- a/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpi.java +++ b/modules/core/src/main/java/org/apache/ignite/spi/discovery/tcp/TcpDiscoverySpi.java @@ -21,7 +21,6 @@ import org.apache.ignite.*; import org.apache.ignite.cluster.*; import org.apache.ignite.configuration.*; import org.apache.ignite.internal.*; -import org.apache.ignite.internal.util.*; import org.apache.ignite.internal.util.io.*; import org.apache.ignite.internal.util.tostring.*; import org.apache.ignite.internal.util.typedef.*; @@ -66,6 +65,17 @@ import java.util.concurrent.atomic.*; * and then this info goes to coordinator. When coordinator processes join request * and issues node added messages and all other nodes then receive info about new node. * Configuration + * Important Notice + * Configuration defaults are chosen to make possible for discovery SPI to reliably work on + * most of hardware and virtual deployments, but this has made failure detection time worse. + * + * For stable low-latency networks the following more aggressive settings are recommended + * (which allows failure detection time ~200ms): + * + * Heartbeat frequency (see {@link #setHeartbeatFrequency(long)}) - 100ms + * Socket timeout (see {@link #setSocketTimeout(long)}) - 200ms + * Message acknowledgement timeout (see {@link #setAckTimeout(long)}) - 50ms + * * Mandatory * There are no mandatory configuration parameters. * Optional @@ -164,23 +174,23 @@ public class TcpDiscoverySpi extends IgniteSpiAdapter implements DiscoverySpi, T /** Default value for thread priority (value is 10). */ public static final int DFLT_THREAD_PRI = 10; -/** Default heartbeat messages issuing frequency (value is 100ms). */ -public static final long DFLT_HEARTBEAT_FREQ = 100; +/** Default heartbeat messages issuing frequency (value is 2000ms). */ +public static final long DFLT_HEARTBEAT_FREQ = 2000; /** Default size of topology snapshots history. */ public static final int DFLT_TOP_HISTORY_SIZE = 1000; -/** Default socket operations timeout in milliseconds (value is 200ms). */ -public stat
[06/50] incubator-ignite git commit: Added tests on EVT_CACHE_REBALANCE_PART_DATA_LOST event.
Added tests on EVT_CACHE_REBALANCE_PART_DATA_LOST event. Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/8c2553ed Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/8c2553ed Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/8c2553ed Branch: refs/heads/ignite-843 Commit: 8c2553eda7ea68498c1d0235060b20f31ef55c8a Parents: 01eee2d Author: nikolay_tikhonov Authored: Wed Jun 17 16:12:48 2015 +0300 Committer: nikolay_tikhonov Committed: Wed Jun 17 16:12:48 2015 +0300 -- ...ridCachePartitionNotLoadedEventSelfTest.java | 82 .../ignite/util/TestTcpCommunicationSpi.java| 21 + 2 files changed, 103 insertions(+) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8c2553ed/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCachePartitionNotLoadedEventSelfTest.java -- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCachePartitionNotLoadedEventSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCachePartitionNotLoadedEventSelfTest.java index 6da27d5..baa6d89 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCachePartitionNotLoadedEventSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCachePartitionNotLoadedEventSelfTest.java @@ -22,15 +22,19 @@ import org.apache.ignite.cache.*; import org.apache.ignite.cache.affinity.*; import org.apache.ignite.configuration.*; import org.apache.ignite.events.*; +import org.apache.ignite.internal.*; +import org.apache.ignite.internal.processors.cache.distributed.dht.preloader.*; import org.apache.ignite.lang.*; 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.util.*; import org.eclipse.jetty.util.*; import java.util.*; +import java.util.concurrent.*; /** * @@ -150,6 +154,84 @@ public class GridCachePartitionNotLoadedEventSelfTest extends GridCommonAbstract } /** + * @throws Exception If failed. + */ +public void testStableTopology() throws Exception { +backupCnt = 1; + +startGrid(1); + +awaitPartitionMapExchange(); + +startGrid(0); + +PartitionNotFullyLoadedListener lsnr = new PartitionNotFullyLoadedListener(); + +grid(1).events().localListen(lsnr, EventType.EVT_CACHE_REBALANCE_PART_DATA_LOST); + +IgniteCache cache0 = jcache(0); + +int key = primaryKey(cache0); + +jcache(1).put(key, key); + +assert cache0.containsKey(key); + +TestTcpCommunicationSpi.stop(ignite(0)); + +stopGrid(0, true); + +awaitPartitionMapExchange(); + +assert jcache(1).containsKey(key); + +assert lsnr.lostParts.isEmpty(); +} + + +/** + * @throws Exception If failed. + */ +public void testMapPartitioned() throws Exception { +backupCnt = 0; + +startGrid(0); + +startGrid(1); + +PartitionNotFullyLoadedListener lsnr = new PartitionNotFullyLoadedListener(); + +grid(1).events().localListen(lsnr, EventType.EVT_CACHE_REBALANCE_PART_DATA_LOST); + +TestTcpCommunicationSpi.skipMsgType(ignite(0), GridDhtPartitionsFullMessage.class); + +IgniteInternalFuture fut = GridTestUtils.runAsync(new Callable() { +@Override public Object call() throws Exception { +startGrid(2); + +return null; +} +}); + +boolean timeout = false; + +try { +fut.get(1, TimeUnit.SECONDS); +} +catch (IgniteFutureTimeoutCheckedException e) { +timeout = true; +} + +assert timeout; + +stopGrid(0, true); + +awaitPartitionMapExchange(); + +assert !lsnr.lostParts.isEmpty(); +} + +/** * */ private static class PartitionNotFullyLoadedListener implements IgnitePredicate { http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/8c2553ed/modules/core/src/test/java/org/apache/ignite/util/TestTcpCommunicationSpi.java -- diff --git a/modules/core/src/test/java/org/apache/ignite/util/TestTcpCommunicationSpi.java b/modules/core/src/test/java/org/apache/ignite/util/TestTcpCommunicationSpi.java index ad2a262..6e4e50b 100644 --- a/mod
[04/50] incubator-ignite git commit: # ignite-1020 do not write to store for local store load
# ignite-1020 do not write to store for local store load Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/674072a3 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/674072a3 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/674072a3 Branch: refs/heads/ignite-843 Commit: 674072a336a2aa276373a5f6820a9e66df88ede8 Parents: e507f03 Author: sboikov Authored: Wed Jun 17 15:31:57 2015 +0300 Committer: sboikov Committed: Wed Jun 17 15:31:57 2015 +0300 -- .../ignite/internal/processors/cache/GridCacheAdapter.java| 4 .../ignite/internal/processors/cache/IgniteCacheProxy.java| 7 +++ .../processors/dr/IgniteDrDataStreamerCacheUpdater.java | 7 ++- 3 files changed, 17 insertions(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/674072a3/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 2ca7687..7335d72 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 @@ -3305,6 +3305,8 @@ public abstract class GridCacheAdapter implements IgniteInternalCache implements IgniteInternalCachehttp://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/674072a3/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/IgniteCacheProxy.java -- diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/IgniteCacheProxy.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/IgniteCacheProxy.java index 69ce7b0..0d70792 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/IgniteCacheProxy.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/IgniteCacheProxy.java @@ -139,6 +139,13 @@ public class IgniteCacheProxy extends AsyncSupportAdapterhttp://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/674072a3/modules/core/src/main/java/org/apache/ignite/internal/processors/dr/IgniteDrDataStreamerCacheUpdater.java -- diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/dr/IgniteDrDataStreamerCacheUpdater.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/dr/IgniteDrDataStreamerCacheUpdater.java index c3a8989..e5bbe39 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/dr/IgniteDrDataStreamerCacheUpdater.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/dr/IgniteDrDataStreamerCacheUpdater.java @@ -46,7 +46,12 @@ public class IgniteDrDataStreamerCacheUpdater implements StreamReceiver
[45/50] incubator-ignite git commit: 1.1.6-SNAPSHOT
1.1.6-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/d0063897 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/d0063897 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/d0063897 Branch: refs/heads/ignite-843 Commit: d0063897052b97398a93bd3ac32fd573d0d7f3d3 Parents: 188cd82 Author: Ignite Teamcity Authored: Fri Jun 19 12:56:32 2015 +0300 Committer: Ignite Teamcity Committed: Fri Jun 19 12:56:32 2015 +0300 -- examples/pom.xml | 2 +- modules/aop/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/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/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 +- pom.xml | 2 +- 37 files changed, 37 insertions(+), 37 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/d0063897/examples/pom.xml -- diff --git a/examples/pom.xml b/examples/pom.xml index 834b5b4..bcff11e 100644 --- a/examples/pom.xml +++ b/examples/pom.xml @@ -28,7 +28,7 @@ ignite-examples -1.1.4-SNAPSHOT +1.1.6-SNAPSHOT http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/d0063897/modules/aop/pom.xml -- diff --git a/modules/aop/pom.xml b/modules/aop/pom.xml index e9cc980..5eea18d 100644 --- a/modules/aop/pom.xml +++ b/modules/aop/pom.xml @@ -31,7 +31,7 @@ ignite-aop -1.1.4-SNAPSHOT +1.1.6-SNAPSHOT http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/d0063897/modules/aws/pom.xml -- diff --git a/modules/aws/pom.xml b/modules/aws/pom.xml index 1d3b1f3..05ecbc1 100644 --- a/modules/aws/pom.xml +++ b/modules/aws/pom.xml @@ -31,7 +31,7 @@ ignite-aws -1.1.4-SNAPSHOT +1.1.6-SNAPSHOT http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/d0063897/modules/clients/pom.xml -- diff --git a/modules/clients/pom.xml b/modules/clients/pom.xml index 6b28630..7c4d2c8 100644 --- a/modules/clients/pom.xml +++ b/modules/clients/pom.xml @@ -31,7 +31,7 @@ ignite-clients -1.1.4-SNAPSHOT +1.1.6-SNAPSHOT http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/d0063897/modules/cloud/pom.xml -- diff --git a/modules/cloud/pom.xml b/modules/cloud/pom.xml index 0c9cd3d..bb32689 100644 --- a/modules/cloud/pom.xml +++ b/modules/cloud/pom.xml @@ -29,7 +29,7 @@ ignite-cloud -1.1.4-SNAPSHOT +1.1.6-SNAPSHOT 1.9.0 http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/d0063897/modules
[07/50] incubator-ignite git commit: 1.1.4-SNAPSHOT
1.1.4-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/489ab0f1 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/489ab0f1 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/489ab0f1 Branch: refs/heads/ignite-843 Commit: 489ab0f1a6b24460bf1896798780b2203a1f5d27 Parents: 8c2553e Author: Ignite Teamcity Authored: Wed Jun 17 16:54:34 2015 +0300 Committer: Ignite Teamcity Committed: Wed Jun 17 16:54:34 2015 +0300 -- examples/pom.xml | 2 +- modules/aop/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/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/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 +- pom.xml | 2 +- 37 files changed, 37 insertions(+), 37 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/489ab0f1/examples/pom.xml -- diff --git a/examples/pom.xml b/examples/pom.xml index 016b3ce..834b5b4 100644 --- a/examples/pom.xml +++ b/examples/pom.xml @@ -28,7 +28,7 @@ ignite-examples -1.1.2-SNAPSHOT +1.1.4-SNAPSHOT http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/489ab0f1/modules/aop/pom.xml -- diff --git a/modules/aop/pom.xml b/modules/aop/pom.xml index e04f183..e9cc980 100644 --- a/modules/aop/pom.xml +++ b/modules/aop/pom.xml @@ -31,7 +31,7 @@ ignite-aop -1.1.2-SNAPSHOT +1.1.4-SNAPSHOT http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/489ab0f1/modules/aws/pom.xml -- diff --git a/modules/aws/pom.xml b/modules/aws/pom.xml index f7fdfbc..1d3b1f3 100644 --- a/modules/aws/pom.xml +++ b/modules/aws/pom.xml @@ -31,7 +31,7 @@ ignite-aws -1.1.2-SNAPSHOT +1.1.4-SNAPSHOT http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/489ab0f1/modules/clients/pom.xml -- diff --git a/modules/clients/pom.xml b/modules/clients/pom.xml index 7842c47..6b28630 100644 --- a/modules/clients/pom.xml +++ b/modules/clients/pom.xml @@ -31,7 +31,7 @@ ignite-clients -1.1.2-SNAPSHOT +1.1.4-SNAPSHOT http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/489ab0f1/modules/cloud/pom.xml -- diff --git a/modules/cloud/pom.xml b/modules/cloud/pom.xml index 579c6a0..0c9cd3d 100644 --- a/modules/cloud/pom.xml +++ b/modules/cloud/pom.xml @@ -29,7 +29,7 @@ ignite-cloud -1.1.2-SNAPSHOT +1.1.4-SNAPSHOT 1.9.0 http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/489ab0f1/modules
[10/50] incubator-ignite git commit: # i-484-1 review
# i-484-1 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/42982382 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/42982382 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/42982382 Branch: refs/heads/ignite-843 Commit: 42982382ee92bc12073beac34d72590bf905ed3e Parents: 10febf2 Author: Yakov Zhdanov Authored: Wed Jun 17 18:12:49 2015 +0300 Committer: Yakov Zhdanov Committed: Wed Jun 17 18:12:49 2015 +0300 -- .../processors/query/h2/twostep/GridReduceQueryExecutor.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/42982382/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridReduceQueryExecutor.java -- diff --git a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridReduceQueryExecutor.java b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridReduceQueryExecutor.java index c570d24..6c407d9 100644 --- a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridReduceQueryExecutor.java +++ b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridReduceQueryExecutor.java @@ -438,7 +438,8 @@ public class GridReduceQueryExecutor { assert !nodes.isEmpty(); if (cctx.isReplicated() || qry.explain()) { -assert qry.explain() || !nodes.contains(ctx.cluster().get().localNode()) : "We must be on a client node."; +assert qry.explain() || !nodes.contains(ctx.cluster().get().localNode()) : +"We must be on a client node."; // Select random data node to run query on a replicated data or get EXPLAIN PLAN from a single node. nodes = Collections.singleton(F.rand(nodes));
[17/50] incubator-ignite git commit: Fixed test.
Fixed 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/fa6615a8 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/fa6615a8 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/fa6615a8 Branch: refs/heads/ignite-843 Commit: fa6615a8665fb8296c63be3e719d6d186293ea0c Parents: 5218210 Author: nikolay_tikhonov Authored: Thu Jun 18 09:44:45 2015 +0300 Committer: nikolay_tikhonov Committed: Thu Jun 18 09:44:45 2015 +0300 -- .../apache/ignite/testframework/junits/GridTestKernalContext.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/fa6615a8/modules/core/src/test/java/org/apache/ignite/testframework/junits/GridTestKernalContext.java -- diff --git a/modules/core/src/test/java/org/apache/ignite/testframework/junits/GridTestKernalContext.java b/modules/core/src/test/java/org/apache/ignite/testframework/junits/GridTestKernalContext.java index 37948d9..24502da 100644 --- a/modules/core/src/test/java/org/apache/ignite/testframework/junits/GridTestKernalContext.java +++ b/modules/core/src/test/java/org/apache/ignite/testframework/junits/GridTestKernalContext.java @@ -46,7 +46,7 @@ public class GridTestKernalContext extends GridKernalContextImpl { null, null, null, -null); +U.allPluginProviders()); GridTestUtils.setFieldValue(grid(), "cfg", config());
[11/50] incubator-ignite git commit: ignite-484-1 - improved retry
ignite-484-1 - improved retry Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/94060c9e Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/94060c9e Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/94060c9e Branch: refs/heads/ignite-843 Commit: 94060c9ef41161c7262a28044ddb176f86814b01 Parents: 10febf2 Author: S.Vladykin Authored: Wed Jun 17 19:46:42 2015 +0300 Committer: S.Vladykin Committed: Wed Jun 17 19:46:42 2015 +0300 -- .../query/h2/twostep/GridMapQueryExecutor.java | 26 -- .../h2/twostep/GridReduceQueryExecutor.java | 86 ++-- ...lientQueryReplicatedNodeRestartSelfTest.java | 50 ++-- 3 files changed, 125 insertions(+), 37 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/94060c9e/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java -- diff --git a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java index aaf64ee..2503a87 100644 --- a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java +++ b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java @@ -48,6 +48,7 @@ import java.util.concurrent.*; import java.util.concurrent.atomic.*; import static org.apache.ignite.events.EventType.*; +import static org.apache.ignite.internal.processors.affinity.AffinityTopologyVersion.*; import static org.apache.ignite.internal.processors.cache.distributed.dht.GridDhtPartitionState.*; import static org.apache.ignite.internal.processors.query.h2.twostep.msg.GridH2ValueMessageFactory.*; @@ -230,6 +231,15 @@ public class GridMapQueryExecutor { } /** + * @param cctx Cache context. + * @param p Partition ID. + * @return Partition. + */ +private GridDhtLocalPartition partition(GridCacheContext cctx, int p) { +return cctx.topology().localPartition(p, NONE, false); +} + +/** * @param cacheNames Cache names. * @param topVer Topology version. * @param explicitParts Explicit partitions list. @@ -263,10 +273,12 @@ public class GridMapQueryExecutor { GridReservable r = reservations.get(grpKey); if (explicitParts == null && r != null) { // Try to reserve group partition if any and no explicits. -if (!r.reserve()) -return false; // We need explicit partitions here -> retry. +if (r != ReplicatedReservation.INSTANCE) { +if (!r.reserve()) +return false; // We need explicit partitions here -> retry. -reserved.add(r); +reserved.add(r); +} } else { // Try to reserve partitions one by one. int partsCnt = cctx.affinity().partitions(); @@ -274,7 +286,7 @@ public class GridMapQueryExecutor { if (cctx.isReplicated()) { // Check all the partitions are in owning state for replicated cache. if (r == null) { // Check only once. for (int p = 0; p < partsCnt; p++) { -GridDhtLocalPartition part = cctx.topology().localPartition(p, topVer, false); +GridDhtLocalPartition part = partition(cctx, p); // We don't need to reserve partitions because they will not be evicted in replicated caches. if (part == null || part.state() != OWNING) @@ -290,7 +302,7 @@ public class GridMapQueryExecutor { partIds = cctx.affinity().primaryPartitions(ctx.localNodeId(), topVer); for (int partId : partIds) { -GridDhtLocalPartition part = cctx.topology().localPartition(partId, topVer, false); +GridDhtLocalPartition part = partition(cctx, partId); if (part == null || part.state() != OWNING || !part.reserve()) return false; @@ -806,12 +818,12 @@ public class GridMapQueryExecutor { /** {@inheritDoc} */ @Override public boolean reserve() { -return true; +throw new IllegalStateException(); } /** {@inheritDoc} */ @Override public void release() { -// No-op. +throw new IllegalStateException(); } } } http://
incubator-ignite git commit: IGNITE-621 - Retries.
Repository: incubator-ignite Updated Branches: refs/heads/ignite-621 5505b4d3d -> c94c0c475 IGNITE-621 - 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/c94c0c47 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/c94c0c47 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/c94c0c47 Branch: refs/heads/ignite-621 Commit: c94c0c475b8d8ac5c31302235d0de36f791fc3a0 Parents: 5505b4d Author: Alexey Goncharuk Authored: Sun Jun 21 22:40:01 2015 -0700 Committer: Alexey Goncharuk Committed: Sun Jun 21 22:40:01 2015 -0700 -- .../dht/atomic/GridNearAtomicUpdateFuture.java | 19 +-- 1 file changed, 13 insertions(+), 6 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/c94c0c47/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/atomic/GridNearAtomicUpdateFuture.java -- diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/atomic/GridNearAtomicUpdateFuture.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/atomic/GridNearAtomicUpdateFuture.java index 53150cc..536eb40 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/atomic/GridNearAtomicUpdateFuture.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/atomic/GridNearAtomicUpdateFuture.java @@ -338,19 +338,21 @@ public class GridNearAtomicUpdateFuture extends GridFutureAdapter cctx.mvcc().removeAtomicFuture(version()); Collection remapKeys = new ArrayList<>(failed.size()); -Collection remapVals = new ArrayList<>(failed.size()); +Collection remapVals = vals != null ? new ArrayList<>(failed.size()) : null; Iterator keyIt = keys.iterator(); -Iterator valsIt = vals.iterator(); +Iterator valsIt = vals != null ? vals.iterator() : null; for (Object key : failed) { while (keyIt.hasNext()) { Object nextKey = keyIt.next(); -Object nextVal = valsIt.next(); +Object nextVal = valsIt != null ? valsIt.next() : null; if (F.eq(key, nextKey)) { remapKeys.add(nextKey); -remapVals.add(nextVal); + +if (remapVals != null) +remapVals.add(nextVal); break; } @@ -388,8 +390,13 @@ public class GridNearAtomicUpdateFuture extends GridFutureAdapter if (op == TRANSFORM && retval == null) retval = Collections.emptyMap(); -if (err != null && X.hasCause(err, CachePartialUpdateCheckedException.class) && remapCnt.decrementAndGet() > 0) { -remap(X.cause(err, CachePartialUpdateCheckedException.class).failedKeys()); +if (err != null && X.hasCause(err, CachePartialUpdateCheckedException.class) && +X.hasCause(err, ClusterTopologyCheckedException.class) && +remapCnt.decrementAndGet() > 0) { + +CachePartialUpdateCheckedException cause = X.cause(err, CachePartialUpdateCheckedException.class); + +remap(cause.failedKeys()); return false; }
[3/3] incubator-ignite git commit: Merge branch 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-973
Merge branch 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-973 Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/de27ff1b Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/de27ff1b Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/de27ff1b Branch: refs/heads/ignite-973 Commit: de27ff1b8788b622937b17bfeaf8941242914d1a Parents: bcfbb92 415264e Author: S.Vladykin Authored: Mon Jun 22 09:21:46 2015 +0300 Committer: S.Vladykin Committed: Mon Jun 22 09:21:46 2015 +0300 -- .../internal/managers/GridManagerAdapter.java | 8 +- .../discovery/GridDiscoveryManager.java | 30 ++- .../GridCachePartitionExchangeManager.java | 1 + .../continuous/CacheContinuousQueryHandler.java | 8 + .../ignite/internal/util/nio/GridNioServer.java | 64 ++- .../org/apache/ignite/spi/IgniteSpiAdapter.java | 7 +- .../org/apache/ignite/spi/IgniteSpiContext.java | 9 +- .../communication/tcp/TcpCommunicationSpi.java | 71 +++ .../tcp/TcpCommunicationSpiMBean.java | 11 ++ .../ignite/spi/discovery/DiscoverySpi.java | 3 +- .../ignite/spi/discovery/tcp/ClientImpl.java| 12 +- .../ignite/spi/discovery/tcp/ServerImpl.java| 17 +- .../spi/discovery/tcp/TcpDiscoveryImpl.java | 3 +- .../spi/discovery/tcp/TcpDiscoverySpi.java | 6 +- .../messages/TcpDiscoveryNodeFailedMessage.java | 18 ++ ...ridFailFastNodeFailureDetectionSelfTest.java | 17 +- .../IgniteSlowClientDetectionSelfTest.java | 187 +++ .../testframework/GridSpiTestContext.java | 7 +- .../ignite/testsuites/IgniteBasicTestSuite.java | 1 + .../cache/jta/GridCacheXAResource.java | 18 +- .../processors/cache/GridCacheJtaSelfTest.java | 2 +- 21 files changed, 467 insertions(+), 33 deletions(-) --
[1/3] incubator-ignite git commit: ignite-973 - swap manager fix + offheap processor signatures fix
Repository: incubator-ignite Updated Branches: refs/heads/ignite-973 [created] de27ff1b8 ignite-973 - swap manager fix + offheap processor signatures 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/23512df8 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/23512df8 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/23512df8 Branch: refs/heads/ignite-973 Commit: 23512df815c196f9a2292ad948b130380f123770 Parents: b23ea74 Author: S.Vladykin Authored: Fri Jun 19 13:31:27 2015 +0300 Committer: S.Vladykin Committed: Fri Jun 19 13:31:27 2015 +0300 -- .../processors/cache/GridCacheSwapManager.java | 12 +- .../offheap/GridOffHeapProcessor.java | 19 +- .../apache/ignite/internal/util/GridDebug.java | 37 ++-- .../cache/IgniteCacheOffheapEvictQueryTest.java | 179 +++ .../IgniteCacheQuerySelfTestSuite.java | 1 + 5 files changed, 220 insertions(+), 28 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/23512df8/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheSwapManager.java -- diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheSwapManager.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheSwapManager.java index d0d9049..f709e03 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheSwapManager.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheSwapManager.java @@ -977,15 +977,15 @@ public class GridCacheSwapManager extends GridCacheManagerAdapter { // First try offheap. if (offheapEnabled) { -byte[] val = offheap.remove(spaceName, part, key.value(cctx.cacheObjectContext(), false), -key.valueBytes(cctx.cacheObjectContext())); - -if(val != null && cctx.config().isStatisticsEnabled()) -cctx.cache().metrics0().onOffHeapRemove(); +// TODO Pass closure c to offheap.remove and apply it before the actual remove. +byte[] val = offheap.remove(spaceName, part, key, key.valueBytes(cctx.cacheObjectContext())); if (val != null) { +if (cctx.config().isStatisticsEnabled()) +cctx.cache().metrics0().onOffHeapRemove(); + if (c != null) -c.apply(val); // Probably we should read value and apply closure before removing... +c.apply(val); return; } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/23512df8/modules/core/src/main/java/org/apache/ignite/internal/processors/offheap/GridOffHeapProcessor.java -- diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/offheap/GridOffHeapProcessor.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/offheap/GridOffHeapProcessor.java index a99c4c0..81bf9f2 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/offheap/GridOffHeapProcessor.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/offheap/GridOffHeapProcessor.java @@ -20,6 +20,7 @@ package org.apache.ignite.internal.processors.offheap; import org.apache.ignite.*; import org.apache.ignite.internal.*; import org.apache.ignite.internal.processors.*; +import org.apache.ignite.internal.processors.cache.*; import org.apache.ignite.internal.util.*; import org.apache.ignite.internal.util.lang.*; import org.apache.ignite.internal.util.offheap.*; @@ -101,7 +102,7 @@ public class GridOffHeapProcessor extends GridProcessorAdapter { * @return Key bytes * @throws IgniteCheckedException If failed. */ -private byte[] keyBytes(Object key, @Nullable byte[] keyBytes) throws IgniteCheckedException { +private byte[] keyBytes(KeyCacheObject key, @Nullable byte[] keyBytes) throws IgniteCheckedException { assert key != null; return keyBytes != null ? keyBytes : marsh.marshal(key); @@ -130,7 +131,7 @@ public class GridOffHeapProcessor extends GridProcessorAdapter { * @return {@code true} If offheap space contains value for the given key. * @throws IgniteCheckedException If failed. */ -public boolean contains(@Nullable String spaceName, int part, Object key, byte[] keyBytes) +public boolean contains(@Nullable String spaceName, int part, KeyCacheObject key, byte[] keyBytes) throws IgniteCheckedException { GridOffHeapPartitionedMap m = offheap(spaceName); @@
[2/3] incubator-ignite git commit: Merge branch 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-973
Merge branch 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-973 Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/bcfbb923 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/bcfbb923 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/bcfbb923 Branch: refs/heads/ignite-973 Commit: bcfbb9236e860115dfc70da9f717aaba7cb9544c Parents: 23512df d699faa Author: S.Vladykin Authored: Fri Jun 19 13:31:39 2015 +0300 Committer: S.Vladykin Committed: Fri Jun 19 13:31:39 2015 +0300 -- examples/pom.xml| 2 +- modules/aop/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 +- .../communication/tcp/TcpCommunicationSpi.java | 42 +-- .../ignite/spi/discovery/tcp/ServerImpl.java| 35 .../spi/discovery/tcp/TcpDiscoverySpi.java | 42 +-- .../tcp/internal/TcpDiscoveryNode.java | 18 .../core/src/main/resources/ignite.properties | 2 +- .../apache/ignite/internal/GridSelfTest.java| 20 + .../DataStreamerMultiThreadedSelfTest.java | 3 ++ .../spi/discovery/tcp/TcpDiscoverySelfTest.java | 44 ++-- modules/extdata/p2p/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/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 +- pom.xml | 2 +- 44 files changed, 189 insertions(+), 89 deletions(-) --
incubator-ignite git commit: # ignite-sprint-6 do not call ping from exchange worker (cherry picked from commit 8fa9d3d)
Repository: incubator-ignite Updated Branches: refs/heads/ignite-sprint-6 415264e3e -> 309eeb012 # ignite-sprint-6 do not call ping from exchange worker (cherry picked from commit 8fa9d3d) Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/309eeb01 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/309eeb01 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/309eeb01 Branch: refs/heads/ignite-sprint-6 Commit: 309eeb0127546c2775f8514e1759497fccf1c8b4 Parents: 415264e Author: sboikov Authored: Fri Jun 19 15:37:37 2015 +0300 Committer: sboikov Committed: Mon Jun 22 09:24:54 2015 +0300 -- .../processors/cache/GridCacheIoManager.java| 64 -- .../GridCachePartitionExchangeManager.java | 70 +--- .../GridCacheAbstractFailoverSelfTest.java | 6 +- 3 files changed, 79 insertions(+), 61 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/309eeb01/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 eef9fde..74a4512 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 @@ -323,7 +323,7 @@ public class GridCacheIoManager extends GridCacheSharedManagerAdapter { * Processes failed messages. * @param nodeId niode id. * @param msg message. - * @throws IgniteCheckedException + * @throws IgniteCheckedException If failed. */ private void processFailedMessage(UUID nodeId, GridCacheMessage msg) throws IgniteCheckedException { GridCacheContext ctx = cctx.cacheContext(msg.cacheId()); @@ -511,6 +511,7 @@ public class GridCacheIoManager extends GridCacheSharedManagerAdapter { * @param cacheMsg Cache message to get start future. * @return Preloader start future. */ +@SuppressWarnings("unchecked") private IgniteInternalFuture startFuture(GridCacheMessage cacheMsg) { int cacheId = cacheMsg.cacheId(); @@ -574,6 +575,7 @@ public class GridCacheIoManager extends GridCacheSharedManagerAdapter { * * @param node Node to send the message to. * @param msg Message to send. + * @param plc IO policy. * @throws IgniteCheckedException If sending failed. * @throws ClusterTopologyCheckedException If receiver left. */ @@ -734,6 +736,7 @@ public class GridCacheIoManager extends GridCacheSharedManagerAdapter { * * @param nodeId ID of node to send the message to. * @param msg Message to send. + * @param plc IO policy. * @throws IgniteCheckedException If sending failed. */ public void send(UUID nodeId, GridCacheMessage msg, GridIoPolicy plc) throws IgniteCheckedException { @@ -795,8 +798,41 @@ public class GridCacheIoManager extends GridCacheSharedManagerAdapter { } /** + * Sends message without retries and node ping in case of error. + * + * @param node Node to send message to. + * @param msg Message. + * @param plc IO policy. + * @throws IgniteCheckedException If send failed. + */ +public void sendNoRetry(ClusterNode node, +GridCacheMessage msg, +GridIoPolicy plc) +throws IgniteCheckedException +{ +assert node != null; +assert msg != null; + +onSend(msg, null); + +try { +cctx.gridIO().send(node, TOPIC_CACHE, msg, plc); + +if (log.isDebugEnabled()) +log.debug("Sent cache message [msg=" + msg + ", node=" + U.toShortString(node) + ']'); +} +catch (IgniteCheckedException e) { +if (!cctx.discovery().alive(node.id())) +throw new ClusterTopologyCheckedException("Node left grid while sending message to: " + node.id(), e); +else +throw e; +} +} + +/** * Adds message handler. * + * @param cacheId Cache ID. * @param type Type of message. * @param c Handler. */ @@ -846,29 +882,15 @@ public class GridCacheIoManager extends GridCacheSharedManagerAdapter { idxClsHandlers.remove(cacheId); -for (Iterator iterator = clsHandlers.keySet().iterator(); iterator.hasNext(); ) { -ListenerKey key = iterator.next(); +for (Iterator iter = clsHandlers.keySet().iterator(); iter.hasNext(); ) { +
incubator-ignite git commit: #ignite-973 - fix for IGNITE-1041
Repository: incubator-ignite Updated Branches: refs/heads/ignite-973 de27ff1b8 -> ced62b870 #ignite-973 - fix for IGNITE-1041 Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/ced62b87 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/ced62b87 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/ced62b87 Branch: refs/heads/ignite-973 Commit: ced62b8708952abfabc4926cfbb28c424d1ce651 Parents: de27ff1 Author: S.Vladykin Authored: Mon Jun 22 09:35:43 2015 +0300 Committer: S.Vladykin Committed: Mon Jun 22 09:35:43 2015 +0300 -- .../processors/query/h2/IgniteH2Indexing.java | 2 ++ .../query/h2/twostep/GridMapQueryExecutor.java | 23 ++-- 2 files changed, 13 insertions(+), 12 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/ced62b87/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/IgniteH2Indexing.java -- diff --git a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/IgniteH2Indexing.java b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/IgniteH2Indexing.java index c162ae6..06c0961 100644 --- a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/IgniteH2Indexing.java +++ b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/IgniteH2Indexing.java @@ -1354,6 +1354,8 @@ public class IgniteH2Indexing implements GridQueryIndexing { Schema rmv = schemas.remove(schema); if (rmv != null) { +mapQryExec.onCacheStop(ccfg.getName()); + try { dropSchema(schema); } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/ced62b87/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java -- diff --git a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java index ba95d43..0f38353 100644 --- a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java +++ b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java @@ -124,18 +124,6 @@ public class GridMapQueryExecutor { } }, EventType.EVT_NODE_FAILED, EventType.EVT_NODE_LEFT); -// Drop group reservations for dead caches. -ctx.event().addLocalEventListener(new GridLocalEventListener() { -@Override public void onEvent(Event evt) { -String cacheName = ((CacheEvent)evt).cacheName(); - -for (T2 grpKey : reservations.keySet()) { -if (F.eq(grpKey.get1(), cacheName)) -reservations.remove(grpKey); -} -} -}, EventType.EVT_CACHE_STOPPED); - ctx.io().addMessageListener(GridTopic.TOPIC_QUERY, new GridMessageListener() { @Override public void onMessage(UUID nodeId, Object msg) { if (!busyLock.enterBusy()) @@ -599,6 +587,17 @@ public class GridMapQueryExecutor { } /** + * @param cacheName Cache name. + */ +public void onCacheStop(String cacheName) { +// Drop group reservations. +for (T2 grpKey : reservations.keySet()) { +if (F.eq(grpKey.get1(), cacheName)) +reservations.remove(grpKey); +} +} + +/** * */ private class QueryResults {
incubator-ignite git commit: # IGNITE-843 Create Summary page.
Repository: incubator-ignite Updated Branches: refs/heads/ignite-843 7e5141ebe -> 359ee91ee # IGNITE-843 Create Summary page. Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/359ee91e Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/359ee91e Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/359ee91e Branch: refs/heads/ignite-843 Commit: 359ee91ee1e117e843f2475e4f6749cfd060f645 Parents: 7e5141e Author: sevdokimov Authored: Mon Jun 22 09:45:55 2015 +0300 Committer: sevdokimov Committed: Mon Jun 22 09:45:55 2015 +0300 -- .../public/javascripts/controllers/summary.js | 33 modules/webconfig/nodejs/views/summary.jade | 26 --- 2 files changed, 55 insertions(+), 4 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/359ee91e/modules/webconfig/nodejs/public/javascripts/controllers/summary.js -- diff --git a/modules/webconfig/nodejs/public/javascripts/controllers/summary.js b/modules/webconfig/nodejs/public/javascripts/controllers/summary.js new file mode 100644 index 000..09c9bd3 --- /dev/null +++ b/modules/webconfig/nodejs/public/javascripts/controllers/summary.js @@ -0,0 +1,33 @@ +/* + * 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. + */ + +configuratorModule.controller('clustersList', ['$scope', '$http', function ($scope, $http) { +$http.get('/rest/clusters') +.success(function(data) { +$scope.caches = data.caches; +$scope.spaces = data.spaces; +$scope.clusters = data.clusters; +}); +}]); + +configuratorModule.service('configGenerator', function(){ +return { +generateXml: function(cluster) { + +} +} +}); \ No newline at end of file http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/359ee91e/modules/webconfig/nodejs/views/summary.jade -- diff --git a/modules/webconfig/nodejs/views/summary.jade b/modules/webconfig/nodejs/views/summary.jade index 07e70cd..f926fa4 100644 --- a/modules/webconfig/nodejs/views/summary.jade +++ b/modules/webconfig/nodejs/views/summary.jade @@ -15,12 +15,30 @@ limitations under the License. extends layout-sidebar -block head + +append scripts +script(src='/javascripts/controllers/summary.js') + block content .docs-header h1 Summary p Configurations summary. hr -.docs-body(ng-controller='summaryRouter') -block body -script(src='/javascripts/controllers/summary.js') \ No newline at end of file +.docs-body(ng-controller='clustersList') +div(ng-hide='clusters.length > 0') +| No cluster configured. You can +a(href='clusters') configure +| it. + +div(ng-hide='clusters.length == 0') +p Following cluster configurations are created, you can download its as xml, java code or as docker file + +div(ng-repeat='row in clusters', style='padding-left: 20px') {{row.name}} +span.clusterName {{row.name}} +| +a(href='#') .xml +| +a(href='#') java code +| +a(href='#') docker +
incubator-ignite git commit: #ignite-973 - minor
Repository: incubator-ignite Updated Branches: refs/heads/ignite-973 ced62b870 -> 774bc94ff #ignite-973 - minor Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/774bc94f Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/774bc94f Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/774bc94f Branch: refs/heads/ignite-973 Commit: 774bc94ff7491735cf966f6f7a9b2a1887071dcf Parents: ced62b8 Author: S.Vladykin Authored: Mon Jun 22 09:46:08 2015 +0300 Committer: S.Vladykin Committed: Mon Jun 22 09:46:08 2015 +0300 -- .../processors/cache/IgniteCacheOffheapEvictQueryTest.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/774bc94f/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheOffheapEvictQueryTest.java -- diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheOffheapEvictQueryTest.java b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheOffheapEvictQueryTest.java index fc6c125..72bfcaa 100644 --- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheOffheapEvictQueryTest.java +++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheOffheapEvictQueryTest.java @@ -69,7 +69,7 @@ public class IgniteCacheOffheapEvictQueryTest extends GridCommonAbstractTest { */ public void testEvictAndRemove() throws Exception { final int KEYS_CNT = 3000; -final int THREADS_CNT = 256; +final int THREADS_CNT = 50; final IgniteCache c = startGrid().cache(null);
[5/6] incubator-ignite git commit: #ignite-973 - minor
#ignite-973 - minor Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/774bc94f Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/774bc94f Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/774bc94f Branch: refs/heads/ignite-sprint-6 Commit: 774bc94ff7491735cf966f6f7a9b2a1887071dcf Parents: ced62b8 Author: S.Vladykin Authored: Mon Jun 22 09:46:08 2015 +0300 Committer: S.Vladykin Committed: Mon Jun 22 09:46:08 2015 +0300 -- .../processors/cache/IgniteCacheOffheapEvictQueryTest.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/774bc94f/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheOffheapEvictQueryTest.java -- diff --git a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheOffheapEvictQueryTest.java b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheOffheapEvictQueryTest.java index fc6c125..72bfcaa 100644 --- a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheOffheapEvictQueryTest.java +++ b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheOffheapEvictQueryTest.java @@ -69,7 +69,7 @@ public class IgniteCacheOffheapEvictQueryTest extends GridCommonAbstractTest { */ public void testEvictAndRemove() throws Exception { final int KEYS_CNT = 3000; -final int THREADS_CNT = 256; +final int THREADS_CNT = 50; final IgniteCache c = startGrid().cache(null);
[6/6] incubator-ignite git commit: Merge branches 'ignite-973' and 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-sprint-6
Merge branches 'ignite-973' and 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-sprint-6 Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/1cc0 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/1cc0 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/1cc0 Branch: refs/heads/ignite-sprint-6 Commit: 1cc0a641f3d52964710377a8c29d9ff59947 Parents: 309eeb0 774bc94 Author: S.Vladykin Authored: Mon Jun 22 09:47:29 2015 +0300 Committer: S.Vladykin Committed: Mon Jun 22 09:47:29 2015 +0300 -- .../processors/cache/GridCacheSwapManager.java | 12 +- .../offheap/GridOffHeapProcessor.java | 19 +- .../apache/ignite/internal/util/GridDebug.java | 37 ++-- .../processors/query/h2/IgniteH2Indexing.java | 2 + .../query/h2/twostep/GridMapQueryExecutor.java | 23 ++- .../cache/IgniteCacheOffheapEvictQueryTest.java | 179 +++ .../IgniteCacheQuerySelfTestSuite.java | 1 + 7 files changed, 233 insertions(+), 40 deletions(-) --
[1/6] incubator-ignite git commit: ignite-973 - swap manager fix + offheap processor signatures fix
Repository: incubator-ignite Updated Branches: refs/heads/ignite-sprint-6 309eeb012 -> 1cc0a ignite-973 - swap manager fix + offheap processor signatures 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/23512df8 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/23512df8 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/23512df8 Branch: refs/heads/ignite-sprint-6 Commit: 23512df815c196f9a2292ad948b130380f123770 Parents: b23ea74 Author: S.Vladykin Authored: Fri Jun 19 13:31:27 2015 +0300 Committer: S.Vladykin Committed: Fri Jun 19 13:31:27 2015 +0300 -- .../processors/cache/GridCacheSwapManager.java | 12 +- .../offheap/GridOffHeapProcessor.java | 19 +- .../apache/ignite/internal/util/GridDebug.java | 37 ++-- .../cache/IgniteCacheOffheapEvictQueryTest.java | 179 +++ .../IgniteCacheQuerySelfTestSuite.java | 1 + 5 files changed, 220 insertions(+), 28 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/23512df8/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheSwapManager.java -- diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheSwapManager.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheSwapManager.java index d0d9049..f709e03 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheSwapManager.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheSwapManager.java @@ -977,15 +977,15 @@ public class GridCacheSwapManager extends GridCacheManagerAdapter { // First try offheap. if (offheapEnabled) { -byte[] val = offheap.remove(spaceName, part, key.value(cctx.cacheObjectContext(), false), -key.valueBytes(cctx.cacheObjectContext())); - -if(val != null && cctx.config().isStatisticsEnabled()) -cctx.cache().metrics0().onOffHeapRemove(); +// TODO Pass closure c to offheap.remove and apply it before the actual remove. +byte[] val = offheap.remove(spaceName, part, key, key.valueBytes(cctx.cacheObjectContext())); if (val != null) { +if (cctx.config().isStatisticsEnabled()) +cctx.cache().metrics0().onOffHeapRemove(); + if (c != null) -c.apply(val); // Probably we should read value and apply closure before removing... +c.apply(val); return; } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/23512df8/modules/core/src/main/java/org/apache/ignite/internal/processors/offheap/GridOffHeapProcessor.java -- diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/offheap/GridOffHeapProcessor.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/offheap/GridOffHeapProcessor.java index a99c4c0..81bf9f2 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/offheap/GridOffHeapProcessor.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/offheap/GridOffHeapProcessor.java @@ -20,6 +20,7 @@ package org.apache.ignite.internal.processors.offheap; import org.apache.ignite.*; import org.apache.ignite.internal.*; import org.apache.ignite.internal.processors.*; +import org.apache.ignite.internal.processors.cache.*; import org.apache.ignite.internal.util.*; import org.apache.ignite.internal.util.lang.*; import org.apache.ignite.internal.util.offheap.*; @@ -101,7 +102,7 @@ public class GridOffHeapProcessor extends GridProcessorAdapter { * @return Key bytes * @throws IgniteCheckedException If failed. */ -private byte[] keyBytes(Object key, @Nullable byte[] keyBytes) throws IgniteCheckedException { +private byte[] keyBytes(KeyCacheObject key, @Nullable byte[] keyBytes) throws IgniteCheckedException { assert key != null; return keyBytes != null ? keyBytes : marsh.marshal(key); @@ -130,7 +131,7 @@ public class GridOffHeapProcessor extends GridProcessorAdapter { * @return {@code true} If offheap space contains value for the given key. * @throws IgniteCheckedException If failed. */ -public boolean contains(@Nullable String spaceName, int part, Object key, byte[] keyBytes) +public boolean contains(@Nullable String spaceName, int part, KeyCacheObject key, byte[] keyBytes) throws IgniteCheckedException { GridOffHeapPartitionedMap m = offheap(spac
[2/6] incubator-ignite git commit: Merge branch 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-973
Merge branch 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-973 Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/bcfbb923 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/bcfbb923 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/bcfbb923 Branch: refs/heads/ignite-sprint-6 Commit: bcfbb9236e860115dfc70da9f717aaba7cb9544c Parents: 23512df d699faa Author: S.Vladykin Authored: Fri Jun 19 13:31:39 2015 +0300 Committer: S.Vladykin Committed: Fri Jun 19 13:31:39 2015 +0300 -- examples/pom.xml| 2 +- modules/aop/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 +- .../communication/tcp/TcpCommunicationSpi.java | 42 +-- .../ignite/spi/discovery/tcp/ServerImpl.java| 35 .../spi/discovery/tcp/TcpDiscoverySpi.java | 42 +-- .../tcp/internal/TcpDiscoveryNode.java | 18 .../core/src/main/resources/ignite.properties | 2 +- .../apache/ignite/internal/GridSelfTest.java| 20 + .../DataStreamerMultiThreadedSelfTest.java | 3 ++ .../spi/discovery/tcp/TcpDiscoverySelfTest.java | 44 ++-- modules/extdata/p2p/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/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 +- pom.xml | 2 +- 44 files changed, 189 insertions(+), 89 deletions(-) --
[4/6] incubator-ignite git commit: #ignite-973 - fix for IGNITE-1041
#ignite-973 - fix for IGNITE-1041 Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/ced62b87 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/ced62b87 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/ced62b87 Branch: refs/heads/ignite-sprint-6 Commit: ced62b8708952abfabc4926cfbb28c424d1ce651 Parents: de27ff1 Author: S.Vladykin Authored: Mon Jun 22 09:35:43 2015 +0300 Committer: S.Vladykin Committed: Mon Jun 22 09:35:43 2015 +0300 -- .../processors/query/h2/IgniteH2Indexing.java | 2 ++ .../query/h2/twostep/GridMapQueryExecutor.java | 23 ++-- 2 files changed, 13 insertions(+), 12 deletions(-) -- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/ced62b87/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/IgniteH2Indexing.java -- diff --git a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/IgniteH2Indexing.java b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/IgniteH2Indexing.java index c162ae6..06c0961 100644 --- a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/IgniteH2Indexing.java +++ b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/IgniteH2Indexing.java @@ -1354,6 +1354,8 @@ public class IgniteH2Indexing implements GridQueryIndexing { Schema rmv = schemas.remove(schema); if (rmv != null) { +mapQryExec.onCacheStop(ccfg.getName()); + try { dropSchema(schema); } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/ced62b87/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java -- diff --git a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java index ba95d43..0f38353 100644 --- a/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java +++ b/modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/twostep/GridMapQueryExecutor.java @@ -124,18 +124,6 @@ public class GridMapQueryExecutor { } }, EventType.EVT_NODE_FAILED, EventType.EVT_NODE_LEFT); -// Drop group reservations for dead caches. -ctx.event().addLocalEventListener(new GridLocalEventListener() { -@Override public void onEvent(Event evt) { -String cacheName = ((CacheEvent)evt).cacheName(); - -for (T2 grpKey : reservations.keySet()) { -if (F.eq(grpKey.get1(), cacheName)) -reservations.remove(grpKey); -} -} -}, EventType.EVT_CACHE_STOPPED); - ctx.io().addMessageListener(GridTopic.TOPIC_QUERY, new GridMessageListener() { @Override public void onMessage(UUID nodeId, Object msg) { if (!busyLock.enterBusy()) @@ -599,6 +587,17 @@ public class GridMapQueryExecutor { } /** + * @param cacheName Cache name. + */ +public void onCacheStop(String cacheName) { +// Drop group reservations. +for (T2 grpKey : reservations.keySet()) { +if (F.eq(grpKey.get1(), cacheName)) +reservations.remove(grpKey); +} +} + +/** * */ private class QueryResults {
[3/6] incubator-ignite git commit: Merge branch 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-973
Merge branch 'ignite-sprint-6' of https://git-wip-us.apache.org/repos/asf/incubator-ignite into ignite-973 Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/de27ff1b Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/de27ff1b Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/de27ff1b Branch: refs/heads/ignite-sprint-6 Commit: de27ff1b8788b622937b17bfeaf8941242914d1a Parents: bcfbb92 415264e Author: S.Vladykin Authored: Mon Jun 22 09:21:46 2015 +0300 Committer: S.Vladykin Committed: Mon Jun 22 09:21:46 2015 +0300 -- .../internal/managers/GridManagerAdapter.java | 8 +- .../discovery/GridDiscoveryManager.java | 30 ++- .../GridCachePartitionExchangeManager.java | 1 + .../continuous/CacheContinuousQueryHandler.java | 8 + .../ignite/internal/util/nio/GridNioServer.java | 64 ++- .../org/apache/ignite/spi/IgniteSpiAdapter.java | 7 +- .../org/apache/ignite/spi/IgniteSpiContext.java | 9 +- .../communication/tcp/TcpCommunicationSpi.java | 71 +++ .../tcp/TcpCommunicationSpiMBean.java | 11 ++ .../ignite/spi/discovery/DiscoverySpi.java | 3 +- .../ignite/spi/discovery/tcp/ClientImpl.java| 12 +- .../ignite/spi/discovery/tcp/ServerImpl.java| 17 +- .../spi/discovery/tcp/TcpDiscoveryImpl.java | 3 +- .../spi/discovery/tcp/TcpDiscoverySpi.java | 6 +- .../messages/TcpDiscoveryNodeFailedMessage.java | 18 ++ ...ridFailFastNodeFailureDetectionSelfTest.java | 17 +- .../IgniteSlowClientDetectionSelfTest.java | 187 +++ .../testframework/GridSpiTestContext.java | 7 +- .../ignite/testsuites/IgniteBasicTestSuite.java | 1 + .../cache/jta/GridCacheXAResource.java | 18 +- .../processors/cache/GridCacheJtaSelfTest.java | 2 +- 21 files changed, 467 insertions(+), 33 deletions(-) --