ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From voze...@apache.org
Subject [3/6] incubator-ignite git commit: ignite-1222
Date Tue, 11 Aug 2015 12:24:57 GMT
ignite-1222


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

Branch: refs/heads/ignite-gg-9615
Commit: fbda19d4b530051f0ab6784379afe66be7d44c76
Parents: cd844a7
Author: Anton Vinogradov <vinogradov.anton@gmail.com>
Authored: Mon Aug 10 16:11:46 2015 +0300
Committer: Anton Vinogradov <vinogradov.anton@gmail.com>
Committed: Mon Aug 10 16:11:46 2015 +0300

----------------------------------------------------------------------
 .../cache/CacheStopAndDestroySelfTest.java      | 87 --------------------
 1 file changed, 87 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/fbda19d4/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheStopAndDestroySelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheStopAndDestroySelfTest.java
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheStopAndDestroySelfTest.java
index 803789e..17f0db7 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheStopAndDestroySelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheStopAndDestroySelfTest.java
@@ -712,93 +712,6 @@ public class CacheStopAndDestroySelfTest extends GridCommonAbstractTest
{
     }
 
     /**
-     * Tests concurrent close.
-     *
-     * @throws Exception If failed.
-     */
-    public void testConcurrentCloseSetWithTry() throws Exception {
-        final AtomicInteger a1 = new AtomicInteger();
-        final AtomicInteger a2 = new AtomicInteger();
-        final AtomicInteger a3 = new AtomicInteger();
-        final AtomicInteger a4 = new AtomicInteger();
-
-        Thread t1 = new Thread(new Runnable() {
-            @Override public void run() {
-                Thread.currentThread().setName("test-thread-1");
-
-                closeWithTry(a1, 0);
-            }
-        });
-        Thread t2 = new Thread(new Runnable() {
-            @Override public void run() {
-                Thread.currentThread().setName("test-thread-2");
-
-                closeWithTry(a2, 0);
-            }
-        });
-        Thread t3 = new Thread(new Runnable() {
-            @Override public void run() {
-                Thread.currentThread().setName("test-thread-3");
-
-                closeWithTry(a3, 2);
-            }
-        });
-        Thread t4 = new Thread(new Runnable() {
-            @Override public void run() {
-                Thread.currentThread().setName("test-thread-4");
-
-                closeWithTry(a4, 2);
-            }
-        });
-
-        IgniteCache<Object, Object> cache = grid(0).getOrCreateCache(getDhtConfig());
-
-        cache.close();
-
-        t1.start();
-        t2.start();
-        t3.start();
-        t4.start();
-
-        try {
-            U.sleep(1000);
-        }
-        finally {
-            stop = true;
-        }
-
-        t1.join();
-        t2.join();
-        t3.join();
-        t4.join();
-
-        assert a1.get() > 1;
-        assert a2.get() > 1;
-        assert a3.get() > 1;
-        assert a4.get() > 1;
-
-        checkUsageFails(cache);
-    }
-
-    /**
-     * @param a AtomicInteger.
-     * @param node Node.
-     */
-    public void closeWithTry(AtomicInteger a, int node) {
-        while (!stop) {
-            try (IgniteCache<String, String> cache = grid(node).getOrCreateCache(getDhtConfig()))
{
-                a.incrementAndGet();
-
-                assert cache.get(KEY_VAL) == null || cache.get(KEY_VAL).equals(KEY_VAL);
-
-                cache.put(KEY_VAL, KEY_VAL);
-
-                assert cache.get(KEY_VAL).equals(KEY_VAL);
-            }
-        }
-    }
-
-    /**
      * Tests start -> destroy -> start -> close using CacheManager.
      */
     public void testTckStyleCreateDestroyClose() {


Mime
View raw message