public class GridNearAtomicUpdateResponse<K,V> extends GridCacheMessage<K,V> implements GridCacheDeployable
MessageAdapter.Type| Modifier and Type | Field and Description |
|---|---|
static int |
CACHE_MSG_IDX
Cache message index.
|
CACHE_MSG_INDEX_FIELD_NAME, cacheId, MAX_CACHE_MSG_LOOKUP_INDEXreader, readState| Constructor and Description |
|---|
GridNearAtomicUpdateResponse()
Empty constructor required by
Externalizable. |
GridNearAtomicUpdateResponse(int cacheId,
UUID nodeId,
GridCacheVersion futVer) |
| Modifier and Type | Method and Description |
|---|---|
void |
addFailedKey(K key,
Throwable e)
Adds key to collection of failed keys.
|
void |
addFailedKeys(Collection<K> keys,
Throwable e)
Adds keys to collection of failed keys.
|
void |
addNearTtl(int keyIdx,
long ttl,
long expireTime) |
void |
addNearValue(int keyIdx,
V val,
byte[] valBytes,
long ttl,
long expireTime)
Adds value to be put in near cache on originating node.
|
void |
addSkippedIndex(int keyIdx) |
byte |
directType()
Gets message type.
|
Throwable |
error() |
Collection<K> |
failedKeys() |
void |
finishUnmarshal(GridCacheSharedContext<K,V> ctx,
ClassLoader ldr)
This method is called after the message is deserialized and is responsible for
unmarshalling state marshalled in
GridCacheMessage.prepareMarshal(GridCacheSharedContext) method. |
GridCacheVersion |
futureVersion() |
int |
lookupIndex()
Gets message lookup index.
|
long |
nearExpireTime(int idx) |
long |
nearTtl(int idx) |
V |
nearValue(int idx) |
byte[] |
nearValueBytes(int idx) |
List<Integer> |
nearValuesIndexes() |
GridCacheVersion |
nearVersion() |
void |
nearVersion(GridCacheVersion nearVer) |
UUID |
nodeId() |
void |
nodeId(UUID nodeId) |
void |
prepareMarshal(GridCacheSharedContext<K,V> ctx)
This method is called before the whole message is serialized
and is responsible for pre-marshalling state.
|
boolean |
readFrom(ByteBuffer buf)
Reads this message from provided byte buffer.
|
Collection<K> |
remapKeys() |
void |
remapKeys(Collection<K> remapKeys) |
GridCacheReturn<Object> |
returnValue() |
void |
returnValue(GridCacheReturn<Object> retVal) |
List<Integer> |
skippedIndexes() |
String |
toString() |
boolean |
writeTo(ByteBuffer buf,
MessageWriter writer)
Writes this message to provided byte buffer.
|
allowForStartup, cacheId, cacheId, classError, deployInfo, ignoreClassErrors, marshalBooleanLinkedMap, marshalCollection, marshalFilter, marshalInfo, marshalInfos, marshalInvokeArguments, marshalTx, marshalValuesCollection, messageId, nextIndexId, onClassError, prepare, prepareFilter, prepareObject, prepareObjects, topologyVersion, transactional, transferExpiryPolicy, unmarshalBooleanLinkedMap, unmarshalCollection, unmarshalFilter, unmarshalInfo, unmarshalInfos, unmarshalInvokeArguments, unmarshalTx, unmarshalValueBytesCollectionsetReader, skipRecoveryclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitdeployInfo, preparepublic GridNearAtomicUpdateResponse()
Externalizable.public GridNearAtomicUpdateResponse(int cacheId,
UUID nodeId,
GridCacheVersion futVer)
cacheId - Cache ID.nodeId - Node ID this reply should be sent to.futVer - Future version.public int lookupIndex()
GridCacheMessage.MAX_CACHE_MSG_LOOKUP_INDEX.lookupIndex in class GridCacheMessage<K,V>public UUID nodeId()
public void nodeId(UUID nodeId)
nodeId - Node ID.public GridCacheVersion futureVersion()
public Throwable error()
public Collection<K> failedKeys()
public GridCacheReturn<Object> returnValue()
public void returnValue(GridCacheReturn<Object> retVal)
retVal - Return value.public void remapKeys(Collection<K> remapKeys)
remapKeys - Remap keys.public Collection<K> remapKeys()
public void addNearValue(int keyIdx,
@Nullable
V val,
@Nullable
byte[] valBytes,
long ttl,
long expireTime)
keyIdx - Key index.val - Value.valBytes - Value bytes.ttl - TTL for near cache update.expireTime - Expire time for near cache update.public void addNearTtl(int keyIdx,
long ttl,
long expireTime)
keyIdx - Key index.ttl - TTL for near cache update.expireTime - Expire time for near cache update.public long nearExpireTime(int idx)
idx - Index.public long nearTtl(int idx)
idx - Index.public void nearVersion(GridCacheVersion nearVer)
nearVer - Version generated on primary node to be used for originating node's near cache update.public GridCacheVersion nearVersion()
public void addSkippedIndex(int keyIdx)
keyIdx - Index of key for which update was skipped@Nullable public List<Integer> skippedIndexes()
@Nullable public List<Integer> nearValuesIndexes()
@Nullable public V nearValue(int idx)
idx - Index.@Nullable public byte[] nearValueBytes(int idx)
idx - Index.public void addFailedKey(K key, Throwable e)
key - Key to add.e - Error cause.public void addFailedKeys(Collection<K> keys, Throwable e)
keys - Key to add.e - Error cause.public void prepareMarshal(GridCacheSharedContext<K,V> ctx) throws IgniteCheckedException
prepareMarshal in class GridCacheMessage<K,V>ctx - IgniteCheckedException - If failed.public void finishUnmarshal(GridCacheSharedContext<K,V> ctx, ClassLoader ldr) throws IgniteCheckedException
GridCacheMessage.prepareMarshal(GridCacheSharedContext) method.finishUnmarshal in class GridCacheMessage<K,V>ctx - Context.ldr - Class loader.IgniteCheckedException - If failed.public boolean writeTo(ByteBuffer buf, MessageWriter writer)
writeTo in class GridCacheMessage<K,V>buf - Byte buffer.writer - Writer.public boolean readFrom(ByteBuffer buf)
readFrom in class GridCacheMessage<K,V>buf - Byte buffer.public byte directType()
directType in class MessageAdapterpublic String toString()
toString in class GridCacheMessage<K,V>
Follow @ApacheIgnite
Ignite Fabric : ver. 1.0.0-RC1 Release Date : February 17 2015