Class ReplicaGetOperationImpl
java.lang.Object
net.spy.memcached.compat.SpyObject
net.spy.memcached.protocol.BaseOperationImpl
net.spy.memcached.protocol.binary.OperationImpl
net.spy.memcached.protocol.binary.SingleKeyOperationImpl
net.spy.memcached.protocol.binary.ReplicaGetOperationImpl
- All Implemented Interfaces:
KeyedOperation, Operation, ReplicaGetOperation, VBucketAware
Implementation of the replica get operation.
-
Nested Class Summary
Nested classes/interfaces inherited from interface ReplicaGetOperation
ReplicaGetOperation.Callback -
Field Summary
FieldsModifier and TypeFieldDescription(package private) static final intLength of the extra header stuff for a GET response.(package private) static final byteprivate final intFields inherited from class SingleKeyOperationImpl
keyFields inherited from class OperationImpl
DUMMY_OPCODE, EMPTY_BYTES, ERR_2BIG, ERR_BUSY, ERR_DELTA_BADVAL, ERR_EXISTS, ERR_INTERNAL, ERR_INVAL, ERR_NO_MEM, ERR_NOT_FOUND, ERR_NOT_MY_VBUCKET, ERR_NOT_STORED, ERR_NOT_SUPPORTED, ERR_TEMP_FAIL, ERR_UNKNOWN_COMMAND, errorCode, keyLen, MIN_RECV_PACKET, opaque, REQ_MAGIC, RES_MAGIC, responseCas, responseCmd, responseOpaque, STATUS_OK, SUCCESS, vbucketFields inherited from class BaseOperationImpl
callback, CANCELLED, notMyVbucketNodes, TIMED_OUT -
Constructor Summary
ConstructorsConstructorDescriptionReplicaGetOperationImpl(String k, int index, ReplicaGetOperation.Callback cb) -
Method Summary
Modifier and TypeMethodDescriptionprotected voiddecodePayload(byte[] pl) Decode the given payload for this command.intvoidInitialize this operation.Methods inherited from class SingleKeyOperationImpl
addNotMyVbucketNode, getKeys, getNotMyVbucketNodes, getVBucket, setNotMyVbucketNodes, setVBucket, toStringMethods inherited from class OperationImpl
decodeByte, decodeInt, decodeLong, decodeShort, decodeUnsignedInt, finishedPayload, generateOpaque, getErrorMsg, getStatusForErrorCode, opaqueIsValid, prepareBuffer, readFromBuffer, resetInputMethods inherited from class BaseOperationImpl
addClone, cancel, getBuffer, getCallback, getCloneCount, getException, getHandlingNode, getState, getWriteCompleteTimestamp, handleError, handleRead, hasErrored, isCancelled, isTimedOut, isTimedOut, isTimedOutUnsent, setBuffer, setCallback, setCloneCount, setHandlingNode, timeOut, transitionState, wasCancelled, writeComplete, writingMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface KeyedOperation
getKeysMethods inherited from interface Operation
addClone, cancel, getBuffer, getCallback, getCloneCount, getErrorMsg, getException, getHandlingNode, getState, getWriteCompleteTimestamp, handleRead, hasErrored, isCancelled, isTimedOut, isTimedOut, isTimedOutUnsent, readFromBuffer, setCloneCount, setHandlingNode, timeOut, writeComplete, writing
-
Field Details
-
REPLICA_GET_CMD
static final byte REPLICA_GET_CMD- See Also:
-
replicaIndex
private final int replicaIndex -
EXTRA_HDR_LEN
static final int EXTRA_HDR_LENLength of the extra header stuff for a GET response.- See Also:
-
-
Constructor Details
-
ReplicaGetOperationImpl
-
-
Method Details
-
initialize
public void initialize()Description copied from interface:OperationInitialize this operation. This is used to prepare output byte buffers and stuff.- Specified by:
initializein interfaceOperation- Specified by:
initializein classBaseOperationImpl
-
decodePayload
protected void decodePayload(byte[] pl) Description copied from class:OperationImplDecode the given payload for this command.- Overrides:
decodePayloadin classOperationImpl- Parameters:
pl- the payload.
-
getReplicaIndex
public int getReplicaIndex()- Specified by:
getReplicaIndexin interfaceReplicaGetOperation
-