public class TempKahaDBStore.KahaDBMessageStore extends AbstractMessageStore
Modifier and Type | Field and Description |
---|---|
protected KahaDestination |
dest |
destination, FUTURE, prioritizedMessages
Constructor and Description |
---|
TempKahaDBStore.KahaDBMessageStore(ActiveMQDestination destination) |
Modifier and Type | Method and Description |
---|---|
void |
addMessage(ConnectionContext context,
Message message)
Adds a message to the message store
|
ActiveMQDestination |
getDestination()
The destination that the message store is holding messages for.
|
Message |
getMessage(MessageId identity)
Looks up a message using either the String messageID or the
messageNumber.
|
int |
getMessageCount() |
void |
recover(MessageRecoveryListener listener)
Recover any messages to be delivered.
|
void |
recoverNextMessages(int maxReturned,
MessageRecoveryListener listener) |
void |
removeAllMessages(ConnectionContext context)
Removes all the messages from the message store.
|
void |
removeMessage(ConnectionContext context,
MessageAck ack)
Removes a message from the message store.
|
void |
resetBatching()
A hint to the Store to reset any batching state for the Destination
|
void |
setBatch(MessageId identity)
allow caching cursors to set the current batch offset when cache is exhausted
|
void |
setMemoryUsage(MemoryUsage memoeyUSage) |
void |
start() |
void |
stop() |
addMessage, asyncAddQueueMessage, asyncAddQueueMessage, asyncAddTopicMessage, asyncAddTopicMessage, dispose, isEmpty, isPrioritizedMessages, removeAsyncMessage, setPrioritizedMessages
protected KahaDestination dest
public TempKahaDBStore.KahaDBMessageStore(ActiveMQDestination destination)
public ActiveMQDestination getDestination()
MessageStore
getDestination
in interface MessageStore
getDestination
in class AbstractMessageStore
public void addMessage(ConnectionContext context, Message message) throws IOException
MessageStore
context
- contextIOException
public void removeMessage(ConnectionContext context, MessageAck ack) throws IOException
MessageStore
ack
- the ack request that cause the message to be removed. It
conatins the identity which contains the messageID of the
message that needs to be removed.IOException
public void removeAllMessages(ConnectionContext context) throws IOException
MessageStore
IOException
public Message getMessage(MessageId identity) throws IOException
MessageStore
identity
- which contains either the messageID or the messageNumberIOException
public int getMessageCount() throws IOException
IOException
public void recover(MessageRecoveryListener listener) throws Exception
MessageStore
Exception
public void recoverNextMessages(int maxReturned, MessageRecoveryListener listener) throws Exception
Exception
public void resetBatching()
MessageStore
public void setBatch(MessageId identity) throws IOException
MessageStore
setBatch
in interface MessageStore
setBatch
in class AbstractMessageStore
IOException
public void setMemoryUsage(MemoryUsage memoeyUSage)
setMemoryUsage
in interface MessageStore
setMemoryUsage
in class AbstractMessageStore
memoeyUSage
- The SystemUsage that is controlling the
destination's memory usage.public void start() throws Exception
start
in interface Service
start
in class AbstractMessageStore
Exception
Copyright © 2005-2013 The Apache Software Foundation. All Rights Reserved.