http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheVariableTopologySelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheVariableTopologySelfTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheVariableTopologySelfTest.java index 55e27e7..33a145f 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheVariableTopologySelfTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheVariableTopologySelfTest.java @@ -9,13 +9,13 @@ package org.gridgain.grid.kernal.processors.cache; +import org.apache.ignite.*; import org.apache.ignite.configuration.*; import org.apache.ignite.lang.*; -import org.gridgain.grid.*; -import org.gridgain.grid.cache.*; 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.gridgain.grid.cache.*; import org.gridgain.grid.util.typedef.*; import org.gridgain.testframework.*; import org.gridgain.testframework.junits.common.*; @@ -112,7 +112,7 @@ public class GridCacheVariableTopologySelfTest extends GridCommonAbstractTest { private int cnt; @SuppressWarnings({"BusyWait"}) - @Override public void applyx() throws GridException { + @Override public void applyx() throws IgniteCheckedException { while (cnt++ < txCnt && !done.get()) { GridCache<Object, Object> cache = grid(0).cache(null);
http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheWriteBehindStoreAbstractSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheWriteBehindStoreAbstractSelfTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheWriteBehindStoreAbstractSelfTest.java index a93f511..3cc93bd 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheWriteBehindStoreAbstractSelfTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheWriteBehindStoreAbstractSelfTest.java @@ -8,8 +8,8 @@ */ package org.gridgain.grid.kernal.processors.cache; +import org.apache.ignite.*; import org.apache.ignite.lang.*; -import org.gridgain.grid.*; import org.gridgain.grid.util.typedef.internal.*; import org.gridgain.testframework.junits.common.*; @@ -154,7 +154,7 @@ public abstract class GridCacheWriteBehindStoreAbstractSelfTest extends GridComm } } } - catch (GridException e) { + catch (IgniteCheckedException e) { error("Unexpected exception in put thread", e); assert false; http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheWriteBehindStoreAbstractTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheWriteBehindStoreAbstractTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheWriteBehindStoreAbstractTest.java index 0e76744..0c91822 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheWriteBehindStoreAbstractTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheWriteBehindStoreAbstractTest.java @@ -9,12 +9,12 @@ package org.gridgain.grid.kernal.processors.cache; +import org.apache.ignite.*; import org.apache.ignite.configuration.*; import org.apache.ignite.lang.*; -import org.gridgain.grid.*; -import org.gridgain.grid.cache.*; import org.apache.ignite.spi.discovery.tcp.*; import org.apache.ignite.spi.discovery.tcp.ipfinder.vm.*; +import org.gridgain.grid.cache.*; import org.gridgain.grid.util.typedef.internal.*; import org.gridgain.testframework.junits.common.*; import org.jetbrains.annotations.*; @@ -292,7 +292,7 @@ public abstract class GridCacheWriteBehindStoreAbstractTest extends GridCommonAb } } } - catch (GridException e) { + catch (IgniteCheckedException e) { error("Unexpected exception in put thread", e); assert false; http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheWriteBehindStoreSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheWriteBehindStoreSelfTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheWriteBehindStoreSelfTest.java index b974a3e..0e84d80 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheWriteBehindStoreSelfTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheWriteBehindStoreSelfTest.java @@ -8,8 +8,8 @@ */ package org.gridgain.grid.kernal.processors.cache; +import org.apache.ignite.*; import org.apache.ignite.lang.*; -import org.gridgain.grid.*; import org.gridgain.grid.cache.*; import org.gridgain.grid.util.typedef.*; import org.gridgain.grid.util.typedef.internal.*; @@ -154,7 +154,7 @@ public class GridCacheWriteBehindStoreSelfTest extends GridCacheWriteBehindStore } } } - catch (GridException e) { + catch (IgniteCheckedException e) { error("Unexpected exception in put thread", e); assert false; @@ -210,7 +210,7 @@ public class GridCacheWriteBehindStoreSelfTest extends GridCacheWriteBehindStore } } } - catch (GridException e) { + catch (IgniteCheckedException e) { error("Unexpected exception in put thread", e); assert false; http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheAtomicLongApiSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheAtomicLongApiSelfTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheAtomicLongApiSelfTest.java index b3959a2..d410045 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheAtomicLongApiSelfTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheAtomicLongApiSelfTest.java @@ -9,20 +9,20 @@ package org.gridgain.grid.kernal.processors.cache.datastructures; +import org.apache.ignite.*; import org.apache.ignite.configuration.*; -import org.gridgain.grid.*; -import org.gridgain.grid.cache.*; -import org.gridgain.grid.cache.datastructures.*; 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.gridgain.grid.cache.*; +import org.gridgain.grid.cache.datastructures.*; import org.gridgain.testframework.junits.common.*; import java.util.*; import static org.gridgain.grid.cache.GridCacheAtomicityMode.*; -import static org.gridgain.grid.cache.GridCacheMode.*; import static org.gridgain.grid.cache.GridCacheDistributionMode.*; +import static org.gridgain.grid.cache.GridCacheMode.*; import static org.gridgain.grid.cache.GridCachePreloadMode.*; import static org.gridgain.grid.cache.GridCacheWriteSynchronizationMode.*; @@ -151,7 +151,7 @@ public class GridCacheAtomicLongApiSelfTest extends GridCommonAbstractTest { fail(); } - catch (GridException e) { + catch (IgniteCheckedException e) { info("Caught expected exception: " + e.getMessage()); } } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheAtomicReferenceApiSelfAbstractTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheAtomicReferenceApiSelfAbstractTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheAtomicReferenceApiSelfAbstractTest.java index b601fe0..a0c3da4 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheAtomicReferenceApiSelfAbstractTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheAtomicReferenceApiSelfAbstractTest.java @@ -9,14 +9,14 @@ package org.gridgain.grid.kernal.processors.cache.datastructures; +import org.apache.ignite.*; import org.apache.ignite.configuration.*; -import org.gridgain.grid.*; -import org.gridgain.grid.cache.*; -import org.gridgain.grid.cache.datastructures.*; -import org.gridgain.grid.cache.store.*; 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.gridgain.grid.cache.*; +import org.gridgain.grid.cache.datastructures.*; +import org.gridgain.grid.cache.store.*; import org.gridgain.testframework.junits.common.*; import org.mockito.*; @@ -106,7 +106,7 @@ public abstract class GridCacheAtomicReferenceApiSelfAbstractTest extends GridCo atomic1.get(); fail(); } - catch (GridException e) { + catch (IgniteCheckedException e) { info("Caught expected exception: " + e.getMessage()); } } @@ -159,9 +159,9 @@ public abstract class GridCacheAtomicReferenceApiSelfAbstractTest extends GridCo * Tests that non-persistent atomic reference doesn't ever * hit the store. * - * @throws GridException If failed. + * @throws IgniteCheckedException If failed. */ - public void testNonPersistentMode() throws GridException { + public void testNonPersistentMode() throws IgniteCheckedException { String atomicName = UUID.randomUUID().toString(); GridCache<Object, Object> cache = grid().cache(null); http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheAtomicReferenceMultiNodeAbstractTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheAtomicReferenceMultiNodeAbstractTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheAtomicReferenceMultiNodeAbstractTest.java index d85f880..1f74249 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheAtomicReferenceMultiNodeAbstractTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheAtomicReferenceMultiNodeAbstractTest.java @@ -89,7 +89,7 @@ public abstract class GridCacheAtomicReferenceMultiNodeAbstractTest extends Grid // Execute task on all grid nodes. ignite.compute().call(new IgniteCallable<Object>() { - @Override public String call() throws GridException { + @Override public String call() throws IgniteCheckedException { GridCacheAtomicReference<String> ref = ignite.cache(null).dataStructures().atomicReference(refName, val, true); assertEquals(val, ref.get()); @@ -102,7 +102,7 @@ public abstract class GridCacheAtomicReferenceMultiNodeAbstractTest extends Grid // Execute task on all grid nodes. ignite.compute().call(new IgniteCallable<String>() { - @Override public String call() throws GridException { + @Override public String call() throws IgniteCheckedException { GridCacheAtomicReference<String> ref = ignite.cache(null).dataStructures().atomicReference(refName, val, true); assertEquals(val, ref.get()); @@ -115,7 +115,7 @@ public abstract class GridCacheAtomicReferenceMultiNodeAbstractTest extends Grid // Execute task on all grid nodes. ignite.compute().call(new IgniteCallable<String>() { - @Override public String call() throws GridException { + @Override public String call() throws IgniteCheckedException { GridCacheAtomicReference<String> ref = ignite.cache(null).dataStructures().atomicReference(refName, val, true); assertEquals(newVal, ref.get()); @@ -150,7 +150,7 @@ public abstract class GridCacheAtomicReferenceMultiNodeAbstractTest extends Grid // Execute task on all grid nodes. ignite.compute().call(new IgniteCallable<String>() { - @Override public String call() throws GridException { + @Override public String call() throws IgniteCheckedException { GridCacheAtomicStamped<String, String> stamped = ignite.cache(null).dataStructures() .atomicStamped(stampedName, val, stamp, true); @@ -165,7 +165,7 @@ public abstract class GridCacheAtomicReferenceMultiNodeAbstractTest extends Grid // Execute task on all grid nodes. ignite.compute().call(new IgniteCallable<String>() { - @Override public String call() throws GridException { + @Override public String call() throws IgniteCheckedException { GridCacheAtomicStamped<String, String> stamped = ignite.cache(null).dataStructures() .atomicStamped(stampedName, val, stamp, true); @@ -180,7 +180,7 @@ public abstract class GridCacheAtomicReferenceMultiNodeAbstractTest extends Grid // Execute task on all grid nodes. ignite.compute().call(new IgniteCallable<String>() { - @Override public String call() throws GridException { + @Override public String call() throws IgniteCheckedException { GridCacheAtomicStamped<String, String> stamped = ignite.cache(null).dataStructures() .atomicStamped(stampedName, val, stamp, true); http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheAtomicStampedApiSelfAbstractTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheAtomicStampedApiSelfAbstractTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheAtomicStampedApiSelfAbstractTest.java index 07048a8..dbcd612 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheAtomicStampedApiSelfAbstractTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheAtomicStampedApiSelfAbstractTest.java @@ -9,12 +9,12 @@ package org.gridgain.grid.kernal.processors.cache.datastructures; +import org.apache.ignite.*; import org.apache.ignite.configuration.*; -import org.gridgain.grid.*; -import org.gridgain.grid.cache.datastructures.*; 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.gridgain.grid.cache.datastructures.*; import org.gridgain.testframework.junits.common.*; import java.util.*; @@ -83,7 +83,7 @@ public abstract class GridCacheAtomicStampedApiSelfAbstractTest extends GridComm atomic1.get(); fail(); } - catch (GridException e) { + catch (IgniteCheckedException e) { info("Caught expected exception: " + e.getMessage()); } } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheMultiNodeDataStructureTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheMultiNodeDataStructureTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheMultiNodeDataStructureTest.java index 0d0390c..b7b5144 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheMultiNodeDataStructureTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheMultiNodeDataStructureTest.java @@ -29,13 +29,13 @@ public class GridCacheMultiNodeDataStructureTest { * Put data to cache and then queries them. * * @param args Command line arguments, none required. - * @throws GridException If example execution failed. + * @throws IgniteCheckedException If example execution failed. */ - public static void main(String[] args) throws GridException { + public static void main(String[] args) throws IgniteCheckedException { try (Ignite g = G.start("examples/config/example-cache.xml")) { // All available nodes. if (g.cluster().nodes().size() <= 2) - throw new GridException("At least 2 nodes must be started."); + throw new IgniteCheckedException("At least 2 nodes must be started."); sample(g, "partitioned"); sample(g, "replicated"); @@ -47,9 +47,9 @@ public class GridCacheMultiNodeDataStructureTest { * * @param g Grid. * @param cacheName Cache name. - * @throws GridException If failed. + * @throws IgniteCheckedException If failed. */ - private static void sample(Ignite g, String cacheName) throws GridException { + private static void sample(Ignite g, String cacheName) throws IgniteCheckedException { GridCache<Long, Object> cache = g.cache(cacheName); GridCacheAtomicLong atomicLong = cache.dataStructures().atomicLong("keygen", 0, true); http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheQueueApiSelfAbstractTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheQueueApiSelfAbstractTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheQueueApiSelfAbstractTest.java index d22277a..ab9a237 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheQueueApiSelfAbstractTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheQueueApiSelfAbstractTest.java @@ -9,12 +9,12 @@ package org.gridgain.grid.kernal.processors.cache.datastructures; +import org.apache.ignite.*; import org.apache.ignite.configuration.*; -import org.gridgain.grid.*; -import org.gridgain.grid.cache.datastructures.*; 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.gridgain.grid.cache.datastructures.*; import org.gridgain.grid.util.typedef.internal.*; import org.gridgain.testframework.junits.common.*; @@ -418,7 +418,7 @@ public abstract class GridCacheQueueApiSelfAbstractTest extends GridCommonAbstra fail("Queue failed"); } - catch (GridRuntimeException e) { + catch (IgniteException e) { putLatch.countDown(); assert e.getMessage().contains("removed"); @@ -445,7 +445,7 @@ public abstract class GridCacheQueueApiSelfAbstractTest extends GridCommonAbstra log.debug("Queue removed [queue " + queue + ']'); } } - catch (GridException e) { + catch (IgniteCheckedException e) { info("Caught expected exception: " + e.getMessage()); assert queue.removed(); @@ -468,7 +468,7 @@ public abstract class GridCacheQueueApiSelfAbstractTest extends GridCommonAbstra assert queue.isEmpty() : queue.size(); fail("Queue must be removed."); } - catch (GridRuntimeException e) { + catch (IgniteException e) { assert e.getMessage().contains("removed"); assert queue.removed(); @@ -507,7 +507,7 @@ public abstract class GridCacheQueueApiSelfAbstractTest extends GridCommonAbstra fail("Queue failed"); } } - catch (GridRuntimeException e) { + catch (IgniteException e) { takeLatch.countDown(); assert e.getMessage().contains("removed"); @@ -533,7 +533,7 @@ public abstract class GridCacheQueueApiSelfAbstractTest extends GridCommonAbstra log.debug("Queue has been removed." + queue); } } - catch (GridException e) { + catch (IgniteCheckedException e) { info("Caught expected exception: " + e.getMessage()); assert queue.removed(); @@ -557,7 +557,7 @@ public abstract class GridCacheQueueApiSelfAbstractTest extends GridCommonAbstra fail("Queue must be removed."); } - catch (GridRuntimeException e) { + catch (IgniteException e) { assert e.getMessage().contains("removed"); assert queue.removed(); http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheQueueJoinedNodeSelfAbstractTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheQueueJoinedNodeSelfAbstractTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheQueueJoinedNodeSelfAbstractTest.java index 2a1eb96..04b4f98 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheQueueJoinedNodeSelfAbstractTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheQueueJoinedNodeSelfAbstractTest.java @@ -272,13 +272,13 @@ public abstract class GridCacheQueueJoinedNodeSelfAbstractTest extends GridCommo takeLatch.countDown(); } } - catch (GridRuntimeException e) { + catch (IgniteException e) { if (e.getCause() instanceof GridInterruptedException || e.getCause() instanceof InterruptedException) log.info("Cancelling job due to interruption: " + e.getMessage()); else fail("Unexpected error: " + e); } - catch (GridException e) { + catch (IgniteCheckedException e) { error("Failed to get value from the queue", e); } finally { http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheQueueMultiNodeAbstractSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheQueueMultiNodeAbstractSelfTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheQueueMultiNodeAbstractSelfTest.java index 09e28c0..acca39c 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheQueueMultiNodeAbstractSelfTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheQueueMultiNodeAbstractSelfTest.java @@ -642,7 +642,7 @@ public abstract class GridCacheQueueMultiNodeAbstractSelfTest extends GridCommon } /** {@inheritDoc} */ - @Override public Integer call() throws GridException { + @Override public Integer call() throws IgniteCheckedException { assertNotNull(ignite); ignite.log().info("Running job [node=" + ignite.cluster().localNode().id() + ", job=" + this + "]"); @@ -689,7 +689,7 @@ public abstract class GridCacheQueueMultiNodeAbstractSelfTest extends GridCommon } /** {@inheritDoc} */ - @Override public Integer call() throws GridException { + @Override public Integer call() throws IgniteCheckedException { assertNotNull(ignite); ignite.log().info("Running job [node=" + ignite.cluster().localNode().id() + ", job=" + this + "]"); @@ -745,7 +745,7 @@ public abstract class GridCacheQueueMultiNodeAbstractSelfTest extends GridCommon } /** {@inheritDoc} */ - @Override public Integer call() throws GridException { + @Override public Integer call() throws IgniteCheckedException { assertNotNull(ignite); ignite.log().info("Running job [node=" + ignite.cluster().localNode().id() + ", job=" + this + "]"); @@ -797,7 +797,7 @@ public abstract class GridCacheQueueMultiNodeAbstractSelfTest extends GridCommon } /** {@inheritDoc} */ - @Override public Integer call() throws GridException { + @Override public Integer call() throws IgniteCheckedException { assertNotNull(ignite); ignite.log().info("Running job [node=" + ignite.cluster().localNode().id() + ", job=" + this + ']'); http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheQueueRotativeMultiNodeAbstractTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheQueueRotativeMultiNodeAbstractTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheQueueRotativeMultiNodeAbstractTest.java index 7723ee8..e2f51d6 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheQueueRotativeMultiNodeAbstractTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheQueueRotativeMultiNodeAbstractTest.java @@ -159,7 +159,7 @@ public abstract class GridCacheQueueRotativeMultiNodeAbstractTest extends GridCo try { assert grid(1).compute().call(new TakeJob(queueName)); } - catch (GridException e) { + catch (IgniteCheckedException e) { error(e.getMessage(), e); } } @@ -209,7 +209,7 @@ public abstract class GridCacheQueueRotativeMultiNodeAbstractTest extends GridCo } /** {@inheritDoc} */ - @Override public Integer call() throws GridException { + @Override public Integer call() throws IgniteCheckedException { assertNotNull(ignite); ignite.log().info("Running job [node=" + ignite.cluster().localNode().id() + ", job=" + this + "]"); @@ -261,7 +261,7 @@ public abstract class GridCacheQueueRotativeMultiNodeAbstractTest extends GridCo } /** {@inheritDoc} */ - @Override public Integer call() throws GridException { + @Override public Integer call() throws IgniteCheckedException { assertNotNull(ignite); ignite.log().info("Running job [node=" + ignite.cluster().localNode().id() + ", job=" + this + "]"); @@ -313,7 +313,7 @@ public abstract class GridCacheQueueRotativeMultiNodeAbstractTest extends GridCo } /** {@inheritDoc} */ - @Override public Integer call() throws GridException { + @Override public Integer call() throws IgniteCheckedException { assertNotNull(ignite); ignite.log().info("Running job [node=" + ignite.cluster().localNode().id() + ", job=" + this + ']'); @@ -361,7 +361,7 @@ public abstract class GridCacheQueueRotativeMultiNodeAbstractTest extends GridCo } /** {@inheritDoc} */ - @Override public Boolean call() throws GridException { + @Override public Boolean call() throws IgniteCheckedException { assertNotNull(ignite); ignite.log().info("Running job [node=" + ignite.cluster().localNode().id() + ", job=" + this + ']'); @@ -377,7 +377,7 @@ public abstract class GridCacheQueueRotativeMultiNodeAbstractTest extends GridCo queue.take(); } - catch (GridRuntimeException e) { + catch (IgniteException e) { ignite.log().info("Caught expected exception: " + e.getMessage()); } @@ -409,7 +409,7 @@ public abstract class GridCacheQueueRotativeMultiNodeAbstractTest extends GridCo } /** {@inheritDoc} */ - @Override public Boolean call() throws GridException { + @Override public Boolean call() throws IgniteCheckedException { assertNotNull(ignite); ignite.log().info("Running job [node=" + ignite.cluster().localNode().id() + ", job=" + this + "]"); http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheSequenceApiSelfAbstractTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheSequenceApiSelfAbstractTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheSequenceApiSelfAbstractTest.java index 9fcd24a..19b1b40 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheSequenceApiSelfAbstractTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheSequenceApiSelfAbstractTest.java @@ -9,14 +9,14 @@ package org.gridgain.grid.kernal.processors.cache.datastructures; +import org.apache.ignite.*; import org.apache.ignite.configuration.*; -import org.gridgain.grid.*; -import org.gridgain.grid.cache.*; -import org.gridgain.grid.cache.datastructures.*; -import org.gridgain.grid.kernal.processors.cache.*; 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.gridgain.grid.cache.*; +import org.gridgain.grid.cache.datastructures.*; +import org.gridgain.grid.kernal.processors.cache.*; import org.gridgain.grid.util.typedef.*; import org.gridgain.testframework.junits.common.*; import org.jetbrains.annotations.*; @@ -316,7 +316,7 @@ public abstract class GridCacheSequenceApiSelfAbstractTest extends GridCommonAbs fail("Exception expected."); } - catch (GridException e) { + catch (IgniteCheckedException e) { info("Caught expected exception: " + e); } } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheSequenceMultiNodeAbstractSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheSequenceMultiNodeAbstractSelfTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheSequenceMultiNodeAbstractSelfTest.java index c1d7a7f..9077edf 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheSequenceMultiNodeAbstractSelfTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheSequenceMultiNodeAbstractSelfTest.java @@ -148,7 +148,7 @@ public abstract class GridCacheSequenceMultiNodeAbstractSelfTest extends GridCom final GridCacheAtomicSequence seq = grid(0).cache(null).dataStructures().atomicSequence(seqName, 0, true); grid(1).compute().run(new CAX() { - @Override public void applyx() throws GridException { + @Override public void applyx() throws IgniteCheckedException { assertNotNull(seq); for (int i = 0; i < RETRIES; i++) @@ -195,7 +195,7 @@ public abstract class GridCacheSequenceMultiNodeAbstractSelfTest extends GridCom } /** {@inheritDoc} */ - @Override public Set<Long> call() throws GridException { + @Override public Set<Long> call() throws IgniteCheckedException { assert ignite != null; if (log.isInfoEnabled()) @@ -249,7 +249,7 @@ public abstract class GridCacheSequenceMultiNodeAbstractSelfTest extends GridCom } /** {@inheritDoc} */ - @Override public Set<Long> call() throws GridException { + @Override public Set<Long> call() throws IgniteCheckedException { assert ignite != null; if (log.isInfoEnabled()) http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheSetAbstractSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheSetAbstractSelfTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheSetAbstractSelfTest.java index c81efe8..9dcd07c 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheSetAbstractSelfTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheSetAbstractSelfTest.java @@ -10,9 +10,9 @@ package org.gridgain.grid.kernal.processors.cache.datastructures; import junit.framework.*; +import org.apache.ignite.*; import org.apache.ignite.configuration.*; import org.apache.ignite.lang.*; -import org.gridgain.grid.*; import org.gridgain.grid.cache.*; import org.gridgain.grid.cache.datastructures.*; import org.gridgain.grid.kernal.*; @@ -56,10 +56,10 @@ public abstract class GridCacheSetAbstractSelfTest extends GridCacheAbstractSelf /** * Waits when internal set maps are cleared. * - * @throws GridException If failed. + * @throws IgniteCheckedException If failed. */ @SuppressWarnings("ErrorNotRethrown") - private void waitSetResourcesCleared() throws GridException { + private void waitSetResourcesCleared() throws IgniteCheckedException { final int MAX_CHECK = 5; for (int i = 0; i < MAX_CHECK; i++) { http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheSetFailoverAbstractSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheSetFailoverAbstractSelfTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheSetFailoverAbstractSelfTest.java index 0d9d2b9..6052220 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheSetFailoverAbstractSelfTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/GridCacheSetFailoverAbstractSelfTest.java @@ -9,8 +9,8 @@ package org.gridgain.grid.kernal.processors.cache.datastructures; +import org.apache.ignite.*; import org.apache.ignite.lang.*; -import org.gridgain.grid.*; import org.gridgain.grid.cache.*; import org.gridgain.grid.cache.datastructures.*; import org.gridgain.grid.kernal.*; @@ -114,7 +114,7 @@ public class GridCacheSetFailoverAbstractSelfTest extends GridCacheAbstractSelfT // TODO: GG-7952, check for equality when GG-7952 fixed. assertTrue(size > 0); } - catch (GridRuntimeException ignore) { + catch (IgniteException ignore) { // No-op. } @@ -132,7 +132,7 @@ public class GridCacheSetFailoverAbstractSelfTest extends GridCacheAbstractSelfT // TODO: GG-7952, check for equality when GG-7952 fixed. assertTrue(cnt > 0); } - catch (GridRuntimeException ignore) { + catch (IgniteException ignore) { // No-op. } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/partitioned/GridCachePartitionedAtomicSequenceMultiThreadedTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/partitioned/GridCachePartitionedAtomicSequenceMultiThreadedTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/partitioned/GridCachePartitionedAtomicSequenceMultiThreadedTest.java index 7f1a187..329928a 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/partitioned/GridCachePartitionedAtomicSequenceMultiThreadedTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/partitioned/GridCachePartitionedAtomicSequenceMultiThreadedTest.java @@ -9,22 +9,22 @@ package org.gridgain.grid.kernal.processors.cache.datastructures.partitioned; +import org.apache.ignite.*; import org.apache.ignite.configuration.*; -import org.gridgain.grid.*; -import org.gridgain.grid.cache.*; -import org.gridgain.grid.cache.datastructures.*; -import org.gridgain.grid.kernal.processors.cache.datastructures.*; 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.gridgain.grid.cache.*; +import org.gridgain.grid.cache.datastructures.*; +import org.gridgain.grid.kernal.processors.cache.datastructures.*; import org.gridgain.grid.util.typedef.internal.*; import org.gridgain.testframework.junits.common.*; import java.util.*; import static org.gridgain.grid.cache.GridCacheAtomicityMode.*; -import static org.gridgain.grid.cache.GridCacheMode.*; import static org.gridgain.grid.cache.GridCacheDistributionMode.*; +import static org.gridgain.grid.cache.GridCacheMode.*; /** * Cache partitioned multi-threaded tests. @@ -163,7 +163,7 @@ public class GridCachePartitionedAtomicSequenceMultiThreadedTest extends GridCom final GridCacheAtomicSequence seq = grid().cache(null).dataStructures().atomicSequence(seqName, 0L, true); runSequenceClosure(new GridInUnsafeClosure<GridCacheAtomicSequence>() { - @Override public void apply(GridCacheAtomicSequence t) throws GridException { + @Override public void apply(GridCacheAtomicSequence t) throws IgniteCheckedException { t.incrementAndGet(); } }, seq, ITERATION_NUM, THREAD_NUM); @@ -179,7 +179,7 @@ public class GridCachePartitionedAtomicSequenceMultiThreadedTest extends GridCom final GridCacheAtomicSequence seq = grid().cache(null).dataStructures().atomicSequence(seqName, 0L, true); runSequenceClosure(new GridInUnsafeClosure<GridCacheAtomicSequence>() { - @Override public void apply(GridCacheAtomicSequence t) throws GridException { + @Override public void apply(GridCacheAtomicSequence t) throws IgniteCheckedException { t.incrementAndGet(); } }, seq, ITERATION_NUM, THREAD_NUM); @@ -195,7 +195,7 @@ public class GridCachePartitionedAtomicSequenceMultiThreadedTest extends GridCom final GridCacheAtomicSequence seq = grid().cache(null).dataStructures().atomicSequence(seqName, 0L, true); runSequenceClosure(new GridInUnsafeClosure<GridCacheAtomicSequence>() { - @Override public void apply(GridCacheAtomicSequence t) throws GridException { + @Override public void apply(GridCacheAtomicSequence t) throws IgniteCheckedException { t.getAndIncrement(); } }, seq, ITERATION_NUM, THREAD_NUM); @@ -211,7 +211,7 @@ public class GridCachePartitionedAtomicSequenceMultiThreadedTest extends GridCom final GridCacheAtomicSequence seq = grid().cache(null).dataStructures().atomicSequence(seqName, 0L, true); runSequenceClosure(new GridInUnsafeClosure<GridCacheAtomicSequence>() { - @Override public void apply(GridCacheAtomicSequence t) throws GridException { + @Override public void apply(GridCacheAtomicSequence t) throws IgniteCheckedException { t.getAndIncrement(); } }, seq, ITERATION_NUM, THREAD_NUM); @@ -227,7 +227,7 @@ public class GridCachePartitionedAtomicSequenceMultiThreadedTest extends GridCom final GridCacheAtomicSequence seq = grid().cache(null).dataStructures().atomicSequence(seqName, 0L, true); runSequenceClosure(new GridInUnsafeClosure<GridCacheAtomicSequence>() { - @Override public void apply(GridCacheAtomicSequence t) throws GridException { + @Override public void apply(GridCacheAtomicSequence t) throws IgniteCheckedException { t.addAndGet(5); } }, seq, ITERATION_NUM, THREAD_NUM); @@ -243,7 +243,7 @@ public class GridCachePartitionedAtomicSequenceMultiThreadedTest extends GridCom final GridCacheAtomicSequence seq = grid().cache(null).dataStructures().atomicSequence(seqName, 0L, true); runSequenceClosure(new GridInUnsafeClosure<GridCacheAtomicSequence>() { - @Override public void apply(GridCacheAtomicSequence t) throws GridException { + @Override public void apply(GridCacheAtomicSequence t) throws IgniteCheckedException { t.getAndAdd(5); } }, seq, ITERATION_NUM, THREAD_NUM); @@ -259,7 +259,7 @@ public class GridCachePartitionedAtomicSequenceMultiThreadedTest extends GridCom final GridCacheAtomicSequence seq = grid().cache(null).dataStructures().atomicSequence(seqName, 0L, true); runSequenceClosure(new GridInUnsafeClosure<GridCacheAtomicSequence>() { - @Override public void apply(GridCacheAtomicSequence t) throws GridException { + @Override public void apply(GridCacheAtomicSequence t) throws IgniteCheckedException { t.incrementAndGet(); t.getAndIncrement(); t.incrementAndGet(); @@ -280,7 +280,7 @@ public class GridCachePartitionedAtomicSequenceMultiThreadedTest extends GridCom final GridCacheAtomicSequence seq = grid().cache(null).dataStructures().atomicSequence(seqName, 0L, true); runSequenceClosure(new GridInUnsafeClosure<GridCacheAtomicSequence>() { - @Override public void apply(GridCacheAtomicSequence t) throws GridException { + @Override public void apply(GridCacheAtomicSequence t) throws IgniteCheckedException { t.getAndAdd(2); t.addAndGet(3); t.addAndGet(5); @@ -308,7 +308,7 @@ public class GridCachePartitionedAtomicSequenceMultiThreadedTest extends GridCom for (int i = 0; i < cnt; i++) c.apply(seq); } - catch (GridException e) { + catch (IgniteCheckedException e) { throw new RuntimeException(e); } } @@ -346,6 +346,6 @@ public class GridCachePartitionedAtomicSequenceMultiThreadedTest extends GridCom * @param <E> Closure argument type. */ private abstract static class GridInUnsafeClosure<E> { - public abstract void apply(E p) throws GridException; + public abstract void apply(E p) throws IgniteCheckedException; } } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/partitioned/GridCachePartitionedQueueEntryMoveSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/partitioned/GridCachePartitionedQueueEntryMoveSelfTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/partitioned/GridCachePartitionedQueueEntryMoveSelfTest.java index c7856c2..05f65df 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/partitioned/GridCachePartitionedQueueEntryMoveSelfTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/datastructures/partitioned/GridCachePartitionedQueueEntryMoveSelfTest.java @@ -94,7 +94,7 @@ public class GridCachePartitionedQueueEntryMoveSelfTest extends GridCommonAbstra //final CountDownLatch latch2 = new CountDownLatch(1); IgniteFuture<?> fut1 = GridTestUtils.runAsync(new Callable<Void>() { - @Override public Void call() throws GridException { + @Override public Void call() throws IgniteCheckedException { Ignite ignite = grid(0); GridCacheQueue<Integer> queue = ignite.cache(null).dataStructures().queue(queueName, QUEUE_CAP, @@ -134,7 +134,7 @@ public class GridCachePartitionedQueueEntryMoveSelfTest extends GridCommonAbstra //latch2.countDown(); IgniteFuture<?> fut2 = GridTestUtils.runAsync(new Callable<Void>() { - @Override public Void call() throws GridException { + @Override public Void call() throws IgniteCheckedException { Ignite ignite = grid(GRID_CNT); GridCacheQueue<Integer> queue = ignite.cache(null).dataStructures(). @@ -214,7 +214,7 @@ public class GridCachePartitionedQueueEntryMoveSelfTest extends GridCommonAbstra aff2 = nodes(aff, part, F.concat(true, tmpNodes, nodes)); if (retries-- < 0) - throw new GridException("Failed to find node IDs to change current affinity mapping."); + throw new IgniteCheckedException("Failed to find node IDs to change current affinity mapping."); } while (F.containsAny(aff1, aff2)); http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheAbstractJobExecutionTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheAbstractJobExecutionTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheAbstractJobExecutionTest.java index 9dd83c9..cabe4db 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheAbstractJobExecutionTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheAbstractJobExecutionTest.java @@ -122,7 +122,7 @@ public abstract class GridCacheAbstractJobExecutionTest extends GridCommonAbstra @IgniteInstanceResource private Ignite ignite; - @Override public Void applyx(final Integer i) throws GridException { + @Override public Void applyx(final Integer i) throws IgniteCheckedException { GridCache<String, int[]> cache = this.ignite.cache(null); try (GridCacheTx tx = cache.txStart(concur, isolation)) { http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheAtomicTimeoutSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheAtomicTimeoutSelfTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheAtomicTimeoutSelfTest.java index e9d6805..74525c1 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheAtomicTimeoutSelfTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheAtomicTimeoutSelfTest.java @@ -195,7 +195,7 @@ public class GridCacheAtomicTimeoutSelfTest extends GridCommonAbstractTest { fail(); } - catch (GridException e) { + catch (IgniteCheckedException e) { assertTrue("Invalid exception thrown: " + e, X.hasCause(e, GridCacheAtomicUpdateTimeoutException.class) || X.hasSuppressed(e, GridCacheAtomicUpdateTimeoutException.class)); } @@ -230,7 +230,7 @@ public class GridCacheAtomicTimeoutSelfTest extends GridCommonAbstractTest { fail(); } - catch (GridException e) { + catch (IgniteCheckedException e) { assertTrue("Invalid exception thrown: " + e, X.hasCause(e, GridCacheAtomicUpdateTimeoutException.class) || X.hasSuppressed(e, GridCacheAtomicUpdateTimeoutException.class)); } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheBasicOpAbstractTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheBasicOpAbstractTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheBasicOpAbstractTest.java index 9cc728a..53c6ff0 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheBasicOpAbstractTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheBasicOpAbstractTest.java @@ -236,7 +236,7 @@ public abstract class GridCacheBasicOpAbstractTest extends GridCommonAbstractTes /** * - * @throws GridException If test fails. + * @throws IgniteCheckedException If test fails. */ public void testOptimisticTransaction() throws Exception { CountDownLatch latch = new CountDownLatch(9); @@ -269,7 +269,7 @@ public abstract class GridCacheBasicOpAbstractTest extends GridCommonAbstractTes tx.commit(); } - catch (GridException e) { + catch (IgniteCheckedException e) { tx.rollback(); throw e; http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheEventAbstractTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheEventAbstractTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheEventAbstractTest.java index d8ff39c..484f9a2 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheEventAbstractTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheEventAbstractTest.java @@ -9,9 +9,9 @@ package org.gridgain.grid.kernal.processors.cache.distributed; +import org.apache.ignite.*; import org.apache.ignite.events.*; import org.apache.ignite.lang.*; -import org.gridgain.grid.*; import org.gridgain.grid.cache.*; import org.gridgain.grid.kernal.*; import org.gridgain.grid.kernal.processors.cache.*; @@ -25,9 +25,9 @@ import java.util.*; import java.util.concurrent.*; import java.util.concurrent.atomic.*; +import static org.apache.ignite.events.IgniteEventType.*; import static org.gridgain.grid.cache.GridCacheTxConcurrency.*; import static org.gridgain.grid.cache.GridCacheTxIsolation.*; -import static org.apache.ignite.events.IgniteEventType.*; /** * Tests events. @@ -99,7 +99,7 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe try { TestEventListener.waitForEventCount(((GridKernal)grid(0)).context(), evtCnts); } - catch (GridException e) { + catch (IgniteCheckedException e) { printEventCounters(gridIdx, evtCnts); throw e; @@ -125,9 +125,9 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe /** * Clear caches without generating events. * - * @throws GridException If failed to clear caches. + * @throws IgniteCheckedException If failed to clear caches. */ - private void clearCaches() throws GridException { + private void clearCaches() throws IgniteCheckedException { for (int i = 0; i < gridCnt; i++) { GridCache<String, Integer> cache = cache(i); @@ -218,7 +218,7 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe runTest( new TestCacheRunnable() { - @Override public void run(GridCache<String, Integer> cache) throws GridException { + @Override public void run(GridCache<String, Integer> cache) throws IgniteCheckedException { String key = "key"; Integer val = 1; @@ -244,7 +244,7 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe */ public void testGetPutRemoveTx1() throws Exception { runTest(new TestCacheRunnable() { - @Override public void run(GridCache<String, Integer> cache) throws GridException { + @Override public void run(GridCache<String, Integer> cache) throws IgniteCheckedException { Map.Entry<String, Integer> e = F.first(pairs(1).entrySet()); assert e != null; @@ -276,7 +276,7 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe */ public void testGetPutRemoveTx2() throws Exception { runTest(new TestCacheRunnable() { - @Override public void run(GridCache<String, Integer> cache) throws GridException { + @Override public void run(GridCache<String, Integer> cache) throws IgniteCheckedException { Map.Entry<String, Integer> e = F.first(pairs(1).entrySet()); assert e != null; @@ -316,7 +316,7 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe return; runTest(new TestCacheRunnable() { - @Override public void run(GridCache<String, Integer> cache) throws GridException { + @Override public void run(GridCache<String, Integer> cache) throws IgniteCheckedException { Map.Entry<String, Integer> e = F.first(pairs(1).entrySet()); assert e != null; @@ -342,7 +342,7 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe */ public void testGetPutRemoveAsyncTx1() throws Exception { runTest(new TestCacheRunnable() { - @Override public void run(GridCache<String, Integer> cache) throws GridException { + @Override public void run(GridCache<String, Integer> cache) throws IgniteCheckedException { Map.Entry<String, Integer> e = F.first(pairs(1).entrySet()); assert e != null; @@ -374,7 +374,7 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe */ public void testGetPutRemoveAsyncTx2() throws Exception { runTest(new TestCacheRunnable() { - @Override public void run(GridCache<String, Integer> cache) throws GridException { + @Override public void run(GridCache<String, Integer> cache) throws IgniteCheckedException { Map.Entry<String, Integer> e = F.first(pairs(1).entrySet()); assert e != null; @@ -410,7 +410,7 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe */ public void testPutRemovex() throws Exception { runTest(new TestCacheRunnable() { - @Override public void run(GridCache<String, Integer> cache) throws GridException { + @Override public void run(GridCache<String, Integer> cache) throws IgniteCheckedException { Map.Entry<String, Integer> e = F.first(pairs(1).entrySet()); assert e != null; @@ -434,7 +434,7 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe */ public void testPutRemovexTx1() throws Exception { runTest(new TestCacheRunnable() { - @Override public void run(GridCache<String, Integer> cache) throws GridException { + @Override public void run(GridCache<String, Integer> cache) throws IgniteCheckedException { Map.Entry<String, Integer> e = F.first(pairs(1).entrySet()); assert e != null; @@ -464,7 +464,7 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe */ public void testPutRemovexTx2() throws Exception { runTest(new TestCacheRunnable() { - @Override public void run(GridCache<String, Integer> cache) throws GridException { + @Override public void run(GridCache<String, Integer> cache) throws IgniteCheckedException { Map.Entry<String, Integer> e = F.first(pairs(1).entrySet()); assert e != null; @@ -498,7 +498,7 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe */ public void testPutIfAbsent() throws Exception { runTest(new TestCacheRunnable() { - @Override public void run(GridCache<String, Integer> cache) throws GridException { + @Override public void run(GridCache<String, Integer> cache) throws IgniteCheckedException { Iterator<Map.Entry<String, Integer>> iter = pairs(2).entrySet().iterator(); Map.Entry<String, Integer> e = iter.next(); @@ -529,7 +529,7 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe */ public void testPutIfAbsentTx() throws Exception { runTest(new TestCacheRunnable() { - @Override public void run(GridCache<String, Integer> cache) throws GridException { + @Override public void run(GridCache<String, Integer> cache) throws IgniteCheckedException { Iterator<Map.Entry<String, Integer>> iter = pairs(2).entrySet().iterator(); GridCacheTx tx = cache.txStart(); @@ -567,7 +567,7 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe */ public void testPutIfAbsentAsync() throws Exception { runTest(new TestCacheRunnable() { - @Override public void run(GridCache<String, Integer> cache) throws GridException { + @Override public void run(GridCache<String, Integer> cache) throws IgniteCheckedException { Iterator<Map.Entry<String, Integer>> iter = pairs(2).entrySet().iterator(); Map.Entry<String, Integer> e = iter.next(); @@ -601,7 +601,7 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe IgniteBiTuple[] evts = new IgniteBiTuple[] {F.t(EVT_CACHE_OBJECT_PUT, 2 * gridCnt), F.t(EVT_CACHE_OBJECT_READ, 1)}; runTest(new TestCacheRunnable() { - @Override public void run(GridCache<String, Integer> cache) throws GridException { + @Override public void run(GridCache<String, Integer> cache) throws IgniteCheckedException { Iterator<Map.Entry<String, Integer>> iter = pairs(2).entrySet().iterator(); // Optimistic transaction. @@ -639,7 +639,7 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe */ public void testFilteredPutRemovex() throws Exception { runTest(new TestCacheRunnable() { - @Override public void run(GridCache<String, Integer> cache) throws GridException { + @Override public void run(GridCache<String, Integer> cache) throws IgniteCheckedException { Map.Entry<String, Integer> e = F.first(pairs(1).entrySet()); assert e != null; @@ -668,7 +668,7 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe */ public void testFilteredPutRemovexTx1() throws Exception { runTest(new TestCacheRunnable() { - @Override public void run(GridCache<String, Integer> cache) throws GridException { + @Override public void run(GridCache<String, Integer> cache) throws IgniteCheckedException { assert cache.keySet().isEmpty() : "Key set is not empty: " + cache().keySet(); Map.Entry<String, Integer> e = F.first(pairs(1).entrySet()); @@ -706,7 +706,7 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe */ public void testFilteredPutRemovexTx2() throws Exception { runTest(new TestCacheRunnable() { - @Override public void run(GridCache<String, Integer> cache) throws GridException { + @Override public void run(GridCache<String, Integer> cache) throws IgniteCheckedException { Map.Entry<String, Integer> e = F.first(pairs(1).entrySet()); assert e != null; @@ -747,9 +747,9 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe private static interface TestCacheRunnable { /** * @param cache Cache. - * @throws GridException If any exception occurs. + * @throws IgniteCheckedException If any exception occurs. */ - void run(GridCache<String, Integer> cache) throws GridException; + void run(GridCache<String, Integer> cache) throws IgniteCheckedException; } /** @@ -837,10 +837,10 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe * * @param ctx Kernal context. * @param evtCnts Array of tuples with values: V1 - event type, V2 - expected event count. - * @throws GridException If failed to wait. + * @throws IgniteCheckedException If failed to wait. */ private static void waitForEventCount(GridKernalContext ctx, - IgniteBiTuple<Integer, Integer>... evtCnts) throws GridException { + IgniteBiTuple<Integer, Integer>... evtCnts) throws IgniteCheckedException { if (F.isEmpty(evtCnts)) return; @@ -940,7 +940,7 @@ public abstract class GridCacheEventAbstractTest extends GridCacheAbstractSelfTe // For partitioned caches we allow extra event for reads. if (expCnt < cnt && (!partitioned || evtType != EVT_CACHE_OBJECT_READ || expCnt + 1 < cnt)) - onDone(new GridException("Wrong event count [evtName=" + U.gridEventName(evtType) + ", evtType=" + + onDone(new IgniteCheckedException("Wrong event count [evtName=" + U.gridEventName(evtType) + ", evtType=" + evtType + ", expCnt=" + expCnt + ", actCnt=" + cnt + ", partitioned=" + partitioned + "]")); if (expCnt == cnt || (partitioned && expCnt + 1 == cnt)) http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheMultiNodeLockAbstractTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheMultiNodeLockAbstractTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheMultiNodeLockAbstractTest.java index 265a85f..2e8867b 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheMultiNodeLockAbstractTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheMultiNodeLockAbstractTest.java @@ -498,9 +498,9 @@ public abstract class GridCacheMultiNodeLockAbstractTest extends GridCommonAbstr } /** - * @throws GridException If test failed. + * @throws IgniteCheckedException If test failed. */ - public void testLockReentry() throws GridException { + public void testLockReentry() throws IgniteCheckedException { GridCache<Integer, String> cache = ignite1.cache(null); assert cache.lock(1, 0L); http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheMultithreadedFailoverAbstractTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheMultithreadedFailoverAbstractTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheMultithreadedFailoverAbstractTest.java index 57b08d0..cab17f0 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheMultithreadedFailoverAbstractTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheMultithreadedFailoverAbstractTest.java @@ -314,7 +314,7 @@ public class GridCacheMultithreadedFailoverAbstractTest extends GridCommonAbstra for (Integer key : rmvSet) expVals.remove(key); } - catch (GridException e) { + catch (IgniteCheckedException e) { log.error("Cache update failed [putMap=" + putMap+ ", rmvSet=" + rmvSet + ']', e); errCtr.incrementAndGet(); @@ -454,7 +454,7 @@ public class GridCacheMultithreadedFailoverAbstractTest extends GridCommonAbstra log.info("Comparing cache content."); if (!cmpLatch.await(60_000, TimeUnit.MILLISECONDS)) - throw new GridException("Failed to suspend threads executing put."); + throw new IgniteCheckedException("Failed to suspend threads executing put."); if (compareCaches(expVals)) { log.info("Cache comparison succeeded."); http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheNodeFailureAbstractTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheNodeFailureAbstractTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheNodeFailureAbstractTest.java index 270d86d..ec3ed43 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheNodeFailureAbstractTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheNodeFailureAbstractTest.java @@ -119,7 +119,7 @@ public abstract class GridCacheNodeFailureAbstractTest extends GridCommonAbstrac } /** - * @throws GridException If test failed. + * @throws IgniteCheckedException If test failed. */ public void testPessimisticReadCommitted() throws Throwable { // TODO: GG-7437. @@ -130,14 +130,14 @@ public abstract class GridCacheNodeFailureAbstractTest extends GridCommonAbstrac } /** - * @throws GridException If test failed. + * @throws IgniteCheckedException If test failed. */ public void testPessimisticRepeatableRead() throws Throwable { checkTransaction(PESSIMISTIC, REPEATABLE_READ); } /** - * @throws GridException If test failed. + * @throws IgniteCheckedException If test failed. */ public void testPessimisticSerializable() throws Throwable { checkTransaction(PESSIMISTIC, SERIALIZABLE); http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheTxTimeoutAbstractTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheTxTimeoutAbstractTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheTxTimeoutAbstractTest.java index 0c1ab54..67c210d 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheTxTimeoutAbstractTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/GridCacheTxTimeoutAbstractTest.java @@ -61,42 +61,42 @@ public class GridCacheTxTimeoutAbstractTest extends GridCommonAbstractTest { } /** - * @throws GridException If test failed. + * @throws IgniteCheckedException If test failed. */ public void testPessimisticReadCommitted() throws Exception { checkTransactionTimeout(PESSIMISTIC, READ_COMMITTED); } /** - * @throws GridException If test failed. + * @throws IgniteCheckedException If test failed. */ public void testPessimisticRepeatableRead() throws Exception { checkTransactionTimeout(PESSIMISTIC, REPEATABLE_READ); } /** - * @throws GridException If test failed. + * @throws IgniteCheckedException If test failed. */ public void testPessimisticSerializable() throws Exception { checkTransactionTimeout(PESSIMISTIC, SERIALIZABLE); } /** - * @throws GridException If test failed. + * @throws IgniteCheckedException If test failed. */ public void testOptimisticReadCommitted() throws Exception { checkTransactionTimeout(OPTIMISTIC, READ_COMMITTED); } /** - * @throws GridException If test failed. + * @throws IgniteCheckedException If test failed. */ public void testOptimisticRepeatableRead() throws Exception { checkTransactionTimeout(OPTIMISTIC, REPEATABLE_READ); } /** - * @throws GridException If test failed. + * @throws IgniteCheckedException If test failed. */ public void testOptimisticSerializable() throws Exception { checkTransactionTimeout(OPTIMISTIC, SERIALIZABLE); @@ -105,7 +105,7 @@ public class GridCacheTxTimeoutAbstractTest extends GridCommonAbstractTest { /** * @param concurrency Concurrency. * @param isolation Isolation. - * @throws GridException If test failed. + * @throws IgniteCheckedException If test failed. */ private void checkTransactionTimeout(GridCacheTxConcurrency concurrency, GridCacheTxIsolation isolation) throws Exception { http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheAtomicNearCacheSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheAtomicNearCacheSelfTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheAtomicNearCacheSelfTest.java index d27844a..f84d006 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheAtomicNearCacheSelfTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheAtomicNearCacheSelfTest.java @@ -761,9 +761,9 @@ public class GridCacheAtomicNearCacheSelfTest extends GridCommonAbstractTest { } /** - * @throws GridException If failed. + * @throws IgniteCheckedException If failed. */ - private void delay() throws GridException { + private void delay() throws IgniteCheckedException { if (writeOrderMode == CLOCK) U.sleep(100); } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheColocatedDebugTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheColocatedDebugTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheColocatedDebugTest.java index 9dd8fc5..246bfb4 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheColocatedDebugTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheColocatedDebugTest.java @@ -295,7 +295,7 @@ public class GridCacheColocatedDebugTest extends GridCommonAbstractTest { info(">>> " + itNum + " iterations completed."); } } - catch (GridException e) { + catch (IgniteCheckedException e) { fail("Unexpected exception caught: " + e); } } @@ -375,7 +375,7 @@ public class GridCacheColocatedDebugTest extends GridCommonAbstractTest { g0.cache(null).unlock(key); } } - catch (GridException e) { + catch (IgniteCheckedException e) { fail("Unexpected exception: " + e); } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtEvictionNearReadersSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtEvictionNearReadersSelfTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtEvictionNearReadersSelfTest.java index 0785439..64b28a5 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtEvictionNearReadersSelfTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtEvictionNearReadersSelfTest.java @@ -95,7 +95,7 @@ public class GridCacheDhtEvictionNearReadersSelfTest extends GridCommonAbstractT super.beforeTestsStarted(); if (GRID_CNT < 2) - throw new GridException("GRID_CNT must not be less than 2."); + throw new IgniteCheckedException("GRID_CNT must not be less than 2."); startGridsMultiThreaded(GRID_CNT); } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtEvictionSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtEvictionSelfTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtEvictionSelfTest.java index 281cd77..e3d9aa1 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtEvictionSelfTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtEvictionSelfTest.java @@ -89,7 +89,7 @@ public class GridCacheDhtEvictionSelfTest extends GridCommonAbstractTest { super.beforeTestsStarted(); if (GRID_CNT < 2) - throw new GridException("GRID_CNT must not be less than 2."); + throw new IgniteCheckedException("GRID_CNT must not be less than 2."); startGrids(GRID_CNT); } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtInternalEntrySelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtInternalEntrySelfTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtInternalEntrySelfTest.java index cf8818c..78ad8ab 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtInternalEntrySelfTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtInternalEntrySelfTest.java @@ -158,9 +158,9 @@ public class GridCacheDhtInternalEntrySelfTest extends GridCommonAbstractTest { /** * @param node Node. * @return Atomic long value. - * @throws GridException In case of error. + * @throws IgniteCheckedException In case of error. */ - private GridCacheAtomicLongValue peekNear(ClusterNode node) throws GridException { + private GridCacheAtomicLongValue peekNear(ClusterNode node) throws IgniteCheckedException { return (GridCacheAtomicLongValue)grid(node).cache(null).peek( new GridCacheInternalKeyImpl(ATOMIC_LONG_NAME), Collections.singleton(NEAR_ONLY)); } @@ -168,9 +168,9 @@ public class GridCacheDhtInternalEntrySelfTest extends GridCommonAbstractTest { /** * @param node Node. * @return Atomic long value. - * @throws GridException In case of error. + * @throws IgniteCheckedException In case of error. */ - private GridCacheAtomicLongValue peekDht(ClusterNode node) throws GridException { + private GridCacheAtomicLongValue peekDht(ClusterNode node) throws IgniteCheckedException { return (GridCacheAtomicLongValue)grid(node).cache(null).peek( new GridCacheInternalKeyImpl(ATOMIC_LONG_NAME), Collections.singleton(PARTITIONED_ONLY)); } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtMultiBackupTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtMultiBackupTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtMultiBackupTest.java index 0c13479..f490bff 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtMultiBackupTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtMultiBackupTest.java @@ -45,7 +45,7 @@ public class GridCacheDhtMultiBackupTest extends GridCommonAbstractTest { @IgniteInstanceResource private Ignite g; - @Override public void applyx() throws GridException { + @Override public void applyx() throws IgniteCheckedException { X.println("Checking whether cache is empty."); GridCache<SampleKey, SampleValue> cache = g.cache("partitioned"); http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtPreloadBigDataSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtPreloadBigDataSelfTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtPreloadBigDataSelfTest.java index 41c7fb8..75728b8 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtPreloadBigDataSelfTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtPreloadBigDataSelfTest.java @@ -158,7 +158,7 @@ public class GridCacheDhtPreloadBigDataSelfTest extends GridCommonAbstractTest { @IgniteInstanceResource private Ignite ignite; - @Override public void onLifecycleEvent(LifecycleEventType evt) throws GridException { + @Override public void onLifecycleEvent(LifecycleEventType evt) throws IgniteCheckedException { if (evt == LifecycleEventType.AFTER_GRID_START) { GridCache<Integer, byte[]> c = ignite.cache(null); @@ -199,9 +199,9 @@ public class GridCacheDhtPreloadBigDataSelfTest extends GridCommonAbstractTest { * @param c Cache. * @param cnt Key count. * @param kbSize Size in KB. - * @throws GridException If failed. + * @throws IgniteCheckedException If failed. */ - private void populate(GridCache<Integer, byte[]> c, int cnt, int kbSize) throws GridException { + private void populate(GridCache<Integer, byte[]> c, int cnt, int kbSize) throws IgniteCheckedException { for (int i = 0; i < cnt; i++) c.put(i, value(kbSize)); } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtPreloadDisabledSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtPreloadDisabledSelfTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtPreloadDisabledSelfTest.java index a782718..82f21e9 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtPreloadDisabledSelfTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtPreloadDisabledSelfTest.java @@ -262,9 +262,9 @@ public class GridCacheDhtPreloadDisabledSelfTest extends GridCommonAbstractTest /** * @param c Cache. * @param cnt Key count. - * @throws GridException If failed. + * @throws IgniteCheckedException If failed. */ - private void putKeys(GridCache<Integer, String> c, int cnt) throws GridException { + private void putKeys(GridCache<Integer, String> c, int cnt) throws IgniteCheckedException { for (int i = 0; i < cnt; i++) c.put(i, Integer.toString(i)); } http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtPreloadSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtPreloadSelfTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtPreloadSelfTest.java index b4fb65e..68994c4 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtPreloadSelfTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtPreloadSelfTest.java @@ -598,9 +598,9 @@ public class GridCacheDhtPreloadSelfTest extends GridCommonAbstractTest { /** * @param c Cache. * @param cnt Key count. - * @throws GridException If failed. + * @throws IgniteCheckedException If failed. */ - private void putKeys(GridCache<Integer, String> c, int cnt) throws GridException { + private void putKeys(GridCache<Integer, String> c, int cnt) throws IgniteCheckedException { for (int i = 0; i < cnt; i++) c.put(i, Integer.toString(i)); } @@ -609,9 +609,9 @@ public class GridCacheDhtPreloadSelfTest extends GridCommonAbstractTest { * @param cache Cache. * @param cnt Key count. * @param grids Grids. - * @throws GridException If failed. + * @throws IgniteCheckedException If failed. */ - private void checkKeys(GridCache<Integer, String> cache, int cnt, Iterable<Ignite> grids) throws GridException { + private void checkKeys(GridCache<Integer, String> cache, int cnt, Iterable<Ignite> grids) throws IgniteCheckedException { GridCacheAffinity<Integer> aff = affinity(cache); Ignite ignite = cache.gridProjection().ignite(); http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/06931b4b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtPreloadStartStopSelfTest.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtPreloadStartStopSelfTest.java b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtPreloadStartStopSelfTest.java index c95716e..cba688a 100644 --- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtPreloadStartStopSelfTest.java +++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridCacheDhtPreloadStartStopSelfTest.java @@ -231,9 +231,9 @@ public class GridCacheDhtPreloadStartStopSelfTest extends GridCommonAbstractTest /** * @param c Cache. * @param cnt Key count. - * @throws GridException If failed. + * @throws IgniteCheckedException If failed. */ - private void putKeys(GridCache<Integer, String> c, int cnt) throws GridException { + private void putKeys(GridCache<Integer, String> c, int cnt) throws IgniteCheckedException { for (int i = 0; i < cnt; i++) c.put(i, Integer.toString(i)); } @@ -241,9 +241,9 @@ public class GridCacheDhtPreloadStartStopSelfTest extends GridCommonAbstractTest /** * @param c Cache. * @param cnt Key count. - * @throws GridException If failed. + * @throws IgniteCheckedException If failed. */ - private void checkKeys(GridCache<Integer, String> c, int cnt) throws GridException { + private void checkKeys(GridCache<Integer, String> c, int cnt) throws IgniteCheckedException { GridCacheAffinity<Integer> aff = affinity(c); boolean sync = isSync(c);