public abstract class AbstractReplicationInBatchContext extends ReplicationInContext implements IReplicationInBatchContext
Constructor and Description |
---|
AbstractReplicationInBatchContext(org.slf4j.Logger contextLogger,
int entireBatchSize,
String sourceLookupName,
String groupName,
boolean supportDistTransactionConsolidation) |
Modifier and Type | Method and Description |
---|---|
<T> void |
addPendingContext(T operationContext) |
protected abstract void |
afterBatchConsumed(long lastProcessedKeyInBatch) |
void |
currentConsumed() |
long |
getCurrentKey() |
int |
getEntireBatchSize() |
<T> List<T> |
getPendingContext() |
<T> T |
getTagObject() |
boolean |
isBatchContext() |
void |
pendingConsumed()
Should be called once all the pending operation that are kept in the context are consumed and
considered successfully replicated.
|
void |
rollback() |
void |
setCurrentKey(long currentKey) |
<T> void |
setTagObject(T tagObject) |
void |
snapshot() |
getContentContext, getContextLogger, getContextMarker, getGroupName, getLastProcessedKey, getReplicationBlobstoreBulkContext, getSourceLookupName, setContextPacket, setLastProcessedKey, setReplicationBlobstoreBulkContext, supportsDistributedTransactionConsolidation
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getContentContext, getContextLogger, getContextMarker, getGroupName, getLastProcessedKey, getReplicationBlobstoreBulkContext, getSourceLookupName, setReplicationBlobstoreBulkContext, supportsDistributedTransactionConsolidation
public void pendingConsumed()
IReplicationInBatchContext
pendingConsumed
in interface IReplicationInBatchContext
public <T> void addPendingContext(T operationContext)
addPendingContext
in interface IReplicationInBatchContext
public <T> List<T> getPendingContext()
getPendingContext
in interface IReplicationInBatchContext
public void setCurrentKey(long currentKey)
public void currentConsumed()
currentConsumed
in interface IReplicationInBatchContext
protected abstract void afterBatchConsumed(long lastProcessedKeyInBatch)
public <T> void setTagObject(T tagObject)
setTagObject
in interface IReplicationInBatchContext
public <T> T getTagObject()
getTagObject
in interface IReplicationInBatchContext
public int getEntireBatchSize()
getEntireBatchSize
in interface IReplicationInBatchContext
public long getCurrentKey()
public void snapshot()
public void rollback()
public boolean isBatchContext()
isBatchContext
in interface IReplicationInContext
isBatchContext
in class ReplicationInContext
Copyright © GigaSpaces.