ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From agoncha...@apache.org
Subject [16/50] [abbrv] incubator-ignite git commit: # ignite-283: Method renamings.
Date Wed, 18 Feb 2015 19:43:06 GMT
# ignite-283: Method renamings.


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

Branch: refs/heads/ignite-285
Commit: eb2b1786efa6f261f70ec7aa610d8368b5b62f96
Parents: c5a15a1
Author: vozerov-gridgain <vozerov@gridgain.com>
Authored: Wed Feb 18 13:09:33 2015 +0300
Committer: vozerov-gridgain <vozerov@gridgain.com>
Committed: Wed Feb 18 13:09:33 2015 +0300

----------------------------------------------------------------------
 .../processors/cache/GridCacheAdapter.java      | 16 ++++++-----
 .../processors/cache/GridCacheMapEntry.java     |  6 ++--
 .../processors/cache/GridCacheProjectionEx.java |  8 +++---
 .../cache/GridCacheProjectionImpl.java          | 16 +++++------
 .../processors/cache/GridCacheProxyImpl.java    | 16 +++++------
 .../processors/cache/GridCacheUtils.java        | 30 ++++++++++++++------
 .../dht/atomic/GridDhtAtomicCache.java          | 12 ++++----
 .../distributed/near/GridNearAtomicCache.java   | 16 +++++------
 .../cache/version/GridCacheVersion.java         |  4 +--
 .../cache/version/GridCacheVersionEx.java       |  2 +-
 .../dr/GridDrDataLoadCacheUpdater.java          |  4 +--
 .../ignite/internal/util/IgniteUtils.java       |  2 +-
 12 files changed, 73 insertions(+), 59 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/eb2b1786/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 9d8f243..cba8b1c 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
@@ -2472,7 +2472,8 @@ public abstract class GridCacheAdapter<K, V> implements GridCache<K,
V>,
     }
 
     /** {@inheritDoc} */
-    @Override public void putAllDr(final Map<? extends K, GridCacheDrInfo<V>>
drMap) throws IgniteCheckedException {
+    @Override public void putAllConflict(final Map<? extends K, GridCacheDrInfo<V>>
drMap)
+        throws IgniteCheckedException {
         if (F.isEmpty(drMap))
             return;
 
@@ -2486,13 +2487,13 @@ public abstract class GridCacheAdapter<K, V> implements GridCache<K,
V>,
             }
 
             @Override public String toString() {
-                return "putAllDr [drMap=" + drMap + ']';
+                return "putAllConflict [drMap=" + drMap + ']';
             }
         });
     }
 
     /** {@inheritDoc} */
-    @Override public IgniteInternalFuture<?> putAllDrAsync(final Map<? extends K,
GridCacheDrInfo<V>> drMap)
+    @Override public IgniteInternalFuture<?> putAllConflictAsync(final Map<? extends
K, GridCacheDrInfo<V>> drMap)
         throws IgniteCheckedException {
         if (F.isEmpty(drMap))
             return new GridFinishedFuture<Object>(ctx.kernalContext());
@@ -2507,7 +2508,7 @@ public abstract class GridCacheAdapter<K, V> implements GridCache<K,
V>,
             }
 
             @Override public String toString() {
-                return "putAllDrAsync [drMap=" + drMap + ']';
+                return "putAllConflictAsync [drMap=" + drMap + ']';
             }
         });
     }
@@ -3379,7 +3380,8 @@ public abstract class GridCacheAdapter<K, V> implements GridCache<K,
V>,
     }
 
     /** {@inheritDoc} */
-    @Override public void removeAllDr(final Map<? extends K, GridCacheVersion> drMap)
throws IgniteCheckedException {
+    @Override public void removeAllConflict(final Map<? extends K, GridCacheVersion>
drMap)
+        throws IgniteCheckedException {
         ctx.denyOnLocalRead();
 
         if (F.isEmpty(drMap))
@@ -3393,13 +3395,13 @@ public abstract class GridCacheAdapter<K, V> implements GridCache<K,
V>,
             }
 
             @Override public String toString() {
-                return "removeAllDr [drMap=" + drMap + ']';
+                return "removeAllConflict [drMap=" + drMap + ']';
             }
         });
     }
 
     /** {@inheritDoc} */
