From 3fa39edf25a599d2d6db88060a8ab539d0562114 Mon Sep 17 00:00:00 2001 From: "Andrey V. Mashenkov" Date: Wed, 22 Aug 2018 14:27:34 +0300 Subject: [PATCH 1/6] IGNITE-9290: WIP. Code cleanup. --- .../cache/CacheEvictionManager.java | 6 ++---- .../cache/CacheOffheapEvictionManager.java | 5 ++--- .../processors/cache/GridCacheAdapter.java | 19 +++++++++---------- .../cache/GridCacheConcurrentMapImpl.java | 2 +- .../processors/cache/GridCacheEntryEx.java | 3 +-- .../cache/GridCacheEvictionManager.java | 3 +-- .../processors/cache/GridCacheMapEntry.java | 6 +++--- .../cache/GridCacheMvccManager.java | 3 +-- .../processors/cache/GridCacheTtlManager.java | 2 +- .../processors/cache/GridCacheUtils.java | 4 +--- .../distributed/dht/GridDhtCacheAdapter.java | 6 +++--- .../distributed/dht/GridDhtGetFuture.java | 2 +- .../dht/GridDhtGetSingleFuture.java | 2 +- .../dht/GridDhtTransactionalCacheAdapter.java | 4 ++-- .../dht/GridPartitionedGetFuture.java | 2 +- .../dht/GridPartitionedSingleGetFuture.java | 2 +- .../dht/atomic/GridDhtAtomicCache.java | 6 +++--- .../dht/colocated/GridDhtColocatedCache.java | 2 +- .../preloader/GridDhtPartitionDemander.java | 4 ++-- .../distributed/near/GridNearAtomicCache.java | 2 +- .../distributed/near/GridNearGetFuture.java | 6 +++--- .../near/GridNearTransactionalCache.java | 6 +++--- .../distributed/near/GridNearTxLocal.java | 10 +++++----- .../cache/local/GridLocalCache.java | 2 +- .../local/atomic/GridLocalAtomicCache.java | 8 ++++---- .../cache/query/GridCacheQueryManager.java | 2 +- .../datastreamer/DataStreamerImpl.java | 2 +- .../schema/SchemaIndexCacheVisitorImpl.java | 3 +-- .../CacheEntryProcessorCopySelfTest.java | 3 +-- .../GridCacheAbstractFullApiSelfTest.java | 2 +- .../cache/GridCacheTestEntryEx.java | 4 ++-- ...gniteCacheConfigVariationsFullApiTest.java | 2 +- ...teCacheClientNodeChangingTopologyTest.java | 2 +- .../dht/GridCacheTxNodeFailureSelfTest.java | 2 +- 34 files changed, 64 insertions(+), 75 deletions(-) diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheEvictionManager.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheEvictionManager.java index b614728f25946..2a9a0e8b10d76 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheEvictionManager.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheEvictionManager.java @@ -19,7 +19,6 @@ import java.util.Collection; import org.apache.ignite.IgniteCheckedException; -import org.apache.ignite.internal.processors.affinity.AffinityTopologyVersion; import org.apache.ignite.internal.processors.cache.transactions.IgniteTxEntry; import org.apache.ignite.internal.processors.cache.version.GridCacheVersion; import org.jetbrains.annotations.Nullable; @@ -35,10 +34,9 @@ public interface CacheEvictionManager extends GridCacheManager { public void touch(IgniteTxEntry txEntry, boolean loc); /** - * @param e Entry for eviction policy notification. - * @param topVer Topology version. + * @param e Entry for eviction policy notification. */ - public void touch(GridCacheEntryEx e, AffinityTopologyVersion topVer); + public void touch(GridCacheEntryEx e); /** * @param entry Entry to attempt to evict. diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheOffheapEvictionManager.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheOffheapEvictionManager.java index d737c8bfca328..6813fec446d9e 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheOffheapEvictionManager.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheOffheapEvictionManager.java @@ -19,7 +19,6 @@ import java.util.Collection; import org.apache.ignite.IgniteCheckedException; -import org.apache.ignite.internal.processors.affinity.AffinityTopologyVersion; import org.apache.ignite.internal.processors.cache.transactions.IgniteTxEntry; import org.apache.ignite.internal.processors.cache.version.GridCacheVersion; import org.apache.ignite.internal.processors.cache.version.GridCacheVersionManager; @@ -32,11 +31,11 @@ public class CacheOffheapEvictionManager extends GridCacheManagerAdapter implements CacheEvictionManager { /** {@inheritDoc} */ @Override public void touch(IgniteTxEntry txEntry, boolean loc) { - touch(txEntry.cached(), null); + touch(txEntry.cached()); } /** {@inheritDoc} */ - @Override public void touch(GridCacheEntryEx e, AffinityTopologyVersion topVer) { + @Override public void touch(GridCacheEntryEx e) { if (e.detached()) return; 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 bc14c548af92b..0d98baf4a2d0f 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 @@ -138,7 +138,6 @@ import org.apache.ignite.plugin.security.SecurityPermission; import org.apache.ignite.resources.IgniteInstanceResource; import org.apache.ignite.resources.JobContextResource; -import org.apache.ignite.spi.discovery.tcp.internal.TcpDiscoveryNode; import org.apache.ignite.transactions.Transaction; import org.apache.ignite.transactions.TransactionConcurrency; import org.apache.ignite.transactions.TransactionIsolation; @@ -896,7 +895,7 @@ public String toString() { continue; } finally { - e.touch(null); + e.touch(); ctx.shared().database().checkpointReadUnlock(); } @@ -951,7 +950,7 @@ public String toString() { return e.peek(heap, offheap, AffinityTopologyVersion.NONE, plc); } finally { - e.touch(null); + e.touch(); } } @@ -2057,7 +2056,7 @@ else if (storeEnabled) readerArgs); if (res == null) - entry.touch(topVer); + entry.touch(); } } @@ -2072,7 +2071,7 @@ else if (storeEnabled) needVer); if (entry != null && (tx == null || (!tx.implicit() && tx.isolation() == READ_COMMITTED))) - entry.touch(topVer); + entry.touch(); if (keysSize == 1) // Safe to return because no locks are required in READ_COMMITTED mode. @@ -2154,7 +2153,7 @@ else if (storeEnabled) if (tx0 == null || (!tx0.implicit() && tx0.isolation() == READ_COMMITTED)) - entry.touch(topVer); + entry.touch(); break; } @@ -2197,7 +2196,7 @@ else if (storeEnabled) GridCacheEntryEx entry = peekEx(key); if (entry != null) - entry.touch(topVer); + entry.touch(); } } @@ -2227,7 +2226,7 @@ else if (storeEnabled) for (KeyCacheObject key0 : misses.keySet()) { GridCacheEntryEx entry = peekEx(key0); if (entry != null) - entry.touch(topVer); + entry.touch(); } } @@ -2288,7 +2287,7 @@ private void clearReservationsIfNeeded( entry.clearReserveForLoad(e.getValue().version()); if (needTouch) - entry.touch(topVer); + entry.touch(); } } } @@ -3635,7 +3634,7 @@ private void loadEntry(KeyCacheObject key, log.debug("Got removed entry during loadCache (will ignore): " + entry); } finally { - entry.touch(topVer); + entry.touch(); } CU.unwindEvicts(ctx); diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheConcurrentMapImpl.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheConcurrentMapImpl.java index 75c0d0cde8c23..c390eb5275ed0 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheConcurrentMapImpl.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheConcurrentMapImpl.java @@ -201,7 +201,7 @@ protected final GridCacheMapEntry putEntryIfObsoleteOrAbsent( true); if (touch) - cur.touch(topVer); + cur.touch(); } assert Math.abs(sizeChange) <= 1; diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheEntryEx.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheEntryEx.java index 1445335cefda8..c5624ea5221b8 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheEntryEx.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheEntryEx.java @@ -1047,7 +1047,6 @@ public void updateIndex(SchemaIndexCacheFilter filter, SchemaIndexCacheVisitorCl /** * Touch this entry in its context's eviction manager. * - * @param topVer Topology version. */ - public void touch(AffinityTopologyVersion topVer); + public void touch(); } diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheEvictionManager.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheEvictionManager.java index e5ab189329aff..f7bfa3dab3610 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheEvictionManager.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheEvictionManager.java @@ -23,7 +23,6 @@ import org.apache.ignite.cache.eviction.EvictionFilter; import org.apache.ignite.cache.eviction.EvictionPolicy; import org.apache.ignite.configuration.CacheConfiguration; -import org.apache.ignite.internal.processors.affinity.AffinityTopologyVersion; import org.apache.ignite.internal.processors.cache.transactions.IgniteTxEntry; import org.apache.ignite.internal.processors.cache.version.GridCacheVersion; import org.apache.ignite.internal.processors.cache.version.GridCacheVersionManager; @@ -201,7 +200,7 @@ private boolean evict0( } /** {@inheritDoc} */ - @Override public void touch(GridCacheEntryEx e, AffinityTopologyVersion topVer) { + @Override public void touch(GridCacheEntryEx e) { assert e.context() == cctx : "Entry from another cache context passed to eviction manager: [" + "entry=" + e + ", cctx=" + cctx + 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 53c39459ee3f7..c7f68afd3931d 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 @@ -900,7 +900,7 @@ private EntryGetResult entryGetResult(CacheObject val, GridCacheVersion ver, boo } finally { if (touch) - touch(cctx.affinity().affinityTopologyVersion()); + touch(); } } @@ -4348,8 +4348,8 @@ private int extrasSize() { } /** {@inheritDoc} */ - @Override public void touch(AffinityTopologyVersion topVer) { - context().evicts().touch(this, topVer); + @Override public void touch() { + context().evicts().touch(this); } /** {@inheritDoc} */ diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMvccManager.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMvccManager.java index 690b15a8721df..4e7bd45d56120 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMvccManager.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMvccManager.java @@ -45,7 +45,6 @@ import org.apache.ignite.internal.processors.cache.distributed.GridCacheMappedVersion; import org.apache.ignite.internal.processors.cache.distributed.GridDistributedCacheEntry; import org.apache.ignite.internal.processors.cache.distributed.dht.GridDhtTxFinishFuture; -import org.apache.ignite.internal.processors.cache.distributed.near.GridNearTxFinishFuture; import org.apache.ignite.internal.processors.cache.transactions.IgniteInternalTx; import org.apache.ignite.internal.processors.cache.transactions.IgniteTxKey; import org.apache.ignite.internal.processors.cache.version.GridCacheVersion; @@ -360,7 +359,7 @@ public void removeExplicitNodeLocks(UUID leftNodeId, AffinityTopologyVersion top try { entry.removeExplicitNodeLocks(leftNodeId); - entry.touch(topVer); + entry.touch(); } catch (GridCacheEntryRemovedException ignore) { if (log.isDebugEnabled()) diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheTtlManager.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheTtlManager.java index 2166ce5eba935..1a887e24f55a1 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheTtlManager.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheTtlManager.java @@ -71,7 +71,7 @@ public class GridCacheTtlManager extends GridCacheManagerAdapter { } if (touch) - entry.touch(null); + entry.touch(); } }; 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 213fb2e33ccca..578b43cd0e3b6 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 @@ -64,7 +64,6 @@ import org.apache.ignite.internal.cluster.ClusterGroupEmptyCheckedException; import org.apache.ignite.internal.cluster.ClusterTopologyCheckedException; import org.apache.ignite.internal.cluster.ClusterTopologyServerNotFoundException; -import org.apache.ignite.internal.managers.discovery.IgniteClusterNode; import org.apache.ignite.internal.processors.affinity.AffinityTopologyVersion; import org.apache.ignite.internal.processors.cache.distributed.GridDistributedLockCancelledException; import org.apache.ignite.internal.processors.cache.distributed.dht.GridDhtCacheAdapter; @@ -99,7 +98,6 @@ import org.apache.ignite.lifecycle.LifecycleAware; import org.apache.ignite.plugin.CachePluginConfiguration; import org.apache.ignite.plugin.security.SecurityException; -import org.apache.ignite.spi.discovery.tcp.internal.TcpDiscoveryNode; import org.apache.ignite.transactions.Transaction; import org.apache.ignite.transactions.TransactionConcurrency; import org.apache.ignite.transactions.TransactionIsolation; @@ -1714,7 +1712,7 @@ private void process(KeyCacheObject key, CacheObject val, GridCacheVersion ver, } finally { if (entry != null) - entry.touch(topVer); + entry.touch(); cctx.shared().database().checkpointReadUnlock(); } diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtCacheAdapter.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtCacheAdapter.java index 5adbda750d77d..6845504b0f19a 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtCacheAdapter.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtCacheAdapter.java @@ -241,7 +241,7 @@ private void processForceKeysRequest0(ClusterNode node, GridDhtForceKeysRequest if (!info.isNew()) res.addInfo(info); - entry.touch(msg.topologyVersion()); + entry.touch(); break; } @@ -677,7 +677,7 @@ private void loadEntry(KeyCacheObject key, } finally { if (entry != null) - entry.touch(topVer); + entry.touch(); part.release(); @@ -1184,7 +1184,7 @@ private void updateTtl(GridCacheAdapter cache, } finally { if (entry != null) - entry.touch(AffinityTopologyVersion.NONE); + entry.touch(); } } catch (IgniteCheckedException e) { diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtGetFuture.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtGetFuture.java index a969dd32dab60..bc776c90b2337 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtGetFuture.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtGetFuture.java @@ -402,7 +402,7 @@ private IgniteInternalFuture> getAsync( log.debug("Got removed entry when getting a DHT value: " + e); } finally { - e.touch(topVer); + e.touch(); } } } diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtGetSingleFuture.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtGetSingleFuture.java index 99a8135cfc441..20c986949dcd3 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtGetSingleFuture.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtGetSingleFuture.java @@ -349,7 +349,7 @@ private void getAsync() { log.debug("Got removed entry when getting a DHT value: " + e); } finally { - e.touch(topVer); + e.touch(); } } } diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTransactionalCacheAdapter.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTransactionalCacheAdapter.java index 11666c9badcf9..3e9f564965d13 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTransactionalCacheAdapter.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridDhtTransactionalCacheAdapter.java @@ -1493,7 +1493,7 @@ private void clearLocks(UUID nodeId, GridDistributedUnlockRequest req) { "(added to cancelled locks set): " + req); } - entry.touch(ctx.affinity().affinityTopologyVersion()); + entry.touch(); break; } @@ -1681,7 +1681,7 @@ else if (log.isDebugEnabled()) if (created && entry.markObsolete(dhtVer)) removeEntry(entry); - entry.touch(topVer); + entry.touch(); break; } diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridPartitionedGetFuture.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridPartitionedGetFuture.java index 30d36e862fa86..307e82f6c1fd1 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridPartitionedGetFuture.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridPartitionedGetFuture.java @@ -527,7 +527,7 @@ private boolean localGet(AffinityTopologyVersion topVer, KeyCacheObject key, int !deserializeBinary); } - entry.touch(topVer); + entry.touch(); // Entry was not in memory or in swap, so we remove it from cache. if (v == null) { diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridPartitionedSingleGetFuture.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridPartitionedSingleGetFuture.java index 83e46ab817497..3df001ff89aa5 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridPartitionedSingleGetFuture.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridPartitionedSingleGetFuture.java @@ -443,7 +443,7 @@ private boolean localGet(AffinityTopologyVersion topVer, int part) { true); } - entry.touch(topVer); + entry.touch(); // Entry was not in memory or in swap, so we remove it from cache. if (v == null) { 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 fbb435982fe52..fadc84db6853c 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 @@ -1589,7 +1589,7 @@ private IgniteInternalFuture> getAllAsync0(@Nullable Collection locked, AffinityTopologyVersi for (int i = 0; i < size; i++) { GridCacheMapEntry entry = locked.get(i); if (entry != null && (skip == null || !skip.contains(entry.key()))) - entry.touch(topVer); + entry.touch(); } } @@ -3274,7 +3274,7 @@ && writeThrough() && !req.skipStore(), } finally { if (entry != null) - entry.touch(req.topologyVersion()); + entry.touch(); } } } diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/colocated/GridDhtColocatedCache.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/colocated/GridDhtColocatedCache.java index eaa93aea14e53..5bef1c1b8b148 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/colocated/GridDhtColocatedCache.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/colocated/GridDhtColocatedCache.java @@ -562,7 +562,7 @@ public final IgniteInternalFuture> loadAsync( } finally { if (entry != null) - entry.touch(topVer); + entry.touch(); } } } diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPartitionDemander.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPartitionDemander.java index 5b5f3444027e3..916144d6d865f 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPartitionDemander.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPartitionDemander.java @@ -888,7 +888,7 @@ private boolean preloadEntry( cctx.isDrEnabled() ? DR_PRELOAD : DR_NONE, false )) { - cached.touch(topVer); // Start tracking. + cached.touch(); // Start tracking. if (cctx.events().isRecordable(EVT_CACHE_REBALANCE_OBJECT_LOADED) && !cached.isInternal()) cctx.events().addEvent(cached.partition(), cached.key(), cctx.localNodeId(), @@ -896,7 +896,7 @@ private boolean preloadEntry( false, null, null, null, true); } else { - cached.touch(topVer); // Start tracking. + cached.touch(); // Start tracking. if (log.isDebugEnabled()) log.debug("Rebalancing entry is already in cache (will ignore) [key=" + cached.key() + 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 3651badce1da8..14df36e26e646 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 @@ -284,7 +284,7 @@ private void processNearAtomicUpdateResponse( } finally { if (entry != null) - entry.touch(topVer); + entry.touch(); } } } diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearGetFuture.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearGetFuture.java index ee0651814b306..8451182ad4fe1 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearGetFuture.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearGetFuture.java @@ -554,7 +554,7 @@ private Map map( } finally { if (entry != null && tx == null) - entry.touch(topVer); + entry.touch(); } } @@ -655,7 +655,7 @@ private boolean localDhtGet(KeyCacheObject key, if (dhtEntry != null) // Near cache is enabled, so near entry will be enlisted in the transaction. // Always touch DHT entry in this case. - dhtEntry.touch(topVer); + dhtEntry.touch(); } } } @@ -799,7 +799,7 @@ private void releaseEvictions(Collection keys, entry.releaseEviction(); if (tx == null) - entry.touch(topVer); + entry.touch(); } } } diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearTransactionalCache.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearTransactionalCache.java index 494f388fb84e1..a5fff90930225 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearTransactionalCache.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearTransactionalCache.java @@ -255,7 +255,7 @@ public void clearLocks(UUID nodeId, GridDhtUnlockRequest req) { "(added to cancelled locks set): " + req); } - entry.touch(topVer); + entry.touch(); } else if (log.isDebugEnabled()) log.debug("Received unlock request for entry that could not be found: " + req); @@ -363,7 +363,7 @@ else if (log.isDebugEnabled()) ); if (!req.inTx()) - entry.touch(req.topologyVersion()); + entry.touch(); } else { if (evicted == null) @@ -596,7 +596,7 @@ else if (log.isDebugEnabled()) if (topVer.equals(AffinityTopologyVersion.NONE)) topVer = ctx.affinity().affinityTopologyVersion(); - entry.touch(topVer); + entry.touch(); break; } diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearTxLocal.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearTxLocal.java index a4acfa6c1f5a1..1509c715e8010 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearTxLocal.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/near/GridNearTxLocal.java @@ -1267,7 +1267,7 @@ private boolean enlistWriteEntry(GridCacheContext cacheCtx, } } catch (ClusterTopologyCheckedException e) { - entry.touch(topologyVersion()); + entry.touch(); throw e; } @@ -1325,7 +1325,7 @@ private boolean enlistWriteEntry(GridCacheContext cacheCtx, } if (readCommitted()) - entry.touch(topologyVersion()); + entry.touch(); break; // While. } @@ -2347,7 +2347,7 @@ private Collection enlistRead( } } else - entry.touch(topVer); + entry.touch(); } } } @@ -2529,7 +2529,7 @@ private void onException() { GridCacheEntryEx cached0 = txEntry.cached(); if (cached0 != null) - cached0.touch(topologyVersion()); + cached0.touch(); } } @@ -4089,7 +4089,7 @@ private IgniteInternalFuture> checkMissed( GridCacheEntryEx e = txEntry == null ? entryEx(cacheCtx, txKey, topVer) : txEntry.cached(); if (readCommitted() || skipVals) { - e.touch(topologyVersion()); + e.touch(); if (visibleVal != null) { cacheCtx.addResult(map, diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/local/GridLocalCache.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/local/GridLocalCache.java index 7b7ac66c0cc31..55b71f5caf116 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/local/GridLocalCache.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/local/GridLocalCache.java @@ -182,7 +182,7 @@ public IgniteInternalFuture lockAllAsync(Collection key if (entry != null && ctx.isAll(entry, CU.empty0())) { entry.releaseLocal(); - entry.touch(topVer); + entry.touch(); } } } diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/local/atomic/GridLocalAtomicCache.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/local/atomic/GridLocalAtomicCache.java index ef64ed8dad2a6..3771a27a36c62 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/local/atomic/GridLocalAtomicCache.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/local/atomic/GridLocalAtomicCache.java @@ -514,7 +514,7 @@ private Map getAllInternal(@Nullable Collection keys, } finally { if (entry != null) - entry.touch(ctx.affinity().affinityTopologyVersion()); + entry.touch(); } if (!success && storeEnabled) @@ -980,7 +980,7 @@ else if (res == null) } finally { if (entry != null) - entry.touch(ctx.affinity().affinityTopologyVersion()); + entry.touch(); } } } @@ -1508,7 +1508,7 @@ private List lockEntries(Collection keys) { AffinityTopologyVersion topVer = ctx.affinity().affinityTopologyVersion(); for (GridCacheEntryEx entry : locked) - entry.touch(topVer); + entry.touch(); throw new NullPointerException("Null key."); } @@ -1525,7 +1525,7 @@ private void unlockEntries(Iterable locked) { AffinityTopologyVersion topVer = ctx.affinity().affinityTopologyVersion(); for (GridCacheEntryEx entry : locked) - entry.touch(topVer); + entry.touch(); } /** diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryManager.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryManager.java index 37bdb80c3ad3e..0d959b1c46392 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryManager.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/GridCacheQueryManager.java @@ -3024,7 +3024,7 @@ private void advance() { val = entry.peek(true, true, topVer, expiryPlc); - entry.touch(topVer); + entry.touch(); break; } diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/datastreamer/DataStreamerImpl.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/datastreamer/DataStreamerImpl.java index 91947d982f49e..b9ddc2b78999f 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/datastreamer/DataStreamerImpl.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/datastreamer/DataStreamerImpl.java @@ -2271,7 +2271,7 @@ else if (ttl == CU.TTL_NOT_CHANGED) primary ? GridDrType.DR_LOAD : GridDrType.DR_PRELOAD, false); - entry.touch(topVer); + entry.touch(); CU.unwindEvicts(cctx); diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/query/schema/SchemaIndexCacheVisitorImpl.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/query/schema/SchemaIndexCacheVisitorImpl.java index 4ab3c833cccbd..e532d04d50ea6 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/query/schema/SchemaIndexCacheVisitorImpl.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/query/schema/SchemaIndexCacheVisitorImpl.java @@ -19,7 +19,6 @@ import org.apache.ignite.IgniteCheckedException; import org.apache.ignite.internal.IgniteInterruptedCheckedException; -import org.apache.ignite.internal.processors.affinity.AffinityTopologyVersion; import org.apache.ignite.internal.processors.cache.GridCacheContext; import org.apache.ignite.internal.processors.cache.GridCacheEntryEx; import org.apache.ignite.internal.processors.cache.GridCacheEntryRemovedException; @@ -244,7 +243,7 @@ private void processKey(KeyCacheObject key, SchemaIndexCacheVisitorClosure clo) entry.updateIndex(rowFilter, clo); } finally { - entry.touch(AffinityTopologyVersion.NONE); + entry.touch(); } break; diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheEntryProcessorCopySelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheEntryProcessorCopySelfTest.java index aabd3b6445826..f57622b6331dd 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheEntryProcessorCopySelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/CacheEntryProcessorCopySelfTest.java @@ -31,7 +31,6 @@ import org.apache.ignite.configuration.CacheConfiguration; import org.apache.ignite.configuration.IgniteConfiguration; import org.apache.ignite.internal.binary.BinaryMarshaller; -import org.apache.ignite.internal.processors.affinity.AffinityTopologyVersion; import org.apache.ignite.internal.util.typedef.internal.CU; import org.apache.ignite.internal.util.typedef.internal.U; import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest; @@ -158,7 +157,7 @@ private void doTest(boolean cpOnRead, final boolean mutate, int expVal, int expC CacheObject obj = entry.peekVisibleValue(); - entry.touch(AffinityTopologyVersion.NONE); + entry.touch(); int actCnt = cnt.get(); diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheAbstractFullApiSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheAbstractFullApiSelfTest.java index b872d2a82345a..1527b1e0df53d 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheAbstractFullApiSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheAbstractFullApiSelfTest.java @@ -6390,7 +6390,7 @@ public CheckEntriesTask(Collection keys) { size++; - e.touch(null); + e.touch(); } } diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheTestEntryEx.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheTestEntryEx.java index 716d32b588ee7..01df38977f278 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheTestEntryEx.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/GridCacheTestEntryEx.java @@ -892,7 +892,7 @@ GridCacheMvccCandidate anyOwner() { } /** {@inheritDoc} */ - @Override public void touch(AffinityTopologyVersion topVer) { - context().evicts().touch(this, topVer); + @Override public void touch() { + context().evicts().touch(this); } } diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheConfigVariationsFullApiTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheConfigVariationsFullApiTest.java index 3600c0595b79d..bddece3000a0f 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheConfigVariationsFullApiTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/IgniteCacheConfigVariationsFullApiTest.java @@ -6219,7 +6219,7 @@ private static class CheckEntriesTask extends TestIgniteIdxRunnable { size++; - e.touch(null); + e.touch(); } } diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheClientNodeChangingTopologyTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheClientNodeChangingTopologyTest.java index 300ecb938f42f..063b579846a87 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheClientNodeChangingTopologyTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/IgniteCacheClientNodeChangingTopologyTest.java @@ -1703,7 +1703,7 @@ private void checkData(final Map map, } } finally { - entry.touch(entry.context().affinity().affinityTopologyVersion()); + entry.touch(); } } else diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridCacheTxNodeFailureSelfTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridCacheTxNodeFailureSelfTest.java index a5c41a0b2deec..79742152018ce 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridCacheTxNodeFailureSelfTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/distributed/dht/GridCacheTxNodeFailureSelfTest.java @@ -360,7 +360,7 @@ private void dataCheck(IgniteKernal orig, IgniteKernal backup, int key, boolean assertTrue("Invalid backup cache entry: " + dhtEntry, dhtEntry.rawGet() == null); } - dhtEntry.touch(null); + dhtEntry.touch(); } /** From ce8d1136736f3d3553e725f2e8cbe4a25bf5f100 Mon Sep 17 00:00:00 2001 From: "Andrey V. Mashenkov" Date: Wed, 15 Aug 2018 12:53:01 +0300 Subject: [PATCH 2/6] IGNITE-9290: Make remove explicit locks async when node left.. Make removing locks async. Move responsibility to trigger removing locks of failed\leaved node from Exchangefuture to MvccManager. Avoid excessive OnLeft method calls in ExchangeFuture. --- .../cache/ExchangeDiscoveryEvents.java | 5 --- .../cache/GridCacheMvccManager.java | 34 +++++++++++-------- .../GridDhtPartitionsExchangeFuture.java | 16 +++------ 3 files changed, 25 insertions(+), 30 deletions(-) diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/ExchangeDiscoveryEvents.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/ExchangeDiscoveryEvents.java index 2f7753beabc02..64233ea85a8da 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/ExchangeDiscoveryEvents.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/ExchangeDiscoveryEvents.java @@ -77,11 +77,6 @@ public class ExchangeDiscoveryEvents { * @param fut Current exchange future. */ public void processEvents(GridDhtPartitionsExchangeFuture fut) { - for (DiscoveryEvent evt : evts) { - if (evt.type() == EVT_NODE_LEFT || evt.type() == EVT_NODE_FAILED) - fut.sharedContext().mvcc().removeExplicitNodeLocks(evt.eventNode().id(), fut.initialVersion()); - } - if (hasServerLeft()) warnNoAffinityNodes(fut.sharedContext()); } diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMvccManager.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMvccManager.java index 4e7bd45d56120..d497350130089 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMvccManager.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMvccManager.java @@ -261,6 +261,8 @@ else if (log.isDebugEnabled()) if (log.isDebugEnabled()) log.debug("Processing node left [nodeId=" + discoEvt.eventNode().id() + "]"); + removeExplicitNodeLocks(discoEvt.eventNode().id()); + for (GridCacheFuture fut : activeFutures()) fut.onNodeLeft(discoEvt.eventNode().id()); @@ -352,21 +354,25 @@ private IgniteInternalFuture ignoreErrors(IgniteInternalFuture f) { /** * @param leftNodeId Left node ID. - * @param topVer Topology version. */ - public void removeExplicitNodeLocks(UUID leftNodeId, AffinityTopologyVersion topVer) { - for (GridDistributedCacheEntry entry : locked()) { - try { - entry.removeExplicitNodeLocks(leftNodeId); - - entry.touch(); - } - catch (GridCacheEntryRemovedException ignore) { - if (log.isDebugEnabled()) - log.debug("Attempted to remove node locks from removed entry in mvcc manager " + - "disco callback (will ignore): " + entry); - } - } + public void removeExplicitNodeLocks(UUID leftNodeId) { + cctx.kernalContext().closure().runLocalSafe( + new Runnable() { + @Override public void run() { + for (GridDistributedCacheEntry entry : locked()) { + try { + entry.removeExplicitNodeLocks(leftNodeId); + + entry.touch(); + } + catch (GridCacheEntryRemovedException ignore) { + if (log.isDebugEnabled()) + log.debug("Attempted to remove node locks from removed entry in mvcc manager " + + "disco callback (will ignore): " + entry); + } + } + } + }, true); } /** diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPartitionsExchangeFuture.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPartitionsExchangeFuture.java index fbd3264ff6fc0..ef0a7781e017c 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPartitionsExchangeFuture.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/preloader/GridDhtPartitionsExchangeFuture.java @@ -732,12 +732,13 @@ else if (msg instanceof WalStateAbstractMessage) else { if (firstDiscoEvt.eventNode().isClient()) exchange = onClientNodeEvent(crdNode); - else + else { exchange = cctx.kernalContext().clientNode() ? ExchangeType.CLIENT : ExchangeType.ALL; - } - if (exchId.isLeft()) - onLeft(); + if (exchId.isLeft()) + onLeft(); + } + } } else { exchange = firstDiscoEvt.eventNode().isClient() ? onClientNodeEvent(crdNode) : @@ -1340,9 +1341,6 @@ private void waitPartitionRelease(boolean distributed, boolean doRollback) throw // Assign to class variable so it will be included into toString() method. this.partReleaseFut = partReleaseFut; - if (exchId.isLeft()) - cctx.mvcc().removeExplicitNodeLocks(exchId.nodeId(), exchId.topologyVersion()); - if (log.isDebugEnabled()) log.debug("Before waiting for partition release future: " + this); @@ -1481,8 +1479,6 @@ private void onLeft() { grp.preloader().unwindUndeploys(); } - - cctx.mvcc().removeExplicitNodeLocks(exchId.nodeId(), exchId.topologyVersion()); } /** @@ -3770,8 +3766,6 @@ public void onNodeLeft(final ClusterNode node) { if (isDone() || !enterBusy()) return; - cctx.mvcc().removeExplicitNodeLocks(node.id(), initialVersion()); - try { onDiscoveryEvent(new IgniteRunnable() { @Override public void run() { From 1ba950035fa5a635393364496833b7780601fe15 Mon Sep 17 00:00:00 2001 From: "Andrey V. Mashenkov" Date: Mon, 19 Nov 2018 11:21:54 +0300 Subject: [PATCH 3/6] IGNITE-10263: Fix compilation. --- .../processors/cache/GridCacheMapEntry.java | 14 +++++++------- .../processors/cache/mvcc/MvccProcessorImpl.java | 3 ++- 2 files changed, 9 insertions(+), 8 deletions(-) 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 de7dd027e852c..434645f02bb18 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 @@ -1242,7 +1242,7 @@ else if (res.resultType() == ResultType.REMOVED_NOT_NULL) { if (lockedByCurrentThread()) { unlockEntry(); - cctx.evicts().touch(this, AffinityTopologyVersion.NONE); + cctx.evicts().touch(this); } } @@ -1358,7 +1358,7 @@ else if (res.resultType() == ResultType.LOCKED) { if (lockedByCurrentThread()) { unlockEntry(); - cctx.evicts().touch(this, AffinityTopologyVersion.NONE); + cctx.evicts().touch(this); } } @@ -1426,7 +1426,7 @@ else if (res.resultType() == ResultType.LOCKED) { if (lockedByCurrentThread()) { unlockEntry(); - cctx.evicts().touch(this, AffinityTopologyVersion.NONE); + cctx.evicts().touch(this); } } @@ -5251,7 +5251,7 @@ else if (res.resultType() == ResultType.LOCKED) { if (entry.lockedByCurrentThread()) { entry.unlockEntry(); - cctx.evicts().touch(entry, AffinityTopologyVersion.NONE); + cctx.evicts().touch(entry); } } @@ -5357,7 +5357,7 @@ else if (res.resultType() == ResultType.LOCKED) { if (entry.lockedByCurrentThread()) { entry.unlockEntry(); - cctx.evicts().touch(entry, AffinityTopologyVersion.NONE); + cctx.evicts().touch(entry); } } @@ -5604,7 +5604,7 @@ else if (res.resultType() == ResultType.REMOVED_NOT_NULL) { if (entry.lockedByCurrentThread()) { entry.unlockEntry(); - cctx.evicts().touch(entry, AffinityTopologyVersion.NONE); + cctx.evicts().touch(entry); } } @@ -6796,7 +6796,7 @@ private IgniteBiTuple runEntryProcessor(CacheInvokeEntry Date: Fri, 23 Nov 2018 16:33:22 +0300 Subject: [PATCH 4/6] IGNITE-9290: Fix imports. --- .../processors/cache/mvcc/CacheMvccOperationChecksTest.java | 1 - 1 file changed, 1 deletion(-) diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/mvcc/CacheMvccOperationChecksTest.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/mvcc/CacheMvccOperationChecksTest.java index e9083f7c5092f..49196d229c02b 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/mvcc/CacheMvccOperationChecksTest.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/mvcc/CacheMvccOperationChecksTest.java @@ -26,7 +26,6 @@ import org.apache.ignite.Ignite; import org.apache.ignite.IgniteCache; import org.apache.ignite.cache.CacheMode; -import org.apache.ignite.cache.CachePeekMode; import org.apache.ignite.configuration.CacheConfiguration; import org.apache.ignite.internal.processors.cache.GridCacheAdapter; import org.apache.ignite.internal.util.typedef.internal.U; From 89b42d3dafdb2bcdbfef83cbd8e17f32ce46d9a0 Mon Sep 17 00:00:00 2001 From: "Andrey V. Mashenkov" Date: Fri, 21 Dec 2018 13:11:08 +0300 Subject: [PATCH 5/6] IGNITE-9290: Minor. --- .../ignite/internal/processors/cache/GridCacheMvccManager.java | 2 -- 1 file changed, 2 deletions(-) diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMvccManager.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMvccManager.java index 674e5f9ff9e13..311e0d37668ef 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMvccManager.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMvccManager.java @@ -369,8 +369,6 @@ public void removeExplicitNodeLocks(UUID leftNodeId) { log.debug("Attempted to remove node locks from removed entry in mvcc manager " + "disco callback (will ignore): " + entry); } - - cctx.exchange().exchangerUpdateHeartbeat(); } } }, true); From 2d01d5675fb0a6d3d3ea9628b214f2551e67bbe5 Mon Sep 17 00:00:00 2001 From: "Andrey V. Mashenkov" Date: Fri, 21 Dec 2018 13:11:58 +0300 Subject: [PATCH 6/6] IGNITE-9290: Minor. --- .../ignite/internal/processors/cache/GridCacheMvccManager.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMvccManager.java b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMvccManager.java index 311e0d37668ef..32b06a3f9df6d 100644 --- a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMvccManager.java +++ b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheMvccManager.java @@ -366,7 +366,7 @@ public void removeExplicitNodeLocks(UUID leftNodeId) { } catch (GridCacheEntryRemovedException ignore) { if (log.isDebugEnabled()) - log.debug("Attempted to remove node locks from removed entry in mvcc manager " + + log.debug("Attempted to remove node locks from removed entry in cache lock manager " + "disco callback (will ignore): " + entry); } }