public abstract class AbstractCacheOperation extends AbstractNamedOperation implements PartitionAwareOperation, ServiceNamespaceAware, IdentifiedDataSerializable
Modifier and Type | Field and Description |
---|---|
protected CacheRecord |
backupRecord |
protected ICacheRecordStore |
cache |
protected ICacheService |
cacheService |
protected Data |
key |
protected Object |
response |
protected CacheWanEventPublisher |
wanEventPublisher |
name
GENERIC_PARTITION_ID
Modifier | Constructor and Description |
---|---|
protected |
AbstractCacheOperation() |
protected |
AbstractCacheOperation(String name,
Data key) |
Modifier and Type | Method and Description |
---|---|
void |
beforeRun() |
int |
getAsyncBackupCount() |
int |
getFactoryId()
Returns DataSerializableFactory factory ID for this class.
|
Object |
getResponse()
Called if and only if
Operation.returnsResponse() returned true , shortly after Operation.run()
returns. |
String |
getServiceName() |
ObjectNamespace |
getServiceNamespace()
Returns the
ServiceNamespace which this object belongs to. |
int |
getSyncBackupCount() |
void |
logError(Throwable e)
Logs Exception/Error thrown during operation execution.
|
ExceptionAction |
onInvocationException(Throwable throwable)
Called when an Exception/Error is thrown
during an invocation.
|
protected void |
readInternal(ObjectDataInput in) |
protected void |
writeInternal(ObjectDataOutput out) |
getName, toString
afterRun, call, executedLocally, getCallerAddress, getCallerUuid, getCallId, getCallTimeout, getConnection, getInvocationTime, getLogger, getNodeEngine, getOperationResponseHandler, getPartitionId, getReplicaIndex, getService, getWaitTimeout, isUrgent, onExecutionFailure, onSetCallId, readData, returnsResponse, run, sendResponse, setCallerUuid, setNodeEngine, setOperationResponseHandler, setPartitionId, setReplicaIndex, setService, setServiceName, setValidateTarget, setWaitTimeout, toString, validatesTarget, writeData
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getPartitionId
getId
readData, writeData
protected Data key
protected Object response
protected transient ICacheService cacheService
protected transient ICacheRecordStore cache
protected transient CacheWanEventPublisher wanEventPublisher
protected transient CacheRecord backupRecord
public String getServiceName()
getServiceName
in class Operation
public void beforeRun() throws Exception
public final Object getResponse()
Operation
Operation.returnsResponse()
returned true
, shortly after Operation.run()
returns.getResponse
in class Operation
public ExceptionAction onInvocationException(Throwable throwable)
Operation
onInvocationException
in class Operation
throwable
- Exception/Error thrown during invocationpublic void logError(Throwable e)
Operation
public ObjectNamespace getServiceNamespace()
ServiceNamespaceAware
ServiceNamespace
which this object belongs to.getServiceNamespace
in interface ServiceNamespaceAware
protected void writeInternal(ObjectDataOutput out) throws IOException
writeInternal
in class AbstractNamedOperation
IOException
protected void readInternal(ObjectDataInput in) throws IOException
readInternal
in class AbstractNamedOperation
IOException
public int getFactoryId()
IdentifiedDataSerializable
getFactoryId
in interface IdentifiedDataSerializable
public final int getSyncBackupCount()
public final int getAsyncBackupCount()
Copyright © 2018 Hazelcast, Inc.. All Rights Reserved.