ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From a.@apache.org
Subject [2/2] ignite git commit: 2224 Interceptor fix
Date Mon, 01 Feb 2016 08:37:20 GMT
2224 Interceptor fix


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

Branch: refs/heads/ignite-2224
Commit: eccbd0d80f38c22e4efda76223dfa20d714230fb
Parents: 8d99bb6
Author: Anton Vinogradov <av@apache.org>
Authored: Mon Feb 1 11:36:09 2016 +0300
Committer: Anton Vinogradov <av@apache.org>
Committed: Mon Feb 1 11:36:09 2016 +0300

----------------------------------------------------------------------
 .../ignite/internal/processors/cache/GridCacheAdapter.java       | 2 +-
 .../processors/cache/GridCacheInterceptorAbstractSelfTest.java   | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ignite/blob/eccbd0d8/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
index 1334554..52cc833 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
@@ -1405,7 +1405,7 @@ public abstract class GridCacheAdapter<K, V> implements IgniteInternalCache<K,
V
         if (ctx.config().getInterceptor() != null) {
             V val0 = (V)ctx.config().getInterceptor().onGet(key, t != null ? val.getValue()
: null);
 
-            val = new CacheEntryImplEx<>(key, val0, t != null ? t.get2() : null);
+            val = (val0 != null) ? new CacheEntryImplEx<>(key, val0, t != null ? t.get2()
: null) : null;
         }
 
         if (statsEnabled)

http://git-wip-us.apache.org/repos/asf/ignite/blob/eccbd0d8/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheInterceptorAbstractSelfTest.java
----------------------------------------------------------------------
diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheInterceptorAbstractSelfTest.java
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheInterceptorAbstractSelfTest.java
index fafe0fe..f50a3e0 100644
--- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheInterceptorAbstractSelfTest.java
+++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheInterceptorAbstractSelfTest.java
@@ -188,7 +188,7 @@ public abstract class GridCacheInterceptorAbstractSelfTest extends GridCacheAbst
 
         IgniteCache<String, Integer> cache = jcache(0);
 
-        assertEquals(null, needVer ? cache.getEntry(key).getValue() : cache.get(key));
+        assertEquals(null, needVer ? cache.getEntry(key) : cache.get(key));
 
         assertEquals(1, interceptor.invokeCnt.get());
 
@@ -222,7 +222,7 @@ public abstract class GridCacheInterceptorAbstractSelfTest extends GridCacheAbst
 
         log.info("Get 3.");
 
-        assertEquals(null, needVer ? cache.getEntry(key).getValue() : cache.get(key));
+        assertEquals(null, needVer ? cache.getEntry(key) : cache.get(key));
 
         assertEquals(1, interceptor.invokeCnt.get());
 


Mime
View raw message