|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.activemq.broker.region.policy.FixedSizedSubscriptionRecoveryPolicy
public class FixedSizedSubscriptionRecoveryPolicy
This implementation of SubscriptionRecoveryPolicy
will keep a fixed
amount of memory available in RAM for message history which is evicted in
time order.
Constructor Summary | |
---|---|
FixedSizedSubscriptionRecoveryPolicy()
|
Method Summary | |
---|---|
boolean |
add(ConnectionContext context,
MessageReference message)
A message was sent to the destination. |
Message[] |
browse(ActiveMQDestination destination)
|
SubscriptionRecoveryPolicy |
copy()
Used to copy the policy object. |
protected MessageList |
createMessageList()
|
MessageList |
getBuffer()
|
int |
getMaximumSize()
|
boolean |
isUseSharedBuffer()
|
void |
recover(ConnectionContext context,
Topic topic,
Subscription sub)
Let a subscription recover message held by the policy. |
void |
setBuffer(MessageList buffer)
|
void |
setMaximumSize(int maximumSize)
Sets the maximum amount of RAM in bytes that this buffer can hold in RAM |
void |
setUseSharedBuffer(boolean useSharedBuffer)
|
void |
start()
|
void |
stop()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FixedSizedSubscriptionRecoveryPolicy()
Method Detail |
---|
public SubscriptionRecoveryPolicy copy()
SubscriptionRecoveryPolicy
copy
in interface SubscriptionRecoveryPolicy
public boolean add(ConnectionContext context, MessageReference message) throws java.lang.Exception
SubscriptionRecoveryPolicy
add
in interface SubscriptionRecoveryPolicy
java.lang.Exception
public void recover(ConnectionContext context, Topic topic, Subscription sub) throws java.lang.Exception
SubscriptionRecoveryPolicy
recover
in interface SubscriptionRecoveryPolicy
java.lang.Exception
public void start() throws java.lang.Exception
start
in interface Service
java.lang.Exception
public void stop() throws java.lang.Exception
stop
in interface Service
java.lang.Exception
public MessageList getBuffer()
public void setBuffer(MessageList buffer)
public int getMaximumSize()
public void setMaximumSize(int maximumSize)
public boolean isUseSharedBuffer()
public void setUseSharedBuffer(boolean useSharedBuffer)
public Message[] browse(ActiveMQDestination destination) throws java.lang.Exception
browse
in interface SubscriptionRecoveryPolicy
java.lang.Exception
protected MessageList createMessageList()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |