public class GridDistributedLockRequest<K,V> extends GridDistributedBaseMessage<K,V>
| Modifier and Type | Field and Description |
|---|---|
protected int |
idx
Key-bytes index.
|
verCACHE_MSG_INDEX_FIELD_NAME, MAX_CACHE_MSG_LOOKUP_INDEXBIT_SET_NOT_READ, BOOLEAN_ARR_NOT_READ, BYTE_ARR_LIST_NOT_READ, BYTE_ARR_NOT_READ, CACHE_VER_NOT_READ, CHAR_ARR_NOT_READ, CLOCK_DELTA_VER_NOT_READ, commState, DHT_PART_EXCHANGE_ID_NOT_READ, DOUBLE_ARR_NOT_READ, DR_INT_REQ_ENTRY_NOT_READ, ENUM_NOT_READ, FLOAT_ARR_NOT_READ, GRID_UUID_NOT_READ, INT_ARR_NOT_READ, LONG_ARR_NOT_READ, LONG_LIST_NOT_READ, MSG_NOT_READ, NULL, SHORT_ARR_NOT_READ, STR_NOT_READ, UUID_NOT_READ, VAL_BYTES_NOT_READ| Constructor and Description |
|---|
GridDistributedLockRequest()
Empty constructor.
|
GridDistributedLockRequest(UUID nodeId,
GridCacheVersion nearXidVer,
long threadId,
GridUuid futId,
GridCacheVersion lockVer,
boolean isInTx,
boolean isRead,
GridCacheTxIsolation isolation,
boolean isInvalidate,
long timeout,
int keyCnt,
int txSize,
Object grpLockKey,
boolean partLock) |
| Modifier and Type | Method and Description |
|---|---|
void |
addKeyBytes(K key,
byte[] keyBytes,
GridCacheTxEntry<K,V> writeEntry,
boolean retVal,
Collection<GridCacheMvccCandidate<K>> cands,
GridCacheVersion drVer,
GridCacheContext<K,V> ctx)
Adds a key.
|
GridTcpCommunicationMessageAdapter |
clone() |
protected void |
clone0(GridTcpCommunicationMessageAdapter _msg)
Clones all fields of the provided message to
this. |
byte |
directType() |
GridCacheVersion |
drVersionByIndex(int idx) |
void |
drVersionByIndex(int idx,
GridCacheVersion drVer) |
GridCacheVersion[] |
drVersions() |
void |
finishUnmarshal(GridCacheContext<K,V> ctx,
ClassLoader ldr)
This method is called after the message is deserialized and is responsible for
unmarshalling state marshalled in
GridCacheMessage.prepareMarshal(GridCacheContext) method. |
GridUuid |
futureId() |
boolean |
groupLock() |
Object |
groupLockKey() |
boolean |
inTx() |
boolean |
isInvalidate() |
GridCacheTxIsolation |
isolation() |
List<byte[]> |
keyBytes() |
List<K> |
keys() |
GridCacheVersion |
nearXidVersion() |
UUID |
nodeId() |
boolean |
partitionLock() |
void |
prepareMarshal(GridCacheContext<K,V> ctx)
This method is called before the whole message is serialized
and is responsible for pre-marshalling state.
|
boolean |
readFrom(ByteBuffer buf) |
boolean[] |
returnFlags() |
boolean |
returnValue(int idx) |
long |
threadId() |
long |
timeout() |
String |
toString() |
boolean |
txRead() |
int |
txSize() |
List<GridCacheTxEntry<K,V>> |
writeEntries() |
boolean |
writeTo(ByteBuffer buf) |
candidatesByIndex, candidatesByIndex, candidatesByKey, candidatesByKey, candidatesByKey, committedVersions, completedVersions, keysCount, rolledbackVersions, version, versionallowForStartup, classError, deployInfo, ignoreClassErrors, lookupIndex, marshalBooleanLinkedMap, marshalCollection, marshalFilter, marshalInfo, marshalInfos, marshalTx, marshalValuesCollection, messageId, nextIndexId, onClassError, prepare, prepareFilter, prepareObject, prepareObjects, topologyVersion, unmarshalBooleanLinkedMap, unmarshalCollection, unmarshalFilter, unmarshalInfo, unmarshalInfos, unmarshalTx, unmarshalValueBytesCollectionarrayIterator, messageReader, messageWriterequals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitdeployInfo, preparepublic GridDistributedLockRequest()
public GridDistributedLockRequest(UUID nodeId, @Nullable GridCacheVersion nearXidVer, long threadId, GridUuid futId, GridCacheVersion lockVer, boolean isInTx, boolean isRead, GridCacheTxIsolation isolation, boolean isInvalidate, long timeout, int keyCnt, int txSize, @Nullable Object grpLockKey, boolean partLock)
nodeId - Node ID.nearXidVer - Near transaction ID.threadId - Thread ID.futId - Future ID.lockVer - Cache version.isInTx - True if implicit transaction lock.isRead - Indicates whether implicit lock is for read or write operation.isolation - Transaction isolation.isInvalidate - Invalidation flag.timeout - Lock timeout.keyCnt - Number of keys.txSize - Expected transaction size.grpLockKey - Group lock key if this is a group-lock transaction.partLock - True if this is a group-lock transaction request and whole partition is
locked.public UUID nodeId()
public GridCacheVersion nearXidVersion()
public long threadId()
public GridUuid futureId()
public boolean inTx()
True if implicit transaction lock.public boolean isInvalidate()
public boolean txRead()
True if lock is implicit and for a read operation.public boolean returnValue(int idx)
idx - Key index.public boolean[] returnFlags()
public GridCacheTxIsolation isolation()
public List<byte[]> keyBytes()
public List<GridCacheTxEntry<K,V>> writeEntries()
public int txSize()
public void addKeyBytes(K key, @Nullable byte[] keyBytes, @Nullable GridCacheTxEntry<K,V> writeEntry, boolean retVal, @Nullable Collection<GridCacheMvccCandidate<K>> cands, @Nullable GridCacheVersion drVer, GridCacheContext<K,V> ctx) throws GridException
key - Key.retVal - Flag indicating whether value should be returned.keyBytes - Key bytes.writeEntry - Write entry.cands - Candidates.drVer - DR version.ctx - Context.GridException - If failed.public boolean groupLock()
True if lock request for group-lock transaction.public boolean partitionLock()
True if partition is locked in group-lock transaction.public long timeout()
public void drVersionByIndex(int idx,
GridCacheVersion drVer)
idx - Key index.drVer - DR version.public GridCacheVersion drVersionByIndex(int idx)
idx - Key index.public GridCacheVersion[] drVersions()
public void prepareMarshal(GridCacheContext<K,V> ctx) throws GridException
prepareMarshal in class GridDistributedBaseMessage<K,V>ctx - Cache context.GridException - If failed.public void finishUnmarshal(GridCacheContext<K,V> ctx, ClassLoader ldr) throws GridException
GridCacheMessage.prepareMarshal(GridCacheContext) method.finishUnmarshal in class GridDistributedBaseMessage<K,V>ctx - Context.ldr - Class loader.GridException - If failed.public GridTcpCommunicationMessageAdapter clone()
clone in class GridTcpCommunicationMessageAdapterprotected void clone0(GridTcpCommunicationMessageAdapter _msg)
this.clone0 in class GridDistributedBaseMessage<K,V>_msg - Message to clone from.public boolean writeTo(ByteBuffer buf)
writeTo in class GridDistributedBaseMessage<K,V>buf - Byte buffer.public boolean readFrom(ByteBuffer buf)
readFrom in class GridDistributedBaseMessage<K,V>buf - Byte buffer.public byte directType()
directType in class GridTcpCommunicationMessageAdapterpublic String toString()
toString in class GridDistributedBaseMessage<K,V>Copyright © 2014. All rights reserved.