Skip navigation links
TIBCO Enterprise Message Service
com.tibco.tibjms.admin

Class ConsumerInfo.Details

  • Enclosing class:
    ConsumerInfo


    public static class ConsumerInfo.Details
    extends java.lang.Object
    Provides additional information about consumer.
    Since:
    EMS 4.4
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      static ConsumerInfo.Details from(javax.management.openmbean.CompositeData cd) 
      long getCurrentMsgCountSentByServer()
      Returns number of messages sent to consumer and not yet acknowledged by consumer's session.
      long getCurrentMsgSizeSentByServer()
      Returns combined size of messages sent to consumer and not yet acknowledged by consumer's session.
      int getDestinationPrefetch()
      Returns destination prefetch value.
      long getElapsedSinceLastAcknowledged()
      Returns number of milliseconds elapsed since last time a message sent to this consumer was acknowledged by consumer's session.
      long getElapsedSinceLastSent()
      Returns number of milliseconds elapsed since last time the server sent a message to this consumer.
      int getPrefetchDelivered()
      Returns number of prefetch messages delivered to consumer by the server.
      java.lang.String getRouteName()
      Returns queue owner server name if this consumer's destination is a routed queue.
      int getSessionAcknowledgeMode()
      Returns consumer's session acknowledge mode as a constant defined in TibjmsAdmin.
      long getTotalAcknowledgedCount()
      Returns total number of messages which were delivered to this consumer and have been acknowledged by consumer's session.
      long getTotalMsgCountSentByServer()
      Returns total number of messages the server sent to this consumer since consumer was created.
      boolean isActive()
      Returns true if this consumer is active.
      boolean isSystem()
      Returns true if this consumer has been created automatically by the system.
      java.lang.String toString()
      Returns string representation of this object.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Method Detail

      • getRouteName

        public java.lang.String getRouteName()
        Returns queue owner server name if this consumer's destination is a routed queue. Returns null for topic consumers and for queue consumers receiving messages from queues local to the server.
        Returns:
        queue owner server name or null
      • getDestinationPrefetch

        public int getDestinationPrefetch()
        Returns destination prefetch value. This returns actual destination prefetch value used by the server at run time. Return value is a positive prefetch value or DestinationInfo.PREFETCH_NONE which is available for queues.
        Returns:
        destination prefetch value as positive value or DestinationInfo.PREFETCH_NONE for queues configured as no-prefetch queue.
      • getPrefetchDelivered

        public int getPrefetchDelivered()
        Returns number of prefetch messages delivered to consumer by the server. This value should be ignored for consumers on no-prefetch queues. For consumers receiving messages on any destination with positive prefetch value, this value is never more than the prefetch value of the destination. While normally this value cannot be used to identify the status of the consumer, it can be used in conjunction with other consumer information values to identify consumers who stopped receiving messages due to application-specific problems.
        Returns:
        number of messages delivered to consumer within prefetch window.
      • getCurrentMsgCountSentByServer

        public long getCurrentMsgCountSentByServer()
        Returns number of messages sent to consumer and not yet acknowledged by consumer's session. For topic consumers this number is included into the number of pending messages returned by ConsumerInfo.getPendingMessageCount().
        Returns:
        number of sent messages, possibly 0.
      • getCurrentMsgSizeSentByServer

        public long getCurrentMsgSizeSentByServer()
        Returns combined size of messages sent to consumer and not yet acknowledged by consumer's session. For topic consumers this size is included into the combined size of pending messages returned by ConsumerInfo.getPendingMessageSize().
        Returns:
        combined size of sent messages, possibly 0.
      • getElapsedSinceLastSent

        public long getElapsedSinceLastSent()
        Returns number of milliseconds elapsed since last time the server sent a message to this consumer. This value, while returned in milliseconds, has a precision of 1 second. It should be used for informational purposes only.
        Returns:
        approximate number of milliseconds elapsed since last time the server sent a message to this consumer.
      • getElapsedSinceLastAcknowledged

        public long getElapsedSinceLastAcknowledged()
        Returns number of milliseconds elapsed since last time a message sent to this consumer was acknowledged by consumer's session. This value, while returned in milliseconds, has a precision of 1 second. This value should be used for informational purposes only. It can be used, for example, to identify consumers which receive messages but do not acknowledge them for some reason, etc.
        Returns:
        approximate number of milliseconds elapsed since last time a message delivered to this consumer has been acknowledged by consumer's session.
      • getTotalMsgCountSentByServer

        public long getTotalMsgCountSentByServer()
        Returns total number of messages the server sent to this consumer since consumer was created. This value includes resends of the same message due to consumer's session recover or rollback. This value does not represent true number of unique messages received by this consumer and should be used only for statistical and informational purposes.
        Returns:
        number of messages sent by server to this consumer since consumer was created, including resends.
      • getTotalAcknowledgedCount

        public long getTotalAcknowledgedCount()
        Returns total number of messages which were delivered to this consumer and have been acknowledged by consumer's session. This value should be used for informational purposes only.
        Returns:
        total number of acknowledged messages which were received via this consumer.
      • isSystem

        public boolean isSystem()
        Returns true if this consumer has been created automatically by the system. If this method returns false, this consumer has been created by user application. If this method returns true this consumer has been created automatically by the system. There are several types of consumers the system may create automatically.
        Returns:
        true if this consumer has been created by EMS server and not by application.
      • isActive

        public boolean isActive()
        Returns true if this consumer is active. Active are consumers which the server can send messages to. Only queue consumers which never called receive() remain in inactive state. Queue consumers which called receive at least once or are configured with the message callback, and all topic consumers are always active. This method can identify inactive queue consumers which never called receive and, while present, never receive any messages from the server even in presence of pending messages in corresponding queue.
        Returns:
        false if this is a queue consumer which is not configured with the message callback and never called receive(). Returns true in all other cases.
      • toString

        public java.lang.String toString()
        Returns string representation of this object.
        Overrides:
        toString in class java.lang.Object
      • from

        public static ConsumerInfo.Details from(javax.management.openmbean.CompositeData cd)
                                         throws java.lang.Exception
        Throws:
        java.lang.Exception
TIBCO Enterprise Message Service

Copyright © Cloud Software Group, Inc. All rights reserved