Interface TopicMBean


@MXBean public interface TopicMBean

The TopicMBean is enabled by the wasJmsServer feature. A TopicMBean is initialized for each Topic existing on the messaging engine. Use the MBean programming interface to query runtime information about a Topic.

JMX clients should use the ObjectName of this MBean to query it
Partial Object Name: WebSphere:feature=wasJmsServer, type=Topic,name=*
where name is unique for each Topic and is equal to the name of the Topic.

  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Delete a subscription
    void
    deleteSubscriptionMessage(String subId, String messageId, Boolean move)
    Delete a specific message on the Subscription.
    long
    Total number of unique messages on this Topic which are not yet passed to all subscribers
    The UUID of the Topic represented by this instance.
    The identifier (name) attribute of the Topic represented by this instance.
    long
    The maximum number of messages permitted at the Topic
    com.ibm.ws.sib.admin.mxbean.MessagingSubscription
    Get an object representing a specified Subscription
    com.ibm.ws.sib.admin.mxbean.MessagingSubscription
    Get an object representing a specified Subscription
    com.ibm.ws.sib.admin.mxbean.QueuedMessage
    Get a message object representing one specific message on a specified Subscription.
    byte[]
    getSubscriptionMessageData(String subId, String messageId, Integer size)
    Get the data content, or payload, of one specific message on the Subscription.
    com.ibm.ws.sib.admin.mxbean.QueuedMessageDetail
    Get a message object containing detailed information on one specific message on a specified Subscription.
    com.ibm.ws.sib.admin.mxbean.QueuedMessage[]
    Get an array of message objects representing the messages on a specified Subscription.
    boolean
    Can producers send to this Topic?
    com.ibm.ws.sib.admin.mxbean.MessagingSubscription[]
    List an array of objects representing all Subscriptions at this Topic
  • Method Details

    • getId

      String getId()
      The UUID of the Topic represented by this instance.
      Returns:
      ID of the Topic
    • getIdentifier

      String getIdentifier()
      The identifier (name) attribute of the Topic represented by this instance.
      Returns:
      Name of the Topic
    • getMaxQueueSize

      long getMaxQueueSize()
      The maximum number of messages permitted at the Topic
      Returns:
      Maximum number of messages permitted for the Topic
    • isSendAllowed

      boolean isSendAllowed()
      Can producers send to this Topic?
      Returns:
      true if send is allowed on the Topic else false
    • getDepth

      long getDepth()
      Total number of unique messages on this Topic which are not yet passed to all subscribers
      Returns:
      Number of messages present on the Topic
    • listSubscriptions

      com.ibm.ws.sib.admin.mxbean.MessagingSubscription[] listSubscriptions() throws Exception
      List an array of objects representing all Subscriptions at this Topic
      Returns:
      Array of Subscriptions for the Topic
      Throws:
      Exception
    • getSubscription

      com.ibm.ws.sib.admin.mxbean.MessagingSubscription getSubscription(String subId) throws Exception
      Get an object representing a specified Subscription
      Parameters:
      subId - the ID of the subscription
      Returns:
      Subscription represented by the Subscription ID
      Throws:
      Exception
    • getSubscriptionByName

      com.ibm.ws.sib.admin.mxbean.MessagingSubscription getSubscriptionByName(String subName) throws Exception
      Get an object representing a specified Subscription
      Parameters:
      subName - the name of the subscription( name is represented as clientId##subscription name)
      Returns:
      Subscription represented by the Subscription name
      Throws:
      Exception
    • deleteSubscription

      void deleteSubscription(String subId) throws Exception
      Delete a subscription
      Parameters:
      subId -
      Throws:
      com.ibm.ws.sib.admin.exception.InvalidArgumentException
      com.ibm.ws.sib.admin.exception.ControllableNotFoundException
      com.ibm.ws.sib.admin.exception.RuntimeOperationFailedException
      Exception
    • getSubscriptionMessages

      com.ibm.ws.sib.admin.mxbean.QueuedMessage[] getSubscriptionMessages(String subId) throws Exception
      Get an array of message objects representing the messages on a specified Subscription.
      Returns:
      Array of messages ready to be subscribed by the Subscription representing Subscription ID
      Throws:
      Exception
    • getSubscriptionMessage

      com.ibm.ws.sib.admin.mxbean.QueuedMessage getSubscriptionMessage(String subId, String messageId) throws Exception
      Get a message object representing one specific message on a specified Subscription.
      Parameters:
      subId - the ID of the subscription
      messageId - the ID of the message
      Returns:
      Message representing the Message ID and ready to be consumed by Subscription representing Subscription ID
      Throws:
      Exception
    • getSubscriptionMessageDetail

      com.ibm.ws.sib.admin.mxbean.QueuedMessageDetail getSubscriptionMessageDetail(String subId, String messageId) throws Exception
      Get a message object containing detailed information on one specific message on a specified Subscription.
      Parameters:
      subId - the ID of the subscription
      messageId - the ID of the message
      Returns:
      Message representing the Message ID and ready to be consumed by Subscription representing Subscription ID
      Throws:
      Exception
    • getSubscriptionMessageData

      byte[] getSubscriptionMessageData(String subId, String messageId, Integer size) throws Exception
      Get the data content, or payload, of one specific message on the Subscription.
      Parameters:
      subId - the ID of the subscription
      messageId - the ID of the message
      size - the number of bytes to return. If the size is specified as zero, or the size exceeds the length of the data content, then the entire message content is returned.
      Returns:
      Byte Array representing the Message Payload
      Throws:
      Exception
    • deleteSubscriptionMessage

      void deleteSubscriptionMessage(String subId, String messageId, Boolean move) throws Exception
      Delete a specific message on the Subscription.
      Parameters:
      subId - the ID of the subscription
      messageId - the ID of the message
      move - flag indicating whether the message should be discarded. If false, then the message is physically deleted. If true, the message is moved to the exception destination for this queue, if one exists.
      Throws:
      Exception