public class MultiKahaDBPersistenceAdapter extends LockableServiceSupport implements PersistenceAdapter, BrokerServiceAware, NoLocalSubscriptionAware
PersistenceAdapter that supports
distribution of destinations across multiple kahaDB persistence adaptersbrokerService, clockDaemon| Constructor and Description |
|---|
MultiKahaDBPersistenceAdapter() |
| Modifier and Type | Method and Description |
|---|---|
void |
allowIOResumption() |
void |
beginTransaction(ConnectionContext context) |
void |
checkpoint(boolean cleanup) |
void |
commitTransaction(ConnectionContext context) |
Locker |
createDefaultLocker() |
JobSchedulerStore |
createJobSchedulerStore() |
MessageStore |
createQueueMessageStore(org.apache.activemq.command.ActiveMQQueue destination) |
TopicMessageStore |
createTopicMessageStore(org.apache.activemq.command.ActiveMQTopic destination) |
TransactionStore |
createTransactionStore() |
void |
deleteAllMessages() |
void |
doStart() |
protected void |
doStop(ServiceStopper stopper) |
List<PersistenceAdapter> |
getAdapters() |
Set<org.apache.activemq.command.ActiveMQDestination> |
getDestinations() |
File |
getDirectory() |
long |
getJournalCleanupInterval() |
int |
getJournalMaxFileLength() |
int |
getJournalWriteBatchSize() |
long |
getLastMessageBrokerSequenceId() |
long |
getLastProducerSequenceId(org.apache.activemq.command.ProducerId id) |
void |
init() |
boolean |
isCheckForCorruption() |
boolean |
isLocalXid(org.apache.activemq.command.TransactionId xid) |
boolean |
isPersistNoLocal() |
static String |
nameFromDestinationFilter(org.apache.activemq.command.ActiveMQDestination destination) |
void |
removeQueueMessageStore(org.apache.activemq.command.ActiveMQQueue destination) |
void |
removeTopicMessageStore(org.apache.activemq.command.ActiveMQTopic destination) |
void |
rollbackTransaction(ConnectionContext context) |
void |
setBrokerName(String brokerName) |
void |
setBrokerService(BrokerService brokerService) |
void |
setCheckForCorruption(boolean checkForCorruption) |
void |
setDirectory(File directory) |
void |
setFilteredPersistenceAdapters(List entries)
Sets the FilteredKahaDBPersistenceAdapter entries
|
void |
setJournalCleanupInterval(long journalCleanupInterval) |
void |
setJournalMaxFileLength(int maxFileLength)
Set the max file length of the transaction journal
When set using Xbean, values of the form "20 Mb", "1024kb", and "1g" can
be used
|
void |
setJournalWriteBatchSize(int journalWriteBatchSize)
Set the max write batch size of the transaction journal
When set using Xbean, values of the form "20 Mb", "1024kb", and "1g" can
be used
|
void |
setTransactionStore(MultiKahaDBTransactionStore transactionStore) |
void |
setUsageManager(SystemUsage usageManager) |
long |
size() |
String |
toString() |
getBrokerService, getLocker, getLockKeepAlivePeriod, getScheduledThreadPoolExecutor, isStopOnError, isUseLock, keepLockAlive, postStop, preStart, setLocker, setLockKeepAlivePeriod, setScheduledThreadPoolExecutor, setStopOnError, setUseLock, stopBrokeraddServiceListener, dispose, isStarted, isStopped, isStopping, removeServiceListener, start, stoppublic MultiKahaDBPersistenceAdapter()
public void setFilteredPersistenceAdapters(List entries)
public static String nameFromDestinationFilter(org.apache.activemq.command.ActiveMQDestination destination)
public boolean isLocalXid(org.apache.activemq.command.TransactionId xid)
public void beginTransaction(ConnectionContext context) throws IOException
beginTransaction in interface PersistenceAdapterIOExceptionpublic void checkpoint(boolean cleanup) throws IOException
checkpoint in interface PersistenceAdapterIOExceptionpublic void commitTransaction(ConnectionContext context) throws IOException
commitTransaction in interface PersistenceAdapterIOExceptionpublic MessageStore createQueueMessageStore(org.apache.activemq.command.ActiveMQQueue destination) throws IOException
createQueueMessageStore in interface PersistenceAdapterIOExceptionpublic TopicMessageStore createTopicMessageStore(org.apache.activemq.command.ActiveMQTopic destination) throws IOException
createTopicMessageStore in interface PersistenceAdapterIOExceptionpublic TransactionStore createTransactionStore() throws IOException
createTransactionStore in interface PersistenceAdapterIOExceptionpublic void deleteAllMessages() throws IOException
deleteAllMessages in interface PersistenceAdapterIOExceptionpublic Set<org.apache.activemq.command.ActiveMQDestination> getDestinations()
getDestinations in interface PersistenceAdapterpublic long getLastMessageBrokerSequenceId() throws IOException
getLastMessageBrokerSequenceId in interface PersistenceAdapterIOExceptionpublic long getLastProducerSequenceId(org.apache.activemq.command.ProducerId id) throws IOException
getLastProducerSequenceId in interface PersistenceAdapterIOExceptionpublic void allowIOResumption()
allowIOResumption in interface PersistenceAdapterpublic void removeQueueMessageStore(org.apache.activemq.command.ActiveMQQueue destination)
removeQueueMessageStore in interface PersistenceAdapterpublic void removeTopicMessageStore(org.apache.activemq.command.ActiveMQTopic destination)
removeTopicMessageStore in interface PersistenceAdapterpublic void rollbackTransaction(ConnectionContext context) throws IOException
rollbackTransaction in interface PersistenceAdapterIOExceptionpublic void setBrokerName(String brokerName)
setBrokerName in interface PersistenceAdapterpublic void setUsageManager(SystemUsage usageManager)
setUsageManager in interface PersistenceAdapterpublic long size()
size in interface PersistenceAdapterpublic void doStart() throws Exception
doStart in class ServiceSupportExceptionprotected void doStop(ServiceStopper stopper) throws Exception
doStop in class ServiceSupportExceptionpublic File getDirectory()
getDirectory in interface PersistenceAdapterpublic void setDirectory(File directory)
setDirectory in interface PersistenceAdapterpublic void init() throws Exception
init in class LockableServiceSupportExceptionpublic void setBrokerService(BrokerService brokerService)
setBrokerService in interface BrokerServiceAwaresetBrokerService in class LockableServiceSupportpublic void setTransactionStore(MultiKahaDBTransactionStore transactionStore)
public void setJournalMaxFileLength(int maxFileLength)
public int getJournalMaxFileLength()
public void setJournalWriteBatchSize(int journalWriteBatchSize)
public int getJournalWriteBatchSize()
public void setJournalCleanupInterval(long journalCleanupInterval)
public long getJournalCleanupInterval()
public void setCheckForCorruption(boolean checkForCorruption)
public boolean isCheckForCorruption()
public List<PersistenceAdapter> getAdapters()
public Locker createDefaultLocker() throws IOException
createDefaultLocker in interface LockableIOExceptionpublic JobSchedulerStore createJobSchedulerStore() throws IOException, UnsupportedOperationException
createJobSchedulerStore in interface PersistenceAdapterIOExceptionUnsupportedOperationExceptionpublic boolean isPersistNoLocal()
isPersistNoLocal in interface NoLocalSubscriptionAwareCopyright © 2005–2022 The Apache Software Foundation. All rights reserved.