org.jboss.mq.server.jmx
Class Queue

java.lang.Object
  extended by org.jboss.mx.util.JBossNotificationBroadcasterSupport
      extended by org.jboss.system.ServiceMBeanSupport
          extended by org.jboss.mq.server.jmx.DestinationMBeanSupport
              extended by org.jboss.mq.server.jmx.Queue
All Implemented Interfaces:
javax.management.MBeanRegistration, javax.management.NotificationBroadcaster, javax.management.NotificationEmitter, DestinationMBean, QueueMBean, org.jboss.system.Service, org.jboss.system.ServiceMBean

public class Queue
extends DestinationMBeanSupport
implements QueueMBean

This class is a message queue which is stored (hashed by Destination) on the JMS provider

Version:
$Revision: 1.10.4.6 $
Author:
Norbert Lataille (Norbert.Lataille@m4x.org), Hiram Chirino, Peter Antman

Field Summary
 
Fields inherited from class org.jboss.mq.server.jmx.DestinationMBeanSupport
destinationName, jbossMQService, jndiBound, jndiName, parameters, securityConf, securityManager, spyDest
 
Fields inherited from class org.jboss.system.ServiceMBeanSupport
log, server, SERVICE_CONTROLLER_SIG, serviceName
 
Fields inherited from interface org.jboss.system.ServiceMBean
CREATE_EVENT, CREATED, DESTROY_EVENT, DESTROYED, FAILED, REGISTERED, START_EVENT, STARTED, STARTING, states, STOP_EVENT, STOPPED, STOPPING, UNREGISTERED
 
Constructor Summary
Queue()
           
 
Method Summary
 MessageCounter[] getMessageCounter()
          Get destination message counter array
 MessageStatistics[] getMessageStatistics()
          Get destination stats array
 int getQueueDepth()
          Gets the QueueDepth attribute of the BasicQueue object
 String getQueueName()
          Get the queue name
 int getReceiversCount()
          Get the number of active receivers
 int getScheduledMessageCount()
          Gets the ScheduledMessageCount attribute of the BasicQueue object
 int getSubscribersCount()
          Get the number of active subscribers
 List listMessages()
          List the messages
 List listMessages(String selector)
          List the messages matching a selector
 List listReceivers()
          List the active receivers
 Collection listSubscribers()
          List the active subscribers
 void removeAllMessages()
          Get the value of JBossMQService.
 void startService()
           
 void stopService()
           
 
Methods inherited from class org.jboss.mq.server.jmx.DestinationMBeanSupport
createService, getDestinationManager, getExpiryDestination, getInitialContext, getInMemory, getJNDIName, getMaxDepth, getMessageCounterHistoryDayLimit, getObjectName, getReceiversImpl, getRecoveryRetries, getRedeliveryDelay, getRedeliveryLimit, getSecurityConf, getSecurityManager, getSpyDest, listMessageCounter, listMessageCounterHistory, resetMessageCounter, resetMessageCounterHistory, setDestinationManager, setExpiryDestination, setInMemory, setJNDIName, setMaxDepth, setMessageCounterHistoryDayLimit, setReceiversImpl, setRecoveryRetries, setRedeliveryDelay, setRedeliveryLimit, setSecurityConf, setSecurityManager, setupExpiryDestination, setupSecurityManager, teardownSecurityManager
 
Methods inherited from class org.jboss.system.ServiceMBeanSupport
create, destroy, destroyService, getDeploymentInfo, getLog, getName, getNextNotificationSequenceNumber, getServer, getServiceName, getState, getStateString, jbossInternalCreate, jbossInternalDescription, jbossInternalDestroy, jbossInternalLifecycle, jbossInternalStart, jbossInternalStop, postDeregister, postRegister, preDeregister, preRegister, start, stop
 
