ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sboi...@apache.org
Subject ignite git commit: Hanging tests fixed
Date Mon, 16 May 2016 15:34:49 GMT
Repository: ignite
Updated Branches:
  refs/heads/master 5f6fda3df -> 223708a89


Hanging tests fixed


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

Branch: refs/heads/master
Commit: 223708a898420b4b9ea421ebfd0296d1e76857de
Parents: 5f6fda3
Author: agura <agura@gridgain.com>
Authored: Mon May 16 18:32:07 2016 +0300
Committer: agura <agura@gridgain.com>
Committed: Mon May 16 18:34:26 2016 +0300

----------------------------------------------------------------------
 .../cache/transactions/TxDeadlockDetectionTest.java     | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ignite/blob/223708a8/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/transactions/TxDeadlockDetectionTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/transactions/TxDeadlockDetectionTest.java
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/transactions/TxDeadlockDetectionTest.java
index 87539b2..3d0beac 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/transactions/TxDeadlockDetectionTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/transactions/TxDeadlockDetectionTest.java
@@ -96,7 +96,7 @@ public class TxDeadlockDetectionTest extends GridCommonAbstractTest {
     @Override protected void beforeTestsStarted() throws Exception {
         super.beforeTestsStarted();
 
-        startGrids(NODES_CNT);
+        startGridsMultiThreaded(NODES_CNT);
     }
 
     /** {@inheritDoc} */
@@ -151,7 +151,7 @@ public class TxDeadlockDetectionTest extends GridCommonAbstractTest {
 
                         IgniteCache<Integer, Integer> cache = ignite.cache(CACHE);
 
-                        try (Transaction tx = ignite.transactions().txStart(PESSIMISTIC,
REPEATABLE_READ, 500, 0)) {
+                        try (Transaction tx = ignite.transactions().txStart(PESSIMISTIC,
REPEATABLE_READ, 700, 0)) {
                             ThreadLocalRandom8 rnd = ThreadLocalRandom8.current();
 
                             for (int i = 0; i < 50; i++) {
@@ -198,7 +198,7 @@ public class TxDeadlockDetectionTest extends GridCommonAbstractTest {
 
         final CyclicBarrier barrier = new CyclicBarrier(2);
 
-        final int timeout = 500;
+        final long timeout = 500;
 
         IgniteInternalFuture<Long> fut = GridTestUtils.runMultiThreadedAsync(new Runnable()
{
             @Override public void run() {
@@ -257,7 +257,7 @@ public class TxDeadlockDetectionTest extends GridCommonAbstractTest {
 
             final CyclicBarrier barrier = new CyclicBarrier(threads);
 
-            final int timeout = 500;
+            final long timeout = 500;
 
             IgniteInternalFuture<Long> fut = GridTestUtils.runMultiThreadedAsync(new
Runnable() {
                 @Override public void run() {
@@ -336,7 +336,7 @@ public class TxDeadlockDetectionTest extends GridCommonAbstractTest {
         try {
             final int txCnt = 2;
 
-            final CyclicBarrier barrier = new CyclicBarrier(2);
+            final CyclicBarrier barrier = new CyclicBarrier(txCnt);
 
             final AtomicInteger threadCnt = new AtomicInteger();
 
@@ -381,7 +381,7 @@ public class TxDeadlockDetectionTest extends GridCommonAbstractTest {
                         deadlock.compareAndSet(false, hasCause(e, TransactionDeadlockException.class));
                     }
                 }
-            }, 2, "tx-thread");
+            }, txCnt, "tx-thread");
 
             fut.get();
 


Mime
View raw message