Class CacheDistributedGetFutureAdapter.AbstractMiniFuture
- java.lang.Object
-
- org.apache.ignite.internal.util.future.GridFutureAdapter<Map<K,V>>
-
- org.apache.ignite.internal.processors.cache.distributed.dht.CacheDistributedGetFutureAdapter.AbstractMiniFuture
-
- All Implemented Interfaces:
IgniteInternalFuture<Map<K,V>>
- Enclosing class:
- CacheDistributedGetFutureAdapter<K,V>
protected abstract class CacheDistributedGetFutureAdapter.AbstractMiniFuture extends GridFutureAdapter<Map<K,V>>
Mini-future for get operations. Mini-futures are only waiting on a single node as opposed to multiple nodes.
-
-
Field Summary
Fields Modifier and Type Field Description protected LinkedHashMap<KeyCacheObject,Boolean>keysMapped keys.protected ClusterNodenodeMapped node.protected AffinityTopologyVersiontopVerTopology version on which this future was mapped.
-
Constructor Summary
Constructors Modifier Constructor Description protectedAbstractMiniFuture(ClusterNode node, LinkedHashMap<KeyCacheObject,Boolean> keys, AffinityTopologyVersion topVer)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description GridNearGetRequestcreateGetRequest(IgniteUuid rootFutId)Factory methond for generate request associated with this miniFuture.protected abstract GridNearGetRequestcreateGetRequest0(IgniteUuid rootFutId, IgniteUuid futId)protected abstract Map<K,V>createResultMap(Collection<GridCacheEntryInfo> entries)IgniteUuidfutureId()ClusterNodenode()voidonNodeLeft()voidonResult(Throwable e)voidonResult(GridNearGetResponse res)protected voidpostProcessResult(GridNearGetResponse res)StringtoString()-
Methods inherited from class org.apache.ignite.internal.util.future.GridFutureAdapter
cancel, chain, chain, chain, chain, chainCompose, chainCompose, error, get, get, get, getUninterruptibly, ignoreInterrupts, isCancelled, isDone, isFailed, listen, listen, logger, onCancelled, onDone, onDone, onDone, onDone, onDone, reset, result
-
-
-
-
Field Detail
-
node
protected final ClusterNode node
Mapped node.
-
keys
@GridToStringInclude protected final LinkedHashMap<KeyCacheObject,Boolean> keys
Mapped keys.
-
topVer
protected final AffinityTopologyVersion topVer
Topology version on which this future was mapped.
-
-
Constructor Detail
-
AbstractMiniFuture
protected AbstractMiniFuture(ClusterNode node, LinkedHashMap<KeyCacheObject,Boolean> keys, AffinityTopologyVersion topVer)
- Parameters:
node- Node.keys- Keys.topVer- Topology version.
-
-
Method Detail
-
futureId
public IgniteUuid futureId()
- Returns:
- Future ID.
-
node
public ClusterNode node()
- Returns:
- Node ID.
-
createGetRequest
public GridNearGetRequest createGetRequest(IgniteUuid rootFutId)
Factory methond for generate request associated with this miniFuture.- Parameters:
rootFutId- Root future id.- Returns:
- Near get request.
-
createGetRequest0
protected abstract GridNearGetRequest createGetRequest0(IgniteUuid rootFutId, IgniteUuid futId)
- Parameters:
rootFutId- Root future id.futId- Mini future id.- Returns:
- Near get request.
-
createResultMap
protected abstract Map<K,V> createResultMap(Collection<GridCacheEntryInfo> entries)
- Parameters:
entries- Collection of entries.- Returns:
- Map with key value results.
-
onResult
public void onResult(Throwable e)
- Parameters:
e- Error.
-
onNodeLeft
public void onNodeLeft()
-
onResult
public void onResult(GridNearGetResponse res)
- Parameters:
res- Result callback.
-
postProcessResult
protected void postProcessResult(GridNearGetResponse res)
- Parameters:
res- Response.
-
-