org.jboss.messaging.core.plugin.postoffice.cluster
Class LocalClusteredQueue
java.lang.Object
org.jboss.messaging.core.ChannelSupport
org.jboss.messaging.core.PagingChannelSupport
org.jboss.messaging.core.local.PagingFilteredQueue
org.jboss.messaging.core.plugin.postoffice.cluster.LocalClusteredQueue
- All Implemented Interfaces:
- Channel, ClusteredQueue, DeliveryObserver, Distributor, Queue, Receiver
- public class LocalClusteredQueue
- extends PagingFilteredQueue
- implements ClusteredQueue
A LocalClusteredQueue
- Version:
- $Revision: 2735 $
$Id: LocalClusteredQueue.java 2735 2007-05-29 16:01:31Z timfox $
- Author:
- Tim Fox
Fields inherited from class org.jboss.messaging.core.ChannelSupport |
acceptReliableMessages, active, channelID, deliveringCount, maxSize, messageRefs, messagesAdded, ms, pm, receiversReady, recoverable, refLock, router, scheduledDeliveries |
Constructor Summary |
LocalClusteredQueue(ClusteredPostOffice office,
int nodeId,
java.lang.String name,
long id,
MessageStore ms,
PersistenceManager pm,
boolean acceptReliableMessages,
boolean recoverable,
int maxSize,
Filter filter,
TransactionRepository tr)
|
LocalClusteredQueue(ClusteredPostOffice office,
int nodeId,
java.lang.String name,
long id,
MessageStore ms,
PersistenceManager pm,
boolean acceptReliableMessages,
boolean recoverable,
int maxSize,
Filter filter,
TransactionRepository tr,
int fullSize,
int pageSize,
int downCacheSize)
|
Methods inherited from class org.jboss.messaging.core.PagingChannelSupport |
addFromRefInfo, addReferenceInMemory, addToDownCache, cancelInternal, doLoad, downCacheCount, flushDownCache, getMessageCount, isActive, isPaging, load, loadPagedReferences, processReferences, removeFirstInMemory, setPagingParams, unload |
Methods inherited from class org.jboss.messaging.core.ChannelSupport |
acceptReliableMessages, acknowledge, acknowledgeInternal, activate, add, browse, browse, cancel, checkAndSchedule, checkClosed, clear, clearAllScheduledDeliveries, close, contains, deactivate, deliver, deliverScheduled, getCallback, getChannelID, getDeliveringCount, getMaxSize, getMessagesAdded, getNumberOfReceivers, getScheduledCount, handleInternal, isRecoverable, iterator, memoryRefCount, processMessageBeforeStorage, recoverDeliveries, remove, removeAllReferences, setMaxSize, undelivered |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface org.jboss.messaging.core.Channel |
acceptReliableMessages, activate, browse, browse, clear, close, deactivate, deliver, getChannelID, getDeliveringCount, getMaxSize, getMessageCount, getMessagesAdded, getScheduledCount, isActive, isRecoverable, load, recoverDeliveries, removeAllReferences, setMaxSize, unload |
Methods inherited from interface org.jboss.messaging.core.Receiver |
handle |
LocalClusteredQueue
public LocalClusteredQueue(ClusteredPostOffice office,
int nodeId,
java.lang.String name,
long id,
MessageStore ms,
PersistenceManager pm,
boolean acceptReliableMessages,
boolean recoverable,
int maxSize,
Filter filter,
TransactionRepository tr,
int fullSize,
int pageSize,
int downCacheSize)
LocalClusteredQueue
public LocalClusteredQueue(ClusteredPostOffice office,
int nodeId,
java.lang.String name,
long id,
MessageStore ms,
PersistenceManager pm,
boolean acceptReliableMessages,
boolean recoverable,
int maxSize,
Filter filter,
TransactionRepository tr)
setPullQueue
public void setPullQueue(RemoteQueueStub queue)
getPullQueue
public RemoteQueueStub getPullQueue()
getStats
public QueueStats getStats()
- Specified by:
getStats
in interface ClusteredQueue
isLocal
public boolean isLocal()
- Specified by:
isLocal
in interface ClusteredQueue
getNodeId
public int getNodeId()
- Specified by:
getNodeId
in interface ClusteredQueue
toString
public java.lang.String toString()
- Overrides:
toString
in class PagingFilteredQueue
handleFromCluster
public Delivery handleFromCluster(MessageReference ref)
throws java.lang.Exception
- Throws:
java.lang.Exception
acknowledgeFromCluster
public void acknowledgeFromCluster(Delivery d)
throws java.lang.Throwable
- Throws:
java.lang.Throwable
handlePullMessagesResult
public void handlePullMessagesResult(RemoteQueueStub remoteQueue,
Message message,
long holdingTxId,
boolean failBeforeCommit,
boolean failAfterCommit)
throws java.lang.Exception
- Throws:
java.lang.Exception
handleGetDeliveriesRequest
public void handleGetDeliveriesRequest(int returnNodeId,
int number,
org.jboss.messaging.core.plugin.postoffice.cluster.TransactionId txId,
PullMessagesRequest tx)
throws java.lang.Exception
- Throws:
java.lang.Exception
isClustered
public boolean isClustered()
- Specified by:
isClustered
in interface Queue
- Overrides:
isClustered
in class PagingFilteredQueue
getRefCount
public int getRefCount()
mergeIn
public void mergeIn(RemoteQueueStub remoteQueue)
throws java.lang.Exception
- Merge the contents of one queue with another - this happens at failover when a queue is failed
over to another node, but a queue with the same name already exists. In this case we merge the
two queues.
- Throws:
java.lang.Exception
deliverInternal
protected void deliverInternal()
- Description copied from class:
ChannelSupport
- This methods delivers as many messages as possible to the router until no more deliveries are
returned. This method should never be called at the same time as handle.
- Overrides:
deliverInternal
in class ChannelSupport
- See Also:
Channel.deliver()
Copyright © 2006 JBoss Inc. All Rights Reserved.