Methods inherited from class org.jboss.mx.util.JBossNotificationBroadcasterSupport
addNotificationListener, getNotificationInfo, handleNotification, nextNotificationSequenceNumber, removeNotificationListener, removeNotificationListener, sendNotification
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.jboss.mq.server.jmx.DestinationMBean
getDestinationManager, getExpiryDestination, getInMemory, getJNDIName, getMaxDepth, getMessageCounterHistoryDayLimit, getReceiversImpl, getRecoveryRetries, getRedeliveryDelay, getRedeliveryLimit, listMessageCounter, listMessageCounterHistory, resetMessageCounter, resetMessageCounterHistory, setDestinationManager, setExpiryDestination, setInMemory, setJNDIName, setMaxDepth, setMessageCounterHistoryDayLimit, setReceiversImpl, setRecoveryRetries, setRedeliveryDelay, setRedeliveryLimit, setSecurityConf, setSecurityManager
 
Methods inherited from interface org.jboss.system.ServiceMBean
getName, getState, getStateString, jbossInternalLifecycle
 
Methods inherited from interface org.jboss.system.Service
create, destroy, start, stop
 
Methods inherited from interface javax.management.MBeanRegistration
postDeregister, postRegister, preDeregister, preRegister
 

Constructor Detail

Queue

public Queue()
Method Detail

getQueueName

public String getQueueName()
Description copied from interface: QueueMBean
Get the queue name

Specified by:
getQueueName in interface QueueMBean
Returns:
the queue name

getQueueDepth

public int getQueueDepth()
                  throws Exception
Description copied from interface: QueueMBean
Gets the QueueDepth attribute of the BasicQueue object

Specified by:
getQueueDepth in interface QueueMBean
Returns:
The QueueDepth value
Throws:
Exception - Description of Exception

getScheduledMessageCount

public int getScheduledMessageCount()
                             throws Exception
Description copied from interface: QueueMBean
Gets the ScheduledMessageCount attribute of the BasicQueue object

Specified by:
getScheduledMessageCount in interface QueueMBean
Returns:
The ScheduledMessageCount value
Throws:
Exception - Description of Exception

startService

public void startService()
                  throws Exception
Overrides:
startService in class DestinationMBeanSupport
Throws:
Exception

stopService

public void stopService()
                 throws Exception
Overrides:
stopService in class DestinationMBeanSupport
Throws:
Exception

removeAllMessages

public void removeAllMessages()
                       throws Exception
Description copied from interface: DestinationMBean
Get the value of JBossMQService.

Specified by:
removeAllMessages in interface DestinationMBean
Throws:
Exception

getReceiversCount

public int getReceiversCount()
Description copied from interface: QueueMBean
Get the number of active receivers

Specified by:
getReceiversCount in interface QueueMBean
Returns:
the number of receivers

listReceivers

public List listReceivers()
Description copied from interface: QueueMBean
List the active receivers

Specified by:
listReceivers in interface QueueMBean
Returns:
the receivers

listMessages

public List listMessages()
                  throws Exception
Description copied from interface: QueueMBean
List the messages

Specified by:
listMessages in interface QueueMBean
Returns:
the messages
Throws:
Exception - for any error

listMessages

public List listMessages(String selector)
                  throws Exception
Description copied from interface: QueueMBean
List the messages matching a selector

Specified by:
listMessages in interface QueueMBean
Parameters:
selector - the selector
Returns:
the messages
Throws:
Exception - for any error

getMessageCounter

public MessageCounter[] getMessageCounter()
Description copied from class: DestinationMBeanSupport
Get destination message counter array

Specified by:
getMessageCounter in interface DestinationMBean
Specified by:
getMessageCounter in class DestinationMBeanSupport
Returns:
MessageCounter[]

getMessageStatistics

public MessageStatistics[] getMessageStatistics()
                                         throws Exception
Description copied from class: DestinationMBeanSupport
Get destination stats array

Specified by:
getMessageStatistics in interface DestinationMBean
Specified by:
getMessageStatistics in class DestinationMBeanSupport
Returns:
MessageStatistics[]
Throws:
Exception - for any error

getSubscribersCount

public int getSubscribersCount()
Description copied from interface: QueueMBean
Get the number of active subscribers

Specified by:
getSubscribersCount in interface QueueMBean
Returns:
the number of subscribers

listSubscribers

public Collection listSubscribers()
Description copied from interface: QueueMBean
List the active subscribers

Specified by:
listSubscribers in interface QueueMBean
Returns:
the subscribers


Copyright © 2002 JBoss Group, LLC. All Rights Reserved.