-    @Override public IgniteInternalFuture<?> removeAllDrAsync(final Map<? extends
K, GridCacheVersion> drMap)
+    @Override public IgniteInternalFuture<?> removeAllConflictAsync(final Map<?
extends K, GridCacheVersion> drMap)
         throws IgniteCheckedException {
         ctx.denyOnLocalRead();
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/eb2b1786/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
index dc0fa59..dcdc0d9 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMapEntry.java
@@ -1607,7 +1607,7 @@ public abstract class GridCacheMapEntry<K, V> implements GridCacheEntryEx<K,
V>
             Object transformClo = null;
 
             if (drResolve) {
-                GridCacheVersion oldDrVer = version().drVersion();
+                GridCacheVersion oldDrVer = version().conflictVersion();
 
                 boolean drNeedResolve = cctx.conflictNeedResolve(oldDrVer, drVer);
 
@@ -2149,7 +2149,7 @@ public abstract class GridCacheMapEntry<K, V> implements GridCacheEntryEx<K,
V>
     private void drReplicate(GridDrType drType, @Nullable V val, @Nullable byte[] valBytes,
GridCacheVersion ver)
         throws IgniteCheckedException {
         if (cctx.isDrEnabled() && drType != DR_NONE && !isInternal())
-            cctx.dr().replicate(key, keyBytes, val, valBytes, rawTtl(), rawExpireTime(),
ver.drVersion(), drType);
+            cctx.dr().replicate(key, keyBytes, val, valBytes, rawTtl(), rawExpireTime(),
ver.conflictVersion(), drType);
     }
 
     /**
@@ -3180,7 +3180,7 @@ public abstract class GridCacheMapEntry<K, V> implements GridCacheEntryEx<K,
V>
         boolean isNew = isStartVersion();
 
         return new GridCachePlainVersionedEntry<>(key, isNew ? unswap(true, true) :
rawGetOrUnmarshalUnlocked(false),
-            ttlExtras(), expireTimeExtras(), ver.drVersion(), isNew);
+            ttlExtras(), expireTimeExtras(), ver.conflictVersion(), isNew);
     }
 
     /** {@inheritDoc} */

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/eb2b1786/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProjectionEx.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProjectionEx.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProjectionEx.java
index 4e93122..7cb3de5 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProjectionEx.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProjectionEx.java
@@ -112,7 +112,7 @@ public interface GridCacheProjectionEx<K, V> extends CacheProjection<K,
V> {
      * @throws IgniteCheckedException If put operation failed.
      * @throws CacheFlagException If projection flags validation failed.
      */
-    public void putAllDr(Map<? extends K, GridCacheDrInfo<V>> drMap) throws IgniteCheckedException;
+    public void putAllConflict(Map<? extends K, GridCacheDrInfo<V>> drMap) throws
IgniteCheckedException;
 
     /**
      * Store DR data asynchronously.
@@ -122,7 +122,7 @@ public interface GridCacheProjectionEx<K, V> extends CacheProjection<K,
V> {
      * @throws IgniteCheckedException If put operation failed.
      * @throws CacheFlagException If projection flags validation failed.
      */
-    public IgniteInternalFuture<?> putAllDrAsync(Map<? extends K, GridCacheDrInfo<V>>
drMap) throws IgniteCheckedException;
+    public IgniteInternalFuture<?> putAllConflictAsync(Map<? extends K, GridCacheDrInfo<V>>
drMap) throws IgniteCheckedException;
 
     /**
      * Internal method that is called from {@link GridCacheEntryImpl}.
@@ -154,7 +154,7 @@ public interface GridCacheProjectionEx<K, V> extends CacheProjection<K,
V> {
      * @throws IgniteCheckedException If remove failed.
      * @throws CacheFlagException If projection flags validation failed.
      */
-    public void removeAllDr(Map<? extends K, GridCacheVersion> drMap) throws IgniteCheckedException;
+    public void removeAllConflict(Map<? extends K, GridCacheVersion> drMap) throws
IgniteCheckedException;
 
     /**
      * Removes DR data asynchronously.
@@ -164,7 +164,7 @@ public interface GridCacheProjectionEx<K, V> extends CacheProjection<K,
V> {
      * @throws IgniteCheckedException If remove failed.
      * @throws CacheFlagException If projection flags validation failed.
      */
-    public IgniteInternalFuture<?> removeAllDrAsync(Map<? extends K, GridCacheVersion>
drMap) throws IgniteCheckedException;
+    public IgniteInternalFuture<?> removeAllConflictAsync(Map<? extends K, GridCacheVersion>
drMap) throws IgniteCheckedException;
 
     /**
      * Internal method that is called from {@link GridCacheEntryImpl}.

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/eb2b1786/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProjectionImpl.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProjectionImpl.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProjectionImpl.java
index eb854d5..041d222 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProjectionImpl.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProjectionImpl.java
@@ -794,14 +794,14 @@ public class GridCacheProjectionImpl<K, V> implements GridCacheProjectionEx<K,
V
     }
 
     /** {@inheritDoc} */
-    @Override public void putAllDr(Map<? extends K, GridCacheDrInfo<V>> drMap)
throws IgniteCheckedException {
-        cache.putAllDr(drMap);
+    @Override public void putAllConflict(Map<? extends K, GridCacheDrInfo<V>>
drMap) throws IgniteCheckedException {
+        cache.putAllConflict(drMap);
     }
 
     /** {@inheritDoc} */
-    @Override public IgniteInternalFuture<?> putAllDrAsync(Map<? extends K, GridCacheDrInfo<V>>
drMap)
+    @Override public IgniteInternalFuture<?> putAllConflictAsync(Map<? extends K,
GridCacheDrInfo<V>> drMap)
         throws IgniteCheckedException {
-        return cache.putAllDrAsync(drMap);
+        return cache.putAllConflictAsync(drMap);
     }
 
     /** {@inheritDoc} */
@@ -1130,13 +1130,13 @@ public class GridCacheProjectionImpl<K, V> implements GridCacheProjectionEx<K,
V
     }
 
     /** {@inheritDoc} */
-    @Override public void removeAllDr(Map<? extends K, GridCacheVersion> drMap) throws
IgniteCheckedException {
-        cache.removeAllDr(drMap);
+    @Override public void removeAllConflict(Map<? extends K, GridCacheVersion> drMap)
throws IgniteCheckedException {
+        cache.removeAllConflict(drMap);
     }
 
     /** {@inheritDoc} */
-    @Override public IgniteInternalFuture<?> removeAllDrAsync(Map<? extends K, GridCacheVersion>
drMap) throws IgniteCheckedException {
-        return cache.removeAllDrAsync(drMap);
+    @Override public IgniteInternalFuture<?> removeAllConflictAsync(Map<? extends
K, GridCacheVersion> drMap) throws IgniteCheckedException {
+        return cache.removeAllConflictAsync(drMap);
     }
 
     /** {@inheritDoc} */

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/eb2b1786/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProxyImpl.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProxyImpl.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProxyImpl.java
index 2a653af..2fc59b9 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProxyImpl.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProxyImpl.java
@@ -738,11 +738,11 @@ public class GridCacheProxyImpl<K, V> implements GridCacheProxy<K,
V>, Externali
     }
 
     /** {@inheritDoc} */
-    @Override public void putAllDr(Map<? extends K, GridCacheDrInfo<V>> drMap)
throws IgniteCheckedException {
+    @Override public void putAllConflict(Map<? extends K, GridCacheDrInfo<V>>
drMap) throws IgniteCheckedException {
         GridCacheProjectionImpl<K, V> prev = gate.enter(prj);
 
         try {
-            delegate.putAllDr(drMap);
+            delegate.putAllConflict(drMap);
         }
         finally {
             gate.leave(prev);
@@ -750,12 +750,12 @@ public class GridCacheProxyImpl<K, V> implements GridCacheProxy<K,
V>, Externali
     }
 
     /** {@inheritDoc} */
-    @Override public IgniteInternalFuture<?> putAllDrAsync(Map<? extends K, GridCacheDrInfo<V>>
drMap)
+    @Override public IgniteInternalFuture<?> putAllConflictAsync(Map<? extends K,
GridCacheDrInfo<V>> drMap)
         throws IgniteCheckedException {
         GridCacheProjectionImpl<K, V> prev = gate.enter(prj);
 
         try {
-            return delegate.putAllDrAsync(drMap);
+            return delegate.putAllConflictAsync(drMap);
         }
         finally {
             gate.leave(prev);
@@ -1454,11 +1454,11 @@ public class GridCacheProxyImpl<K, V> implements GridCacheProxy<K,
V>, Externali
     }
 
     /** {@inheritDoc} */
-    @Override public void removeAllDr(Map<? extends K, GridCacheVersion> drMap) throws
IgniteCheckedException {
+    @Override public void removeAllConflict(Map<? extends K, GridCacheVersion> drMap)
throws IgniteCheckedException {
         GridCacheProjectionImpl<K, V> prev = gate.enter(prj);
 
         try {
-            delegate.removeAllDr(drMap);
+            delegate.removeAllConflict(drMap);
         }
         finally {
             gate.leave(prev);
@@ -1466,11 +1466,11 @@ public class GridCacheProxyImpl<K, V> implements GridCacheProxy<K,
V>, Externali
     }
 
     /** {@inheritDoc} */
-    @Override public IgniteInternalFuture<?> removeAllDrAsync(Map<? extends K, GridCacheVersion>
drMap) throws IgniteCheckedException {
+    @Override public IgniteInternalFuture<?> removeAllConflictAsync(Map<? extends
K, GridCacheVersion> drMap) throws IgniteCheckedException {
         GridCacheProjectionImpl<K, V> prev = gate.enter(prj);
 
         try {
-            return delegate.removeAllDrAsync(drMap);
+            return delegate.removeAllConflictAsync(drMap);
         }
         finally {
             gate.leave(prev);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/eb2b1786/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
index a3a5b20..9cd075c 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheUtils.java
@@ -74,12 +74,24 @@ public class GridCacheUtils {
     /** Peek flags. */
     private static final GridCachePeekMode[] PEEK_FLAGS = new GridCachePeekMode[] { GLOBAL,
SWAP };
 
-    /** */
+    /** TTL: minimum positive value. */
+    public static final long TTL_MINIMUM = 1L;
+
+    /** TTL: eternal. */
+    public static final long TTL_ETERNAL = 0L;
+
+    /** TTL: not changed. */
     public static final long TTL_NOT_CHANGED = -1L;
 
-    /** */
+    /** TTL: zero (immediate expiration). */
     public static final long TTL_ZERO = -2L;
 
+    /** Expire time: eternal. */
+    public static final long EXPIRE_TIME_ETERNAL = 0L;
+
+    /** Expire time: must be calculated based on TTL value. */
+    public static final long EXPIRE_TIME_CALCULATE = -1L;
+
     /** Per-thread generated UID store. */
     private static final ThreadLocal<String> UUIDS = new ThreadLocal<String>()
{
         @Override protected String initialValue() {
@@ -1602,15 +1614,15 @@ public class GridCacheUtils {
      * @return Expire time.
      */
     public static long toExpireTime(long ttl) {
-        assert ttl >= 0L : ttl;
+        assert ttl != CU.TTL_ZERO && ttl != CU.TTL_NOT_CHANGED && ttl >=
0;
 
-        if (ttl == 0L)
-            return 0L;
-        else {
-            long expireTime = U.currentTimeMillis() + ttl;
+        long expireTime = ttl == CU.TTL_ETERNAL ? CU.EXPIRE_TIME_ETERNAL : U.currentTimeMillis()
+ ttl;
 
-            return expireTime > 0L ? expireTime : 0L;
-        }
+        // Account for overflow.
+        if (expireTime < 0)
+            expireTime = CU.EXPIRE_TIME_ETERNAL;
+
+        return expireTime;
     }
 
     /**

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/eb2b1786/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/atomic/GridDhtAtomicCache.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/atomic/GridDhtAtomicCache.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/atomic/GridDhtAtomicCache.java
index b90d78e..995e419 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/atomic/GridDhtAtomicCache.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/atomic/GridDhtAtomicCache.java
@@ -453,12 +453,12 @@ public class GridDhtAtomicCache<K, V> extends GridDhtCacheAdapter<K,
V> {
     }
 
     /** {@inheritDoc} */
-    @Override public void putAllDr(Map<? extends K, GridCacheDrInfo<V>> drMap)
throws IgniteCheckedException {
-        putAllDrAsync(drMap).get();
+    @Override public void putAllConflict(Map<? extends K, GridCacheDrInfo<V>>
drMap) throws IgniteCheckedException {
+        putAllConflictAsync(drMap).get();
     }
 
     /** {@inheritDoc} */
-    @Override public IgniteInternalFuture<?> putAllDrAsync(Map<? extends K, GridCacheDrInfo<V>>
drMap) {
+    @Override public IgniteInternalFuture<?> putAllConflictAsync(Map<? extends K,
GridCacheDrInfo<V>> drMap) {
         ctx.dr().onReceiveCacheEntriesReceived(drMap.size());
 
         return updateAllAsync0(null,
@@ -534,12 +534,12 @@ public class GridDhtAtomicCache<K, V> extends GridDhtCacheAdapter<K,
V> {
     }
 
     /** {@inheritDoc} */
-    @Override public void removeAllDr(Map<? extends K, GridCacheVersion> drMap) throws
IgniteCheckedException {
-        removeAllDrAsync(drMap).get();
+    @Override public void removeAllConflict(Map<? extends K, GridCacheVersion> drMap)
throws IgniteCheckedException {
+        removeAllConflictAsync(drMap).get();
     }
 
     /** {@inheritDoc} */
-    @Override public IgniteInternalFuture<?> removeAllDrAsync(Map<? extends K, GridCacheVersion>
drMap) {
+    @Override public IgniteInternalFuture<?> removeAllConflictAsync(Map<? extends
K, GridCacheVersion> drMap) {
         ctx.dr().onReceiveCacheEntriesReceived(drMap.size());
 
         return removeAllAsync0(null, drMap, null, false, false, null);

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/eb2b1786/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearAtomicCache.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearAtomicCache.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearAtomicCache.java
index f409e94..9530b98 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearAtomicCache.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearAtomicCache.java
@@ -526,13 +526,13 @@ public class GridNearAtomicCache<K, V> extends GridNearCacheAdapter<K,
V> {
     }
 
     /** {@inheritDoc} */
-    @Override public void putAllDr(Map<? extends K, GridCacheDrInfo<V>> drMap)
throws IgniteCheckedException {
-        dht.putAllDr(drMap);
+    @Override public void putAllConflict(Map<? extends K, GridCacheDrInfo<V>>
drMap) throws IgniteCheckedException {
+        dht.putAllConflict(drMap);
     }
 
     /** {@inheritDoc} */
-    @Override public IgniteInternalFuture<?> putAllDrAsync(Map<? extends K, GridCacheDrInfo<V>>
drMap) throws IgniteCheckedException {
-        return dht.putAllDrAsync(drMap);
+    @Override public IgniteInternalFuture<?> putAllConflictAsync(Map<? extends K,
GridCacheDrInfo<V>> drMap) throws IgniteCheckedException {
+        return dht.putAllConflictAsync(drMap);
     }
 
     /** {@inheritDoc} */
@@ -645,13 +645,13 @@ public class GridNearAtomicCache<K, V> extends GridNearCacheAdapter<K,
V> {
     }
 
     /** {@inheritDoc} */
-    @Override public void removeAllDr(Map<? extends K, GridCacheVersion> drMap) throws
IgniteCheckedException {
-        dht.removeAllDr(drMap);
+    @Override public void removeAllConflict(Map<? extends K, GridCacheVersion> drMap)
throws IgniteCheckedException {
+        dht.removeAllConflict(drMap);
     }
 
     /** {@inheritDoc} */
-    @Override public IgniteInternalFuture<?> removeAllDrAsync(Map<? extends K, GridCacheVersion>
drMap) throws IgniteCheckedException {
-        return dht.removeAllDrAsync(drMap);
+    @Override public IgniteInternalFuture<?> removeAllConflictAsync(Map<? extends
K, GridCacheVersion> drMap) throws IgniteCheckedException {
+        return dht.removeAllConflictAsync(drMap);
     }
 
     /** {@inheritDoc} */

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/eb2b1786/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/version/GridCacheVersion.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/version/GridCacheVersion.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/version/GridCacheVersion.java
index 53e43e2..b706e92 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/version/GridCacheVersion.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/version/GridCacheVersion.java
@@ -149,9 +149,9 @@ public class GridCacheVersion extends MessageAdapter implements Comparable<GridC
     }
 
     /**
-     * @return DR version.
+     * @return Conflict version.
      */
-    @Nullable public GridCacheVersion drVersion() {
+    @Nullable public GridCacheVersion conflictVersion() {
         return this; // Use current version.
     }
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/eb2b1786/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/version/GridCacheVersionEx.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/version/GridCacheVersionEx.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/version/GridCacheVersionEx.java
index 8c95b9b..4f135ca 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/version/GridCacheVersionEx.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/version/GridCacheVersionEx.java
@@ -77,7 +77,7 @@ public class GridCacheVersionEx extends GridCacheVersion {
     }
 
     /** {@inheritDoc} */
-    @Override public GridCacheVersion drVersion() {
+    @Override public GridCacheVersion conflictVersion() {
         return drVer;
     }
 

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/eb2b1786/modules/core/src/main/java/org/apache/ignite/internal/processors/dr/GridDrDataLoadCacheUpdater.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/dr/GridDrDataLoadCacheUpdater.java
b/modules/core/src/main/java/org/apache/ignite/internal/processors/dr/GridDrDataLoadCacheUpdater.java
index 2cc97da..ed43149 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/processors/dr/GridDrDataLoadCacheUpdater.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/dr/GridDrDataLoadCacheUpdater.java
@@ -66,9 +66,9 @@ public class GridDrDataLoadCacheUpdater<K, V> implements IgniteDataLoader.Update
                     new GridCacheDrInfo<>(entry.value(), entry.version()) : null;
 
                 if (val == null)
-                    cache.removeAllDr(Collections.singletonMap(key, entry.version()));
+                    cache.removeAllConflict(Collections.singletonMap(key, entry.version()));
                 else
-                    cache.putAllDr(Collections.singletonMap(key, val));
+                    cache.putAllConflict(Collections.singletonMap(key, val));
             }
 
             if (log.isDebugEnabled())

http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/eb2b1786/modules/core/src/main/java/org/apache/ignite/internal/util/IgniteUtils.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/util/IgniteUtils.java b/modules/core/src/main/java/org/apache/ignite/internal/util/IgniteUtils.java
index 103b0ad..5db0da4 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/util/IgniteUtils.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/util/IgniteUtils.java
@@ -8813,7 +8813,7 @@ public abstract class IgniteUtils {
         UNSAFE.putBoolean(arr, off++, verEx);
 
         if (verEx) {
-            GridCacheVersion drVer = ver.drVersion();
+            GridCacheVersion drVer = ver.conflictVersion();
 
             assert drVer != null;
 


Mime
View raw message