ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From agoncha...@apache.org
Subject [2/3] incubator-ignite git commit: Ignite - More fixes for tests.
Date Sat, 06 Dec 2014 01:05:54 GMT
Ignite - More fixes for tests.


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

Branch: refs/heads/master
Commit: 1021f373b0faa91c88ab13457c8e8668ba5b48f6
Parents: ab6275c
Author: Alexey Goncharuk <agoncharuk@gridgain.com>
Authored: Fri Dec 5 17:01:40 2014 -0800
Committer: Alexey Goncharuk <agoncharuk@gridgain.com>
Committed: Fri Dec 5 17:01:40 2014 -0800

----------------------------------------------------------------------
 .../cache/distributed/dht/GridDhtTxPrepareFuture.java     |  5 ++++-
 .../cache/distributed/near/GridNearTxLocal.java           |  2 ++
 .../cache/GridCacheTxExceptionAbstractSelfTest.java       |  8 ++++----
 .../gridgain/testsuites/bamboo/GridDataGridTestSuite.java | 10 +++++-----
 4 files changed, 15 insertions(+), 10 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/1021f373/modules/core/src/main/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
b/modules/core/src/main/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
index 40d2593..8cee847 100644
--- a/modules/core/src/main/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
+++ b/modules/core/src/main/java/org/gridgain/grid/kernal/processors/cache/distributed/dht/GridDhtTxPrepareFuture.java
@@ -426,6 +426,8 @@ public final class GridDhtTxPrepareFuture<K, V> extends GridCompoundIdentityFutu
             for (GridCacheTxEntry<K, V> e : writes) {
                 GridCacheTxEntry<K, V> txEntry = tx.entry(e.txKey());
 
+                assert txEntry != null : "Missing tx entry for key [tx=" + tx + ", key="
+ e.txKey() + ']';
+
                 while (true) {
                     try {
                         GridCacheEntryEx<K, V> entry = txEntry.cached();
@@ -446,7 +448,8 @@ public final class GridDhtTxPrepareFuture<K, V> extends GridCompoundIdentityFutu
                         else
                             val0 = entry.rawGet();
 
-                        res.addOwnedValue(txEntry.txKey(), dhtVer, val0, valBytes0);
+                        if (val0 != null || valBytes0 != null)
+                            res.addOwnedValue(txEntry.txKey(), dhtVer, val0, valBytes0);
 
                         break;
                     }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/1021f373/modules/core/src/main/java/org/gridgain/grid/kernal/processors/cache/distributed/near/GridNearTxLocal.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/gridgain/grid/kernal/processors/cache/distributed/near/GridNearTxLocal.java
b/modules/core/src/main/java/org/gridgain/grid/kernal/processors/cache/distributed/near/GridNearTxLocal.java
index e29d78a..eb006fa 100644
--- a/modules/core/src/main/java/org/gridgain/grid/kernal/processors/cache/distributed/near/GridNearTxLocal.java
+++ b/modules/core/src/main/java/org/gridgain/grid/kernal/processors/cache/distributed/near/GridNearTxLocal.java
@@ -621,6 +621,8 @@ public class GridNearTxLocal<K, V> extends GridDhtTxLocalAdapter<K,
V> {
             if (!isRollbackOnly()) {
                 invalidate = true;
 
+                systemInvalidate(true);
+
                 U.warn(log, "Set transaction invalidation flag to true due to error [tx="
+ this + ", err=" + err + ']');
             }
         }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/1021f373/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheTxExceptionAbstractSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheTxExceptionAbstractSelfTest.java
b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheTxExceptionAbstractSelfTest.java
index 5e2f6c2..c156c86 100644
--- a/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheTxExceptionAbstractSelfTest.java
+++ b/modules/core/src/test/java/org/gridgain/grid/kernal/processors/cache/GridCacheTxExceptionAbstractSelfTest.java
@@ -341,8 +341,8 @@ public abstract class GridCacheTxExceptionAbstractSelfTest extends GridCacheAbst
             log.info("Entry: " + entry);
 
             if (entry != null) {
-                assertFalse("Unexpected entry for grid " + i, entry.lockedByAny());
-                assertFalse("Unexpected entry for grid " + i, entry.hasValue());
+                assertFalse("Unexpected entry for grid [i=" + i + ", entry=" + entry + ']',
entry.lockedByAny());
+                assertFalse("Unexpected entry for grid [i=" + i + ", entry=" + entry + ']',
entry.hasValue());
             }
 
             if (cache.isNear()) {
@@ -351,8 +351,8 @@ public abstract class GridCacheTxExceptionAbstractSelfTest extends GridCacheAbst
                 log.info("Dht entry: " + entry);
 
                 if (entry != null) {
-                    assertFalse("Unexpected entry for grid " + i, entry.lockedByAny());
-                    assertFalse("Unexpected entry for grid " + i, entry.hasValue());
+                    assertFalse("Unexpected entry for grid [i=" + i + ", entry=" + entry
+ ']', entry.lockedByAny());
+                    assertFalse("Unexpected entry for grid [i=" + i + ", entry=" + entry
+ ']', entry.hasValue());
                 }
             }
         }

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/1021f373/modules/core/src/test/java/org/gridgain/testsuites/bamboo/GridDataGridTestSuite.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/gridgain/testsuites/bamboo/GridDataGridTestSuite.java
b/modules/core/src/test/java/org/gridgain/testsuites/bamboo/GridDataGridTestSuite.java
index 7dfbded..22ae0a7 100644
--- a/modules/core/src/test/java/org/gridgain/testsuites/bamboo/GridDataGridTestSuite.java
+++ b/modules/core/src/test/java/org/gridgain/testsuites/bamboo/GridDataGridTestSuite.java
@@ -59,7 +59,7 @@ public class GridDataGridTestSuite extends TestSuite {
         suite.addTestSuite(GridCacheAffinityApiSelfTest.class);
         suite.addTestSuite(GridCacheStoreValueBytesSelfTest.class);
         //suite.addTestSuite(GridDataLoaderProcessorSelfTest.class); TODO GG-9141
-        //suite.addTestSuite(GridDataLoaderImplSelfTest.class); TODO GG-9141
+        suite.addTestSuite(GridDataLoaderImplSelfTest.class);
         suite.addTestSuite(GridCacheEntryMemorySizeSelfTest.class);
         suite.addTestSuite(GridCacheClearAllSelfTest.class);
         suite.addTestSuite(GridCacheGlobalClearAllSelfTest.class);
@@ -68,20 +68,20 @@ public class GridDataGridTestSuite extends TestSuite {
         suite.addTestSuite(GridCacheGetStoreErrorSelfTest.class);
         suite.addTestSuite(GridCacheAsyncOperationsLimitSelfTest.class);
         suite.addTestSuite(GridCacheTtlManagerSelfTest.class);
-//        suite.addTestSuite(GridCacheLifecycleAwareSelfTest.class);
+        suite.addTestSuite(GridCacheLifecycleAwareSelfTest.class);
         suite.addTestSuite(GridCacheStopSelfTest.class);
         suite.addTestSuite(GridCacheAtomicNearCacheSelfTest.class);
         suite.addTestSuite(GridCacheStorePutxSelfTest.class);
         suite.addTestSuite(GridCacheOffHeapMultiThreadedUpdateSelfTest.class);
         suite.addTestSuite(GridCacheOffHeapAtomicMultiThreadedUpdateSelfTest.class);
-//        suite.addTestSuite(GridCacheColocatedTxExceptionSelfTest.class);
-//        suite.addTestSuite(GridCacheReplicatedTxExceptionSelfTest.class);
+        suite.addTestSuite(GridCacheColocatedTxExceptionSelfTest.class);
+        suite.addTestSuite(GridCacheReplicatedTxExceptionSelfTest.class);
 //        suite.addTestSuite(GridCacheLocalTxExceptionSelfTest.class);
         suite.addTestSuite(GridCacheNearTxExceptionSelfTest.class);
         suite.addTestSuite(GridCacheColocatedTxStoreExceptionSelfTest.class);
         suite.addTestSuite(GridCacheReplicatedTxStoreExceptionSelfTest.class);
 //        suite.addTestSuite(GridCacheLocalTxStoreExceptionSelfTest.class);
-//        suite.addTestSuite(GridCacheNearTxStoreExceptionSelfTest.class);
+        suite.addTestSuite(GridCacheNearTxStoreExceptionSelfTest.class);
         suite.addTestSuite(GridCacheMissingCommitVersionSelfTest.class);
         suite.addTestSuite(GridCacheEntrySetIterationPreloadingSelfTest.class);
 //        suite.addTestSuite(GridCacheMixedPartitionExchangeSelfTest.class);


Mime
View raw message