org.apache.activemq.store.memory
Class MemoryTransactionStore
java.lang.Object
org.apache.activemq.store.memory.MemoryTransactionStore
- All Implemented Interfaces:
- Service, TransactionStore
public class MemoryTransactionStore
- extends Object
- implements TransactionStore
Provides a TransactionStore implementation that can create transaction aware
MessageStore objects from non transaction aware MessageStore objects.
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
inflightTransactions
protected ConcurrentHashMap<Object,MemoryTransactionStore.Tx> inflightTransactions
preparedTransactions
protected ConcurrentHashMap<TransactionId,MemoryTransactionStore.Tx> preparedTransactions
persistenceAdapter
protected final PersistenceAdapter persistenceAdapter
MemoryTransactionStore
public MemoryTransactionStore(PersistenceAdapter persistenceAdapter)
proxy
public MessageStore proxy(MessageStore messageStore)
proxy
public TopicMessageStore proxy(TopicMessageStore messageStore)
onProxyTopicStore
protected void onProxyTopicStore(ProxyTopicMessageStore proxyTopicMessageStore)
prepare
public void prepare(TransactionId txid)
throws IOException
- Specified by:
prepare in interface TransactionStore
- Throws:
IOException- See Also:
TransactionStore.prepare(TransactionId)
getTx
public MemoryTransactionStore.Tx getTx(Object txid)
getPreparedTx
public MemoryTransactionStore.Tx getPreparedTx(TransactionId txid)
commit
public void commit(TransactionId txid,
boolean wasPrepared,
Runnable preCommit,
Runnable postCommit)
throws IOException
- Specified by:
commit in interface TransactionStore
- Throws:
IOException
rollback
public void rollback(TransactionId txid)
throws IOException
- Specified by:
rollback in interface TransactionStore
- Throws:
IOException- See Also:
TransactionStore.rollback(TransactionId)
start
public void start()
throws Exception
- Specified by:
start in interface Service
- Throws:
Exception
stop
public void stop()
throws Exception
- Specified by:
stop in interface Service
- Throws:
Exception
recover
public void recover(TransactionRecoveryListener listener)
throws IOException
- Specified by:
recover in interface TransactionStore
- Throws:
IOException
onRecovered
protected void onRecovered(MemoryTransactionStore.Tx tx)
acknowledge
public void acknowledge(TopicMessageStore destination,
String clientId,
String subscriptionName,
MessageId messageId,
MessageAck ack)
throws IOException
- Throws:
IOException
delete
public void delete()
Copyright © 2005-2013 The Apache Software Foundation. All Rights Reserved.