17#ifndef _ACTIVEMQ_CORE_ACTIVEMQTRANSACTIONCONTEXT_H_
18#define _ACTIVEMQ_CORE_ACTIVEMQTRANSACTIONCONTEXT_H_
41 class ActiveMQSessionKernel;
46 class LocalTransactionEventListener;
47 class ActiveMQConnection;
63 TxContextData* context;
180 std::string getResourceManagerId()
const;
188 void afterRollback();
#define AMQCPP_API
Definition: Config.h:30
Concrete connection used for all connectors to the ActiveMQ broker.
Definition: ActiveMQConnection.h:62
Transaction Management class, hold messages that are to be redelivered upon a request to roll-back.
Definition: ActiveMQTransactionContext.h:59
virtual void removeSynchronization(const Pointer< Synchronization > &sync)
Removes a Synchronization to this Transaction.
virtual void begin()
Begins a new transaction if one is not currently in progress.
virtual bool isInLocalTransaction() const
Checks to see if there is currently an Local Transaction in progess, returns false if not,...
ActiveMQTransactionContext(activemq::core::kernels::ActiveMQSessionKernel *session, const decaf::util::Properties &properties)
Constructor.
virtual int prepare(const cms::Xid *xid)
Requests the Resource manager to prepare to commit a specified transaction.
virtual void start(const cms::Xid *xid, int flags)
Starts work for a specified transaction branch.
virtual void addSynchronization(const Pointer< Synchronization > &sync)
Adds a Synchronization to this Transaction.
virtual bool isSameRM(const cms::XAResource *theXAResource)
Returns true if the ResourceManager for this XAResource is the same as the Resource Manager for a sup...
virtual bool setTransactionTimeout(int seconds)
Sets the transaction timeout value for this XAResource.
virtual bool isInTransaction() const
Checks to see if there is currently a Transaction in progress returns false if not,...
virtual void rollback(const cms::Xid *xid)
Requests the Resource Manager to rollback a specified transaction branch.
virtual void commit(const cms::Xid *xid, bool onePhase)
Commits a global transaction.
virtual int getTransactionTimeout() const
Gets the transaction timeout value for this XAResource.
virtual void end(const cms::Xid *xid, int flags)
Ends the work done for a transaction branch.
virtual void forget(const cms::Xid *xid)
Informs the Resource Manager that it can forget about a specified transaction branch.
virtual const decaf::lang::Pointer< commands::TransactionId > & getTransactionId() const
Get the Transaction Id object for the current Transaction, returns NULL if no transaction is running.
virtual bool isInXATransaction() const
Checks to see if there is currently an XA Transaction in progress, returns false if not,...
virtual void commit()
Commit the current Transaction.
virtual ~ActiveMQTransactionContext()
virtual void rollback()
Rollback the current Transaction.
virtual int recover(int flag, cms::Xid **recovered)
Get a list of prepared transaction branches.
Definition: ActiveMQSessionKernel.h:67
CMS API Exception that is the base for all exceptions thrown from CMS classes.
Definition: CMSException.h:50
The XAException is thrown by the Resource Manager (RM) to inform the Transaction Manager of an error ...
Definition: XAException.h:32
The XAResource interface is a CMS mapping of the industry standard XA interface based on the X/Open C...
Definition: XAResource.h:44
An interface which provides a mapping for the X/Open XID transaction identifier structure.
Definition: Xid.h:37
Definition: Exception.h:38
Decaf's implementation of a Smart Pointer that is a template on a Type and is Thread Safe if the defa...
Definition: Pointer.h:53
Java-like properties class for mapping string names to string values.
Definition: Properties.h:53
Set template that wraps around a std::set to provide a more user-friendly interface and to provide co...
Definition: StlSet.h:39
#define local
Definition: gzguts.h:40
Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements.
Definition: CachedConsumer.h:24