Class PartitionsEvictManager
- java.lang.Object
-
- org.apache.ignite.internal.processors.cache.GridCacheSharedManagerAdapter
-
- org.apache.ignite.internal.processors.cache.distributed.dht.topology.PartitionsEvictManager
-
- All Implemented Interfaces:
GridCacheSharedManager
public class PartitionsEvictManager extends GridCacheSharedManagerAdapter
Class that serves asynchronous part eviction process. Multiple partition from group can be evicted at the same time.
-
-
Field Summary
Fields Modifier and Type Field Description static StringSHOW_EVICTION_PROGRESS_FREQEviction progress frequency property name.-
Fields inherited from class org.apache.ignite.internal.processors.cache.GridCacheSharedManagerAdapter
cctx, diagnosticLog, log
-
-
Constructor Summary
Constructors Constructor Description PartitionsEvictManager()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcleanupRemovedGroup(int grpId)Cleans up group eviction context when it's safe.IgniteInternalFuture<?>evictPartitionAsync(CacheGroupContext grp, GridDhtLocalPartition part, GridFutureAdapter<?> finishFut)Adds partition to eviction queue and starts eviction process if permit available.voidonCacheGroupStarted(CacheGroupContext grp)Callback on cache group start.voidonCacheGroupStopped(CacheGroupContext grp)Stops eviction process for group.protected voidonKernalStop0(boolean cancel)protected voidstart0()inttotal()-
Methods inherited from class org.apache.ignite.internal.processors.cache.GridCacheSharedManagerAdapter
context, isStopping, kernalStartInfo, kernalStopInfo, onDisconnected, onKernalStart, onKernalStart0, onKernalStop, onReconnected, printMemoryStats, start, startInfo, stop, stop0, stopInfo, toString
-
-
-
-
Field Detail
-
SHOW_EVICTION_PROGRESS_FREQ
@SystemProperty(value="Eviction progress frequency in milliseconds", type=java.lang.Long.class, defaults="120000") public static final String SHOW_EVICTION_PROGRESS_FREQ
Eviction progress frequency property name.- See Also:
- Constant Field Values
-
-
Method Detail
-
onCacheGroupStarted
public void onCacheGroupStarted(CacheGroupContext grp)
Callback on cache group start.- Parameters:
grp- Group.
-
onCacheGroupStopped
public void onCacheGroupStopped(CacheGroupContext grp)
Stops eviction process for group. Method awaits last offered partition eviction.- Parameters:
grp- Group context.
-
evictPartitionAsync
public IgniteInternalFuture<?> evictPartitionAsync(CacheGroupContext grp, GridDhtLocalPartition part, GridFutureAdapter<?> finishFut)
Adds partition to eviction queue and starts eviction process if permit available.- Parameters:
grp- Group context.part- Partition to evict.finishFut- Clearing finish future.
-
start0
protected void start0() throws IgniteCheckedException- Overrides:
start0in classGridCacheSharedManagerAdapter- Throws:
IgniteCheckedException- If failed.
-
onKernalStop0
protected void onKernalStop0(boolean cancel)
- Overrides:
onKernalStop0in classGridCacheSharedManagerAdapter- Parameters:
cancel- Cancel flag.
-
cleanupRemovedGroup
public void cleanupRemovedGroup(int grpId)
Cleans up group eviction context when it's safe.- Parameters:
grpId- Group id.
-
total
public int total()
- Returns:
- The number of executing + waiting in the queue tasks.
-
-