org.jboss.cache.interceptors
Class OptimisticTxInterceptor
java.lang.Object
org.jboss.cache.commands.AbstractVisitor
org.jboss.cache.interceptors.base.CommandInterceptor
org.jboss.cache.interceptors.BaseTransactionalContextInterceptor
org.jboss.cache.interceptors.TxInterceptor
org.jboss.cache.interceptors.OptimisticTxInterceptor
- All Implemented Interfaces:
- Visitor
Deprecated. will be removed along with optimistic and pessimistic locking.
@Deprecated
public class OptimisticTxInterceptor
- extends TxInterceptor
A new interceptor to simplify functionality in the TxInterceptor
.
- Since:
- 2.2.0
- Author:
- Manik Surtani (manik AT jboss DOT org)
Field Summary |
protected org.jboss.cache.interceptors.OptimisticTxInterceptor.ModificationsReplayVisitor |
replayVisitor
Deprecated. |
Methods inherited from class org.jboss.cache.interceptors.TxInterceptor |
assertTxIsStillValid, attachGtxAndPassUpChain, createLocalTx, dumpStatistics, getCommits, getNumberOfSyncsRegistered, getPrepares, getRollbacks, getStatisticsEnabled, intialize, resetStatistics, runCommitPhase, runPreparePhase, runRollbackPhase, setStatisticsEnabled, visitCommitCommand, visitInvalidateCommand, visitPrepareCommand, visitRollbackCommand |
Methods inherited from class org.jboss.cache.commands.AbstractVisitor |
visitClearDataCommand, visitCollection, visitCreateNodeCommand, visitEvictFqnCommand, visitExistsNodeCommand, visitGetDataMapCommand, visitGetChildrenNamesCommand, visitGetKeysCommand, visitGetKeyValueCommand, visitGetNodeCommand, visitGravitateDataCommand, visitMoveCommand, visitPutDataMapCommand, visitPutForExternalReadCommand, visitPutKeyValueCommand, visitRemoveKeyCommand, visitRemoveNodeCommand |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
replayVisitor
protected final org.jboss.cache.interceptors.OptimisticTxInterceptor.ModificationsReplayVisitor replayVisitor
- Deprecated.
OptimisticTxInterceptor
public OptimisticTxInterceptor()
- Deprecated.
visitOptimisticPrepareCommand
public Object visitOptimisticPrepareCommand(InvocationContext ctx,
OptimisticPrepareCommand command)
throws Throwable
- Deprecated.
- Description copied from interface:
Visitor
- Visits a OptimisticPrepareCommand.
- Specified by:
visitOptimisticPrepareCommand
in interface Visitor
- Overrides:
visitOptimisticPrepareCommand
in class AbstractVisitor
- Parameters:
ctx
- invocation contextcommand
- command to visit
- Returns:
- response from the visit
- Throws:
Throwable
- in the event of problems.
handleDefault
public Object handleDefault(InvocationContext ctx,
VisitableCommand command)
throws Throwable
- Deprecated.
- Description copied from class:
TxInterceptor
- Tests if we already have a tx running. If so, register a sync handler for this method invocation.
if not, create a local tx if we're using opt locking.
- Overrides:
handleDefault
in class TxInterceptor
- Parameters:
ctx
- invocation contextcommand
- command to invoke
- Returns:
- return value
- Throws:
Throwable
- in the event of problems
buildPrepareCommand
protected PrepareCommand buildPrepareCommand(GlobalTransaction gtx,
List modifications,
boolean onePhaseCommit)
- Deprecated.
- Overrides:
buildPrepareCommand
in class TxInterceptor
replayModifications
protected void replayModifications(InvocationContext ctx,
Transaction ltx,
PrepareCommand command)
throws Throwable
- Deprecated.
- Replays modifications by passing them up the interceptor chain.
- Overrides:
replayModifications
in class TxInterceptor
- Throws:
Throwable
cleanupStaleLocks
protected void cleanupStaleLocks(InvocationContext ctx)
throws Throwable
- Deprecated.
- Overrides:
cleanupStaleLocks
in class TxInterceptor
- Throws:
Throwable
Copyright © 2008 JBoss, a division of Red Hat. All Rights Reserved.