public abstract class BaseRpcInterceptor extends CommandInterceptor
ReplicationInterceptor
and OptimisticReplicationInterceptor
.Modifier and Type | Field and Description |
---|---|
protected boolean |
defaultSynchronous |
protected RPCManager |
rpcManager |
protected TransactionTable |
txTable |
configuration, log, trace
Constructor and Description |
---|
BaseRpcInterceptor() |
Modifier and Type | Method and Description |
---|---|
protected void |
checkResponses(List rsps)
Checks whether any of the responses are exceptions.
|
void |
injectComponents(RPCManager rpcManager,
BuddyManager buddyManager,
ReplicationQueue replicationQueue,
TransactionTable txTable,
CommandsFactory commandsFactory) |
protected boolean |
isLocalModeForced(InvocationContext ctx) |
protected boolean |
isSynchronous(Option option) |
protected boolean |
isTransactionalAndLocal(InvocationContext ctx)
The call runs in a transaction and it was initiated on this node of the cluster.
|
protected void |
replicateCall(InvocationContext ctx,
ReplicableCommand call,
boolean sync,
Option o) |
protected void |
replicateCall(InvocationContext ctx,
ReplicableCommand call,
boolean sync,
Option o,
boolean useOutOfBandMessage) |
protected void |
replicateCall(InvocationContext ctx,
Vector<org.jgroups.Address> recipients,
ReplicableCommand c,
boolean sync,
Option o,
boolean useOutOfBandMessage) |
protected void |
replicateCall(Vector<org.jgroups.Address> recipients,
ReplicableCommand call,
boolean sync,
boolean wrapCacheCommandInReplicateMethod,
boolean useOutOfBandMessage,
boolean isBroadcast,
long timeout) |
protected boolean |
skipReplicationOfTransactionMethod(InvocationContext ctx)
It does not make sense replicating a transaction method(commit, rollback, prepare) if one of the following is true:
|
getNext, handleDefault, hasNext, invokeNextInterceptor, setNext
visitClearDataCommand, visitCollection, visitCommitCommand, visitCreateNodeCommand, visitEvictFqnCommand, visitExistsNodeCommand, visitGetChildrenNamesCommand, visitGetDataMapCommand, visitGetKeysCommand, visitGetKeyValueCommand, visitGetNodeCommand, visitGravitateDataCommand, visitInvalidateCommand, visitMoveCommand, visitOptimisticPrepareCommand, visitPrepareCommand, visitPutDataMapCommand, visitPutForExternalReadCommand, visitPutKeyValueCommand, visitRemoveKeyCommand, visitRemoveNodeCommand, visitRollbackCommand
protected TransactionTable txTable
protected RPCManager rpcManager
protected boolean defaultSynchronous
public void injectComponents(RPCManager rpcManager, BuddyManager buddyManager, ReplicationQueue replicationQueue, TransactionTable txTable, CommandsFactory commandsFactory)
protected void checkResponses(List rsps) throws Throwable
Throwable
protected void replicateCall(InvocationContext ctx, ReplicableCommand call, boolean sync, Option o, boolean useOutOfBandMessage) throws Throwable
Throwable
protected void replicateCall(InvocationContext ctx, ReplicableCommand call, boolean sync, Option o) throws Throwable
Throwable
protected void replicateCall(InvocationContext ctx, Vector<org.jgroups.Address> recipients, ReplicableCommand c, boolean sync, Option o, boolean useOutOfBandMessage) throws Throwable
Throwable
protected void replicateCall(Vector<org.jgroups.Address> recipients, ReplicableCommand call, boolean sync, boolean wrapCacheCommandInReplicateMethod, boolean useOutOfBandMessage, boolean isBroadcast, long timeout) throws Throwable
Throwable
protected boolean skipReplicationOfTransactionMethod(InvocationContext ctx)
- call was not initiated here, but on other member of the cluster - there is no transaction. Why broadcast a commit or rollback if there is no transaction going on? - the current transaction did not modify any data
protected boolean isTransactionalAndLocal(InvocationContext ctx)
protected boolean isSynchronous(Option option)
protected boolean isLocalModeForced(InvocationContext ctx)
Copyright © 2012 JBoss, a division of Red Hat. All Rights Reserved.