org.codehaus.activemq.service
Interface TransactionManager

All Superinterfaces:
Service
All Known Implementing Classes:
TransactionManagerImpl

public interface TransactionManager
extends Service

A Transaction keeps track of all the tasks that must be run before and after transactional events.

Version:
$Revision: 1.5 $

Method Summary
 void cleanUpClient(BrokerClient client)
          A hint to the TransactionManager that an BrokerClient has stopped This enables the TransactionManager to rollback in progess transactions that the client created.
 Transaction createLocalTransaction(BrokerClient client, String txid)
           
 Transaction createXATransaction(BrokerClient client, ActiveMQXid xid)
           
 Transaction getContexTransaction()
           
 Transaction getLocalTransaction(String txid)
           
 ActiveMQXid[] getPreparedXATransactions()
           
 Transaction getXATransaction(ActiveMQXid xid)
           
 void loadTransaction(ActiveMQXid xid, Transaction transaction)
          Called on restart when recovering prepared transactions to reload a transaction from persistent store
 void setContexTransaction(Transaction tx)
           
 
Methods inherited from interface org.codehaus.activemq.service.Service
start, stop
 

Method Detail

setContexTransaction

public void setContexTransaction(Transaction tx)

getContexTransaction

public Transaction getContexTransaction()

createLocalTransaction

public Transaction createLocalTransaction(BrokerClient client,
                                          String txid)
                                   throws JMSException
Throws:
JMSException

getLocalTransaction

public Transaction getLocalTransaction(String txid)
                                throws JMSException
Throws:
JMSException

createXATransaction

public Transaction createXATransaction(BrokerClient client,
                                       ActiveMQXid xid)
                                throws XAException
Throws:
XAException

getXATransaction

public Transaction getXATransaction(ActiveMQXid xid)
                             throws XAException
Throws:
XAException

getPreparedXATransactions

public ActiveMQXid[] getPreparedXATransactions()
                                        throws XAException
Throws:
XAException

cleanUpClient

public void cleanUpClient(BrokerClient client)
                   throws JMSException
A hint to the TransactionManager that an BrokerClient has stopped This enables the TransactionManager to rollback in progess transactions that the client created.

Parameters:
client -
Throws:
JMSException

loadTransaction

public void loadTransaction(ActiveMQXid xid,
                            Transaction transaction)
                     throws XAException
Called on restart when recovering prepared transactions to reload a transaction from persistent store

Parameters:
xid -
transaction -
Throws:
XAException


Copyright © 2004 Protique, Ltd.. All Rights Reserved.