org.apache.activemq.broker.region
Class QueueBrowserSubscription
java.lang.Object
org.apache.activemq.broker.region.AbstractSubscription
org.apache.activemq.broker.region.PrefetchSubscription
org.apache.activemq.broker.region.QueueSubscription
org.apache.activemq.broker.region.QueueBrowserSubscription
- All Implemented Interfaces:
- LockOwner, Subscription, SubscriptionRecovery
public class QueueBrowserSubscription
- extends QueueSubscription
Methods inherited from class org.apache.activemq.broker.region.PrefetchSubscription |
acknowledge, add, add, assertAckMatchesDispatched, countBeforeFull, createMessageDispatch, dispatch, dispatchPending, getDequeueCounter, getDispatchedCounter, getDispatchedQueueSize, getEnqueueCounter, getInFlightSize, getMaxAuditDepth, getMaxProducersToAudit, getPending, getPendingQueueSize, isFull, isHighWaterMark, isLowWaterMark, isRecoveryRequired, onDispatch, processMessageDispatchNotification, pullMessage, remove, sendToDLQ, setMaxAuditDepth, setMaxProducersToAudit, setPending, updateConsumerPrefetch |
Methods inherited from class org.apache.activemq.broker.region.AbstractSubscription |
addDestination, addRecoveredMessage, doAddRecoveredMessage, gc, getActiveMQDestination, getConsumerInfo, getContext, getCursorMemoryHighWaterMark, getInFlightUsage, getInfo, getObjectName, getPrefetchSize, getSelector, getSelectorExpression, isBrowser, isSlave, matches, removeDestination, setCursorMemoryHighWaterMark, setObjectName, setPrefetchSize, setSelector |
QueueBrowserSubscription
public QueueBrowserSubscription(Broker broker,
SystemUsage usageManager,
ConnectionContext context,
ConsumerInfo info)
throws InvalidSelectorException
- Throws:
InvalidSelectorException
canDispatch
protected boolean canDispatch(MessageReference node)
- Description copied from class:
PrefetchSubscription
- Use when a matched message is about to be dispatched to the client.
- Overrides:
canDispatch
in class QueueSubscription
- Returns:
- false if the message should not be dispatched to the client
(another sub may have already dispatched it for example).
toString
public String toString()
- Overrides:
toString
in class QueueSubscription
destinationsAdded
public void destinationsAdded()
throws Exception
- Throws:
Exception
matches
public boolean matches(MessageReference node,
MessageEvaluationContext context)
throws IOException
- Description copied from interface:
Subscription
- Is the subscription interested in the message?
- Specified by:
matches
in interface Subscription
- Overrides:
matches
in class AbstractSubscription
- Returns:
-
- Throws:
IOException
acknowledge
protected void acknowledge(ConnectionContext context,
MessageAck ack,
MessageReference n)
throws IOException
- Since we are a browser we don't really remove the message from the queue.
- Overrides:
acknowledge
in class QueueSubscription
- Throws:
IOException
incrementQueueRef
public void incrementQueueRef()
decrementQueueRef
public void decrementQueueRef()
throws Exception
- Throws:
Exception
Copyright © 2005-2011 Apache Software Foundation. All Rights Reserved.