|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.jboss.cache.interceptors.Interceptor org.jboss.cache.interceptors.BaseTransactionalContextInterceptor org.jboss.cache.interceptors.TxInterceptor
public class TxInterceptor
This interceptor is the new default at the head of all interceptor chains, and makes transactional attributes available to all interceptors in the chain. This interceptor is also responsible for registering for synchronisation on transaction completion.
Field Summary |
---|
Fields inherited from class org.jboss.cache.interceptors.BaseTransactionalContextInterceptor |
---|
txManager, txTable |
Fields inherited from class org.jboss.cache.interceptors.Interceptor |
---|
cache, configuration, last, log, next |
Constructor Summary | |
---|---|
TxInterceptor()
|
Method Summary | |
---|---|
java.util.Map<java.lang.String,java.lang.Object> |
dumpStatistics()
This implementation returns an empty Map. |
long |
getCommits()
Returns the number of transaction commits |
long |
getPrepares()
Returns the number of transaction prepares |
long |
getRollbacks()
Returns the number of transaction rollbacks |
java.lang.Object |
invoke(InvocationContext ctx)
|
void |
resetStatistics()
This implementation is a no-op. |
protected void |
runCommitPhase(InvocationContext ctx,
GlobalTransaction gtx,
javax.transaction.Transaction tx,
java.util.List modifications,
boolean onePhaseCommit)
creates a commit() MethodCall and feeds it to handleCommitRollback(); |
protected java.lang.Object |
runPreparePhase(InvocationContext ctx,
GlobalTransaction gtx,
java.util.List modifications)
Handles a local prepare - invoked by the sync handler. |
protected void |
runRollbackPhase(InvocationContext ctx,
GlobalTransaction gtx,
javax.transaction.Transaction tx,
java.util.List modifications)
creates a rollback() MethodCall and feeds it to handleCommitRollback(); |
Methods inherited from class org.jboss.cache.interceptors.BaseTransactionalContextInterceptor |
---|
copyInvocationScopeOptionsToTxScope, isRollingBack, setCache, setTransactionalContext |
Methods inherited from class org.jboss.cache.interceptors.Interceptor |
---|
getLast, getNext, getStatisticsEnabled, isActive, isOnePhaseCommitPrepareMehod, isPreparing, isValid, setLast, setNext, setStatisticsEnabled, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface org.jboss.cache.interceptors.InterceptorMBean |
---|
getStatisticsEnabled, setStatisticsEnabled |
Constructor Detail |
---|
public TxInterceptor()
Method Detail |
---|
public java.lang.Object invoke(InvocationContext ctx) throws java.lang.Throwable
invoke
in class Interceptor
java.lang.Throwable
public long getPrepares()
TxInterceptorMBean
getPrepares
in interface TxInterceptorMBean
public long getCommits()
TxInterceptorMBean
getCommits
in interface TxInterceptorMBean
public long getRollbacks()
TxInterceptorMBean
getRollbacks
in interface TxInterceptorMBean
public void resetStatistics()
Interceptor
resetStatistics
in interface InterceptorMBean
resetStatistics
in class Interceptor
public java.util.Map<java.lang.String,java.lang.Object> dumpStatistics()
Interceptor
dumpStatistics
in interface InterceptorMBean
dumpStatistics
in class Interceptor
protected void runCommitPhase(InvocationContext ctx, GlobalTransaction gtx, javax.transaction.Transaction tx, java.util.List modifications, boolean onePhaseCommit)
gtx
- protected void runRollbackPhase(InvocationContext ctx, GlobalTransaction gtx, javax.transaction.Transaction tx, java.util.List modifications)
gtx
- protected java.lang.Object runPreparePhase(InvocationContext ctx, GlobalTransaction gtx, java.util.List modifications) throws java.lang.Throwable
java.lang.Throwable
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |