ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sevdoki...@apache.org
Subject [09/35] incubator-ignite git commit: # IGNITE-56 Migration tests to IgniteCache
Date Tue, 10 Feb 2015 16:15:53 GMT
# IGNITE-56 Migration tests to IgniteCache


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

Branch: refs/heads/ignite-96
Commit: 05163cafdd3f0a9d0ae42cf3748053d0c659f0d2
Parents: 1d7267a
Author: sevdokimov <sevdokimov@gridgain.com>
Authored: Mon Feb 9 18:33:24 2015 +0300
Committer: sevdokimov <sevdokimov@gridgain.com>
Committed: Mon Feb 9 18:33:37 2015 +0300

----------------------------------------------------------------------
 .../processors/cache/IgniteTxAbstractTest.java  | 11 +---
 ...tractDistributedByteArrayValuesSelfTest.java | 44 +++++++-------
 .../GridCacheAbstractPrimarySyncSelfTest.java   |  5 +-
 .../GridCacheAtomicTimeoutSelfTest.java         | 36 +++++++----
 .../GridCacheBasicOpAbstractTest.java           | 63 +++++++++++++-------
 .../GridCacheClientModesAbstractSelfTest.java   |  2 +-
 6 files changed, 97 insertions(+), 64 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/05163caf/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteTxAbstractTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteTxAbstractTest.java
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteTxAbstractTest.java
index 3c87b52..da32afc 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteTxAbstractTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteTxAbstractTest.java
@@ -124,15 +124,6 @@ abstract class IgniteTxAbstractTest extends GridCommonAbstractTest {
     }
 
     /**
-     * @param i Grid index.
-     * @return Cache.
-     */
-    @SuppressWarnings("unchecked")
-    @Override protected GridCache<Integer, String> cache(int i) {
-        return grid(i).cache(null);
-    }
-
-    /**
      * @return Keys.
      */
     protected Iterable<Integer> getKeys() {
@@ -414,7 +405,7 @@ abstract class IgniteTxAbstractTest extends GridCommonAbstractTest {
                     String v1 = null;
 
                     for (int j = 0; j < gridCount(); j++) {
-                        GridCache<Integer, String> cache = cache(j);
+                        GridCache<Integer, String> cache = internalCache(j);
 
                         IgniteTx tx = ignite(j).transactions().tx();
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/05163caf/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheAbstractDistributedByteArrayValuesSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheAbstractDistributedByteArrayValuesSelfTest.java
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheAbstractDistributedByteArrayValuesSelfTest.java
index dfcf6ab..ad854b6 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheAbstractDistributedByteArrayValuesSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheAbstractDistributedByteArrayValuesSelfTest.java
@@ -40,13 +40,13 @@ public abstract class GridCacheAbstractDistributedByteArrayValuesSelfTest
extend
     protected static Ignite[] ignites;
 
     /** Regular caches. */
-    private static GridCache<Integer, Object>[] caches;
+    private static IgniteCache<Integer, Object>[] caches;
 
     /** Offheap values caches. */
-    private static GridCache<Integer, Object>[] cachesOffheap;
+    private static IgniteCache<Integer, Object>[] cachesOffheap;
 
     /** Offheap tiered caches. */
-    private static GridCache<Integer, Object>[] cachesOffheapTiered;
+    private static IgniteCache<Integer, Object>[] cachesOffheapTiered;
 
     /** {@inheritDoc} */
     @Override protected IgniteConfiguration getConfiguration(String gridName) throws Exception
{
@@ -142,16 +142,16 @@ public abstract class GridCacheAbstractDistributedByteArrayValuesSelfTest
extend
 
         ignites = new Ignite[gridCnt];
 
-        caches = new GridCache[gridCnt];
-        cachesOffheap = new GridCache[gridCnt];
-        cachesOffheapTiered = new GridCache[gridCnt];
+        caches = new IgniteCache[gridCnt];
+        cachesOffheap = new IgniteCache[gridCnt];
+        cachesOffheapTiered = new IgniteCache[gridCnt];
 
         for (int i = 0; i < gridCnt; i++) {
             ignites[i] = startGrid(i);
 
-            caches[i] = ignites[i].cache(CACHE_REGULAR);
-            cachesOffheap[i] = ignites[i].cache(CACHE_OFFHEAP);
-            cachesOffheapTiered[i] = ignites[i].cache(CACHE_OFFHEAP_TIERED);
+            caches[i] = ignites[i].jcache(CACHE_REGULAR);
+            cachesOffheap[i] = ignites[i].jcache(CACHE_OFFHEAP);
+            cachesOffheapTiered[i] = ignites[i].jcache(CACHE_OFFHEAP_TIERED);
         }
     }
 
@@ -280,16 +280,16 @@ public abstract class GridCacheAbstractDistributedByteArrayValuesSelfTest
extend
      * @throws Exception If failed.
      */
     public void testSwap() throws Exception {
-        for (GridCache<Integer, Object> cache : caches)
+        for (IgniteCache<Integer, Object> cache : caches)
             assert cache.configuration().isSwapEnabled();
 
         byte[] val1 = wrap(1);
 
-        GridCache<Integer, Object> primaryCache = null;
+        IgniteCache<Integer, Object> primaryCache = null;
 
         int i = 0;
 
-        for (GridCache<Integer, Object> cache : caches) {
+        for (IgniteCache<Integer, Object> cache : caches) {
             Ignite ignite = ignites[i++];
 
             if (ignite.affinity(null).isPrimary(ignite.cluster().localNode(), SWAP_TEST_KEY))
{
@@ -305,11 +305,13 @@ public abstract class GridCacheAbstractDistributedByteArrayValuesSelfTest
extend
 
         assert Arrays.equals(val1, (byte[])primaryCache.get(SWAP_TEST_KEY));
 
-        assert primaryCache.evict(SWAP_TEST_KEY);
+        primaryCache.evict(SWAP_TEST_KEY);
 
         assert primaryCache.peek(SWAP_TEST_KEY) == null;
 
-        assert Arrays.equals(val1, (byte[])primaryCache.promote(SWAP_TEST_KEY));
+        primaryCache.promote(SWAP_TEST_KEY);
+
+        assert Arrays.equals(val1, (byte[])primaryCache.localPeek(SWAP_TEST_KEY, CachePeekMode.ONHEAP));
     }
 
     /**
@@ -321,7 +323,7 @@ public abstract class GridCacheAbstractDistributedByteArrayValuesSelfTest
extend
      * @param val Value.
      * @throws Exception If failed.
      */
-    private void testTransaction0(GridCache<Integer, Object>[] caches, IgniteTxConcurrency
concurrency,
+    private void testTransaction0(IgniteCache<Integer, Object>[] caches, IgniteTxConcurrency
concurrency,
         Integer key, byte[] val) throws Exception {
         testTransactionMixed0(caches, concurrency, key, val, null, null);
     }
@@ -337,10 +339,10 @@ public abstract class GridCacheAbstractDistributedByteArrayValuesSelfTest
extend
      * @param val2 Value 2.
      * @throws Exception If failed.
      */
-    private void testTransactionMixed0(GridCache<Integer, Object>[] caches, IgniteTxConcurrency
concurrency,
+    private void testTransactionMixed0(IgniteCache<Integer, Object>[] caches, IgniteTxConcurrency
concurrency,
         Integer key1, byte[] val1, @Nullable Integer key2, @Nullable Object val2) throws
Exception {
-        for (GridCache<Integer, Object> cache : caches) {
-            IgniteTx tx = cache.txStart(concurrency, REPEATABLE_READ);
+        for (IgniteCache<Integer, Object> cache : caches) {
+            IgniteTx tx = cache.unwrap(Ignite.class).transactions().txStart(concurrency,
REPEATABLE_READ);
 
             try {
                 cache.put(key1, val1);
@@ -354,8 +356,8 @@ public abstract class GridCacheAbstractDistributedByteArrayValuesSelfTest
extend
                 tx.close();
             }
 
-            for (GridCache<Integer, Object> cacheInner : caches) {
-                tx = cacheInner.txStart(concurrency, REPEATABLE_READ);
+            for (IgniteCache<Integer, Object> cacheInner : caches) {
+                tx = cacheInner.unwrap(Ignite.class).transactions().txStart(concurrency,
REPEATABLE_READ);
 
                 try {
                     assertArrayEquals(val1, (byte[])cacheInner.get(key1));
@@ -373,7 +375,7 @@ public abstract class GridCacheAbstractDistributedByteArrayValuesSelfTest
extend
                 }
             }
 
-            tx = cache.txStart(concurrency, REPEATABLE_READ);
+            tx = cache.unwrap(Ignite.class).transactions().txStart(concurrency, REPEATABLE_READ);
 
             try {
                 cache.remove(key1);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/05163caf/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheAbstractPrimarySyncSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheAbstractPrimarySyncSelfTest.java
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheAbstractPrimarySyncSelfTest.java
index 6d82740..f7c696d 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheAbstractPrimarySyncSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheAbstractPrimarySyncSelfTest.java
@@ -17,6 +17,7 @@
 
 package org.apache.ignite.internal.processors.cache.distributed;
 
+import org.apache.ignite.*;
 import org.apache.ignite.cache.*;
 import org.apache.ignite.configuration.*;
 import org.apache.ignite.spi.discovery.tcp.*;
@@ -89,10 +90,10 @@ public abstract class GridCacheAbstractPrimarySyncSelfTest extends GridCommonAbs
     public void testPrimarySync() throws Exception {
         for (int i = 0; i < GRID_CNT; i++) {
             for (int j = 0; j < GRID_CNT; j++) {
-                GridCache<Integer, Integer> cache = grid(j).cache(null);
+                IgniteCache<Integer, Integer> cache = grid(j).jcache(null);
 
                 if (grid(j).affinity(null).isPrimary(grid(j).localNode(), i)) {
-                    try (IgniteTx tx = cache.txStart(PESSIMISTIC, REPEATABLE_READ)) {
+                    try (IgniteTx tx = grid(j).transactions().txStart(PESSIMISTIC, REPEATABLE_READ))
{
                         cache.put(i, i);
 
                         tx.commit();

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/05163caf/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheAtomicTimeoutSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheAtomicTimeoutSelfTest.java
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheAtomicTimeoutSelfTest.java
index 6d62a84..2c48b1f 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheAtomicTimeoutSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheAtomicTimeoutSelfTest.java
@@ -30,6 +30,7 @@ import org.apache.ignite.internal.util.direct.*;
 import org.apache.ignite.internal.util.nio.*;
 import org.apache.ignite.internal.util.typedef.*;
 import org.apache.ignite.internal.util.typedef.internal.*;
+import org.apache.ignite.lang.*;
 import org.apache.ignite.spi.*;
 import org.apache.ignite.spi.communication.tcp.*;
 import org.apache.ignite.testframework.*;
@@ -113,7 +114,8 @@ public class GridCacheAtomicTimeoutSelfTest extends GridCommonAbstractTest
{
 
         TestCommunicationSpi commSpi = (TestCommunicationSpi)grid(0).configuration().getCommunicationSpi();
 
-        GridCache<Object, Object> cache = ignite.cache(null);
+        IgniteCache<Object, Object> cache = ignite.jcache(null);
+        IgniteCache<Object, Object> cacheAsync = cache.withAsync();
 
         int key = keyForTest();
 
@@ -121,7 +123,9 @@ public class GridCacheAtomicTimeoutSelfTest extends GridCommonAbstractTest
{
 
         commSpi.skipNearRequest = true;
 
-        IgniteInternalFuture<Object> fut = cache.putAsync(key, 1);
+        cacheAsync.put(key, 1);
+
+        IgniteFuture<Object> fut = cacheAsync.future();
 
         Map<UUID, GridCommunicationClient> clients = U.field(commSpi, "clients");
 
@@ -134,7 +138,10 @@ public class GridCacheAtomicTimeoutSelfTest extends GridCommonAbstractTest
{
 
             fail();
         }
-        catch (CacheAtomicUpdateTimeoutCheckedException ignore) {
+        catch (IgniteException e) {
+            if (!(e.getCause() instanceof CacheAtomicUpdateTimeoutCheckedException))
+                throw e;
+
             // Expected exception.
         }
     }
@@ -145,7 +152,8 @@ public class GridCacheAtomicTimeoutSelfTest extends GridCommonAbstractTest
{
     public void testNearUpdateResponseLost() throws Exception {
         Ignite ignite = grid(0);
 
-        GridCache<Object, Object> cache = ignite.cache(null);
+        IgniteCache<Object, Object> cache = ignite.jcache(null);
+        IgniteCache<Object, Object> cacheAsync = cache.withAsync();
 
         int key = keyForTest();
 
@@ -155,7 +163,9 @@ public class GridCacheAtomicTimeoutSelfTest extends GridCommonAbstractTest
{
 
         commSpi.skipNearResponse = true;
 
-        IgniteInternalFuture<Object> fut = cache.putAsync(key, 1);
+        cacheAsync.put(key, 1);
+
+        IgniteFuture<Object> fut = cacheAsync.future();
 
         Map<UUID, GridCommunicationClient> clients = U.field(commSpi, "clients");
 
@@ -168,7 +178,10 @@ public class GridCacheAtomicTimeoutSelfTest extends GridCommonAbstractTest
{
 
             fail();
         }
-        catch (CacheAtomicUpdateTimeoutCheckedException ignore) {
+        catch (IgniteException e) {
+            if (!(e.getCause() instanceof CacheAtomicUpdateTimeoutCheckedException))
+                throw e;
+
             // Expected exception.
         }
     }
@@ -214,7 +227,8 @@ public class GridCacheAtomicTimeoutSelfTest extends GridCommonAbstractTest
{
     public void testDhtUpdateResponseLost() throws Exception {
         Ignite ignite = grid(0);
 
-        GridCache<Object, Object> cache = ignite.cache(null);
+        IgniteCache<Object, Object> cache = ignite.jcache(null);
+        IgniteCache<Object, Object> cacheAsync = cache.withAsync();
 
         int key = keyForTest();
 
@@ -224,7 +238,9 @@ public class GridCacheAtomicTimeoutSelfTest extends GridCommonAbstractTest
{
 
         commSpi.skipDhtResponse = true;
 
-        IgniteInternalFuture<Object> fut = cache.putAsync(key, 1);
+        cacheAsync.put(key, 1);
+
+        IgniteFuture<Object> fut = cacheAsync.future();
 
         Map<UUID, GridCommunicationClient> clients = U.field(commSpi, "clients");
 
@@ -237,7 +253,7 @@ public class GridCacheAtomicTimeoutSelfTest extends GridCommonAbstractTest
{
 
             fail();
         }
-        catch (IgniteCheckedException e) {
+        catch (IgniteException e) {
             assertTrue("Invalid exception thrown: " + e, X.hasCause(e, CacheAtomicUpdateTimeoutCheckedException.class)
                 || X.hasSuppressed(e, CacheAtomicUpdateTimeoutCheckedException.class));
         }
@@ -249,7 +265,7 @@ public class GridCacheAtomicTimeoutSelfTest extends GridCommonAbstractTest
{
     private int keyForTest() {
         int i = 0;
 
-        CacheAffinity<Object> aff = grid(0).cache(null).affinity();
+        CacheAffinity<Object> aff = grid(0).affinity(null);
 
         while (!aff.isPrimary(grid(1).localNode(), i) || !aff.isBackup(grid(2).localNode(),
i))
             i++;

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/05163caf/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheBasicOpAbstractTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheBasicOpAbstractTest.java
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheBasicOpAbstractTest.java
index 65b8dca..2009221 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheBasicOpAbstractTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheBasicOpAbstractTest.java
@@ -21,7 +21,6 @@ import org.apache.ignite.*;
 import org.apache.ignite.cache.*;
 import org.apache.ignite.configuration.*;
 import org.apache.ignite.events.*;
-import org.apache.ignite.internal.*;
 import org.apache.ignite.internal.util.typedef.*;
 import org.apache.ignite.lang.*;
 import org.apache.ignite.spi.discovery.tcp.*;
@@ -88,7 +87,7 @@ public abstract class GridCacheBasicOpAbstractTest extends GridCommonAbstractTes
     /** {@inheritDoc} */
     @Override protected void beforeTest() throws Exception {
         for (Ignite g : G.allGrids())
-            g.cache(null).clear();
+            g.jcache(null).clear();
     }
 
     /**
@@ -101,9 +100,9 @@ public abstract class GridCacheBasicOpAbstractTest extends GridCommonAbstractTes
         CacheEventListener lsnr = new CacheEventListener(latch);
 
         try {
-            GridCache<String, String> cache1 = ignite1.cache(null);
-            GridCache<String, String> cache2 = ignite2.cache(null);
-            GridCache<String, String> cache3 = ignite3.cache(null);
+            IgniteCache<String, String> cache1 = ignite1.jcache(null);
+            IgniteCache<String, String> cache2 = ignite2.jcache(null);
+            IgniteCache<String, String> cache3 = ignite3.jcache(null);
 
             ignite1.events().localListen(lsnr, EVT_CACHE_OBJECT_PUT, EVT_CACHE_OBJECT_REMOVED);
             ignite2.events().localListen(lsnr, EVT_CACHE_OBJECT_PUT, EVT_CACHE_OBJECT_REMOVED);
@@ -156,9 +155,9 @@ public abstract class GridCacheBasicOpAbstractTest extends GridCommonAbstractTes
 
             info("Stop latch wait 3");
 
-            assert !cache1.containsKey("1") : "Key set: " + cache1.keySet();
-            assert !cache2.containsKey("1") : "Key set: " + cache2.keySet();
-            assert !cache3.containsKey("1") : "Key set: " + cache3.keySet();
+            assert !cache1.containsKey("1");
+            assert !cache2.containsKey("1");
+            assert !cache3.containsKey("1");
         }
         finally {
             ignite1.events().stopLocalListen(lsnr);
@@ -176,23 +175,32 @@ public abstract class GridCacheBasicOpAbstractTest extends GridCommonAbstractTes
         CacheEventListener lsnr = new CacheEventListener(latch);
 
         try {
-            GridCache<String, String> cache1 = ignite1.cache(null);
-            GridCache<String, String> cache2 = ignite2.cache(null);
-            GridCache<String, String> cache3 = ignite3.cache(null);
+            IgniteCache<String, String> cache1 = ignite1.jcache(null);
+            IgniteCache<String, String> cache1Async = cache1.withAsync();
+            IgniteCache<String, String> cache2 = ignite2.jcache(null);
+            IgniteCache<String, String> cache2Async = cache2.withAsync();
+            IgniteCache<String, String> cache3 = ignite3.jcache(null);
+            IgniteCache<String, String> cache3Async = cache3.withAsync();
 
             ignite1.events().localListen(lsnr, EVT_CACHE_OBJECT_PUT, EVT_CACHE_OBJECT_REMOVED);
             ignite2.events().localListen(lsnr, EVT_CACHE_OBJECT_PUT, EVT_CACHE_OBJECT_REMOVED);
             ignite3.events().localListen(lsnr, EVT_CACHE_OBJECT_PUT, EVT_CACHE_OBJECT_REMOVED);
 
-            IgniteInternalFuture<String> f1 = cache1.getAsync("async1");
+            cache1Async.get("async1");
+
+            IgniteFuture<String> f1 = cache1Async.future();
 
             assert f1.get() == null;
 
-            f1 = cache1.putAsync("async1", "asyncval1");
+            cache1Async.put("async1", "asyncval1");
+
+            f1 = cache1Async.future();
 
             assert f1.get() == null;
 
-            f1 = cache1.getAsync("async1");
+            cache1Async.get("async1");
+
+            f1 = cache1Async.future();
 
             String v1 = f1.get();
 
@@ -201,8 +209,13 @@ public abstract class GridCacheBasicOpAbstractTest extends GridCommonAbstractTes
 
             assert latch.await(5, SECONDS);
 
-            IgniteInternalFuture<String> f2 = cache2.getAsync("async1");
-            IgniteInternalFuture<String> f3 = cache3.getAsync("async1");
+            cache2Async.get("async1");
+
+            IgniteFuture<String> f2 = cache2Async.future();
+
+            cache3Async.get("async1");
+
+            IgniteFuture<String> f3 = cache3Async.future();
 
             String v2 = f2.get();
             String v3 = f3.get();
@@ -215,15 +228,25 @@ public abstract class GridCacheBasicOpAbstractTest extends GridCommonAbstractTes
 
             lsnr.setLatch(latch = new CountDownLatch(3));
 
-            f2 = cache2.removeAsync("async1");
+            cache2Async.getAndRemove("async1");
+
+            f2 = cache2.future();
 
             assert "asyncval1".equals(f2.get());
 
             assert latch.await(5, SECONDS);
 
-            f1 = cache1.getAsync("async1");
-            f2 = cache2.getAsync("async1");
-            f3 = cache3.getAsync("async1");
+            cache1Async.get("async1");
+
+            f1 = cache1Async.future();
+
+            cache2Async.get("async1");
+
+            f2 = cache2Async.future();
+
+            cache3Async.get("async1");
+
+            f3 = cache3Async.future();
 
             v1 = f1.get();
             v2 = f2.get();

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/05163caf/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheClientModesAbstractSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheClientModesAbstractSelfTest.java
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheClientModesAbstractSelfTest.java
index dfc9381..014c96a 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheClientModesAbstractSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/GridCacheClientModesAbstractSelfTest.java
@@ -107,7 +107,7 @@ public abstract class GridCacheClientModesAbstractSelfTest extends GridCacheAbst
         for (int key = 0; key < 10; key++) {
             for (int i = 1; i < gridCount(); i++) {
                 if (grid(i).affinity(null).isPrimaryOrBackup(grid(i).localNode(), key))
-                    assertEquals(key, grid(i).cache(null).peek(key));
+                    assertEquals(key, grid(i).jcache(null).peek(key));
             }
 
             if (nearEnabled())


Mime
View raw message