ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From agoncha...@apache.org
Subject ignite git commit: IGNITE-950-new - Fixing keepBinary for data streamer and continuous queries.
Date Mon, 02 Nov 2015 14:55:03 GMT
Repository: ignite
Updated Branches:
  refs/heads/ignite-950-new 988fc0a24 -> 75340e0d1


IGNITE-950-new - Fixing keepBinary for data streamer and continuous queries.


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

Branch: refs/heads/ignite-950-new
Commit: 75340e0d1148244321a7fb559766e40f24c3eb7e
Parents: 988fc0a
Author: Alexey Goncharuk <alexey.goncharuk@gmail.com>
Authored: Mon Nov 2 17:54:47 2015 +0300
Committer: Alexey Goncharuk <alexey.goncharuk@gmail.com>
Committed: Mon Nov 2 17:54:47 2015 +0300

----------------------------------------------------------------------
 .../internal/processors/affinity/GridAffinityProcessor.java     | 5 +++--
 .../cache/query/continuous/CacheContinuousQueryEvent.java       | 3 +--
 2 files changed, 4 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ignite/blob/75340e0d/modules/core/src/main/java/org/apache/ignite/internal/processors/affinity/GridAffinityProcessor.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/affinity/GridAffinityProcessor.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/affinity/GridAffinityProcessor.java
index 8f66dc1..6c82585 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/affinity/GridAffinityProcessor.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/affinity/GridAffinityProcessor.java
@@ -38,6 +38,7 @@ import org.apache.ignite.cluster.ClusterNode;
 import org.apache.ignite.configuration.CacheConfiguration;
 import org.apache.ignite.events.DiscoveryEvent;
 import org.apache.ignite.events.Event;
+import org.apache.ignite.igniteobject.IgniteObject;
 import org.apache.ignite.internal.GridKernalContext;
 import org.apache.ignite.internal.IgniteInternalFuture;
 import org.apache.ignite.internal.managers.eventstorage.GridLocalEventListener;
@@ -497,7 +498,7 @@ public class GridAffinityProcessor extends GridProcessorAdapter {
      * @throws IgniteCheckedException In case of error.
      */
     private <K> ClusterNode primary(AffinityInfo aff, K key) throws IgniteCheckedException
{
-        if (key instanceof CacheObject)
+        if (key instanceof CacheObject && !(key instanceof IgniteObject))
             key = ((CacheObject)key).value(aff.cacheObjCtx, false);
 
         int part = aff.affFunc.partition(aff.mapper.affinityKey(key));
@@ -516,7 +517,7 @@ public class GridAffinityProcessor extends GridProcessorAdapter {
      * @return Primary and backup nodes.
      */
     private <K> List<ClusterNode> primaryAndBackups(AffinityInfo aff, K key)
{
-        if (key instanceof CacheObject)
+        if (key instanceof CacheObject && !(key instanceof IgniteObject))
             key = ((CacheObject) key).value(aff.cacheObjCtx, false);
 
         int part = aff.affFunc.partition(aff.mapper.affinityKey(key));

http://git-wip-us.apache.org/repos/asf/ignite/blob/75340e0d/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/continuous/CacheContinuousQueryEvent.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/continuous/CacheContinuousQueryEvent.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/continuous/CacheContinuousQueryEvent.java
index e95cd69..d26be5f 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/continuous/CacheContinuousQueryEvent.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/continuous/CacheContinuousQueryEvent.java
@@ -21,7 +21,6 @@ import javax.cache.Cache;
 import javax.cache.event.CacheEntryEvent;
 import org.apache.ignite.internal.processors.cache.GridCacheContext;
 import org.apache.ignite.internal.util.tostring.GridToStringExclude;
-import org.apache.ignite.internal.util.typedef.internal.CU;
 import org.apache.ignite.internal.util.typedef.internal.S;
 
 /**
@@ -65,7 +64,7 @@ class CacheContinuousQueryEvent<K, V> extends CacheEntryEvent<K,
V> {
 
     /** {@inheritDoc} */
     @Override public V getValue() {
-        return CU.value(e.value(), cctx, false);
+        return (V)cctx.cacheObjectContext().unwrapPortableIfNeeded(e.value(), true, false);
     }
 
     /** {@inheritDoc} */


Mime
View raw message