public class GridDhtPreloader<K,V> extends GridCachePreloaderAdapter<K,V>
| Modifier and Type | Field and Description |
|---|---|
static long |
DFLT_PRELOAD_RESEND_TIMEOUT
Default preload resend timeout.
|
aff, cctx, log, preloadPred| Constructor and Description |
|---|
GridDhtPreloader(GridCacheContext<K,V> cctx) |
| Modifier and Type | Method and Description |
|---|---|
void |
addAssignments(GridDhtPreloaderAssignments<K,V> assignments,
boolean forcePreload)
Adds assignments to preloader.
|
void |
addDhtAssignmentFetchFuture(AffinityTopologyVersion topVer,
GridDhtAssignmentFetchFuture fut) |
GridDhtPreloaderAssignments<K,V> |
assign(GridDhtPartitionsExchangeFuture exchFut) |
void |
forcePreload()
Force preload process.
|
void |
onExchangeFutureAdded()
Callback by exchange manager when new exchange future is added to worker.
|
void |
onInitialExchangeComplete(Throwable err)
Callback by exchange manager when initial partition exchange is complete.
|
void |
onKernalStart()
Kernal start callback.
|
void |
onKernalStop()
Kernal stop callback.
|
void |
onPartitionEvicted(GridDhtLocalPartition part,
boolean updateSeq)
Resends partitions on partition evict within configured timeout.
|
void |
preloadPredicate(IgnitePredicate<GridCacheEntryInfo> preloadPred) |
void |
removeDhtAssignmentFetchFuture(AffinityTopologyVersion topVer,
GridDhtAssignmentFetchFuture fut) |
GridDhtFuture<Object> |
request(Collection<KeyCacheObject> keys,
AffinityTopologyVersion topVer)
Requests that preloader sends the request for the key.
|
void |
start()
Starts preloading.
|
IgniteInternalFuture<Object> |
startFuture() |
IgniteInternalFuture<?> |
syncFuture() |
void |
unwindUndeploys()
Unwinds undeploys.
|
void |
updateLastExchangeFuture(GridDhtPartitionsExchangeFuture lastFut)
Updates last exchange future.
|
preloadPredicate, stoppublic static final long DFLT_PRELOAD_RESEND_TIMEOUT
public GridDhtPreloader(GridCacheContext<K,V> cctx)
cctx - Cache context.public void start()
start in interface GridCachePreloader<K,V>start in class GridCachePreloaderAdapter<K,V>public void onKernalStart()
throws IgniteCheckedException
onKernalStart in interface GridCachePreloader<K,V>onKernalStart in class GridCachePreloaderAdapter<K,V>IgniteCheckedException - If failed.public void preloadPredicate(IgnitePredicate<GridCacheEntryInfo> preloadPred)
preloadPredicate in interface GridCachePreloader<K,V>preloadPredicate in class GridCachePreloaderAdapter<K,V>preloadPred - Preload predicate.public void onKernalStop()
onKernalStop in interface GridCachePreloader<K,V>onKernalStop in class GridCachePreloaderAdapter<K,V>public void onInitialExchangeComplete(@Nullable Throwable err)
onInitialExchangeComplete in interface GridCachePreloader<K,V>onInitialExchangeComplete in class GridCachePreloaderAdapter<K,V>err - Error, if any happened on initial exchange.public void onExchangeFutureAdded()
onExchangeFutureAdded in interface GridCachePreloader<K,V>onExchangeFutureAdded in class GridCachePreloaderAdapter<K,V>public void updateLastExchangeFuture(GridDhtPartitionsExchangeFuture lastFut)
updateLastExchangeFuture in interface GridCachePreloader<K,V>updateLastExchangeFuture in class GridCachePreloaderAdapter<K,V>lastFut - Last future.public GridDhtPreloaderAssignments<K,V> assign(GridDhtPartitionsExchangeFuture exchFut)
assign in interface GridCachePreloader<K,V>assign in class GridCachePreloaderAdapter<K,V>exchFut - Exchange future to assign.public void addAssignments(GridDhtPreloaderAssignments<K,V> assignments, boolean forcePreload)
addAssignments in interface GridCachePreloader<K,V>addAssignments in class GridCachePreloaderAdapter<K,V>assignments - Assignments to add.forcePreload - Force preload flag.public IgniteInternalFuture<Object> startFuture()
GridCachePreloaderAdapterstartFuture in interface GridCachePreloader<K,V>startFuture in class GridCachePreloaderAdapter<K,V>public IgniteInternalFuture<?> syncFuture()
syncFuture in interface GridCachePreloader<K,V>syncFuture in class GridCachePreloaderAdapter<K,V>public void addDhtAssignmentFetchFuture(AffinityTopologyVersion topVer, GridDhtAssignmentFetchFuture fut)
topVer - Requested topology version.fut - Future to add.public void removeDhtAssignmentFetchFuture(AffinityTopologyVersion topVer, GridDhtAssignmentFetchFuture fut)
topVer - Requested topology version.fut - Future to remove.public void onPartitionEvicted(GridDhtLocalPartition part, boolean updateSeq)
part - Evicted partition.updateSeq - Update sequence.public GridDhtFuture<Object> request(Collection<KeyCacheObject> keys, AffinityTopologyVersion topVer)
GridCachePreloaderAdapterrequest in interface GridCachePreloader<K,V>request in class GridCachePreloaderAdapter<K,V>keys - Keys to request.topVer - Topology version, -1 if not required.public void forcePreload()
forcePreload in interface GridCachePreloader<K,V>forcePreload in class GridCachePreloaderAdapter<K,V>public void unwindUndeploys()
unwindUndeploys in interface GridCachePreloader<K,V>unwindUndeploys in class GridCachePreloaderAdapter<K,V>
Follow @ApacheIgnite
Ignite Fabric : ver. 1.0.0 Release Date : March 31 2015