The destination monitor MBean is used for monitoring a destination. There is one such MBean for each destination.
The destination monitor MBean has an object name of the following form:
com.sun.messaging.jms.server:type=Destination,subtype=Monitor,desttype=destinationType,name=destinationName
where destinationType is one of the destination types shown in Table 3–39 and destinationName is the name of the destination. For example:
com.sun.messaging.jms.server:type=Destination,subtype=Monitor,desttype=t,name="Dest"
The utility class MQObjectName provides a static method, createDestinationMonitor, for constructing object names of this form.
The destination monitor MBean has the attributes shown in Table 3–38. The names of these attributes are defined as static constants in the utility class DestinationAttributes.
Table 3–38 Destination Monitor Attributes
Name |
Type |
Settable? |
Description |
---|---|---|---|
String |
No |
Destination name |
|
String |
No |
Destination type See Table 3–39 for possible values. |
|
CreatedByAdmin |
Boolean |
No |
Administrator-created destination? |
Temporary |
Boolean |
No |
Temporary destination? |
String |
No | ||
Integer |
No |
Current state See Table 3–40 for possible values. |
|
String |
No |
String representation of current state: Useful for displaying the state in human-readable form, such as in the Java Monitoring and Management Console (jconsole). See Table 3–40 for possible values. |
|
Integer |
No |
Current number of associated message producers |
|
Integer |
No |
Current number of associated message consumers For queue destinations, this attribute includes both active and backup consumers. For topic destinations, it includes both nondurable and (active and inactive) durable subscribers and is equivalent to NumActiveConsumers. |
|
Integer |
No |
Current number of wildcard message producers associated with the destination For topic destinations only. |
|
Integer |
No |
Current number of wildcard message consumers associated with the destination For topic destinations only. |
|
Integer |
No |
Current number of wildcard message producers and wildcard message consumers associated with the destination For topic destinations only. |
|
Integer |
No |
Peak number of associated message consumers since broker started For queue destinations, this attribute includes both active and backup consumers. For topic destinations, it includes both nondurable and (active and inactive) durable subscribers and is equivalent to PeakNumActiveConsumers. |
|
Integer |
No |
Average number of associated message consumers since broker started For queue destinations, this attribute includes both active and backup consumers. For topic destinations, it includes both nondurable and (active and inactive) durable subscribers and is equivalent to AvgNumActiveConsumers. |
|
Integer |
No |
Current number of associated active message consumers For topic destinations, this attribute includes both nondurable and (active and inactive) durable subscribers and is equivalent to NumConsumers. |
|
Integer |
No |
Peak number of associated active message consumers since broker started For topic destinations, this attribute includes both nondurable and (active and inactive) durable subscribers and is equivalent to PeakNumConsumers. |
|
Integer |
No |
Average number of associated active message consumers since broker started For topic destinations, this attribute includes both nondurable and (active and inactive) durable subscribers and is equivalent to AvgNumConsumers. |
|
Integer |
No |
Current number of associated backup message consumers |
|
Integer |
No |
Peak number of associated backup message consumers since broker started |
|
Integer |
No |
Average number of associated backup message consumers since broker started |
|
Long |
No |
Current number of messages stored in memory and persistent store Does not include messages held in transactions. |
|
Long |
No |
Current number of messages stored in memory and persistent store that were produced to a remote broker in a cluster. This number does not include messages included in transactions. |
|
Long |
No |
Current number of messages being held in memory and persistent store pending acknowledgment |
|
Long |
No |
Current number of messages being held in memory and persistent store in uncommitted transactions |
|
String |
No |
JMS Message ID of the next message to be delivered to any consumer |
|
Long |
No |
Peak number of messages stored in memory and persistent store since broker started |
|
Long |
No |
Average number of messages stored in memory and persistent store since broker started |
|
Long |
No |
Cumulative number of messages received since broker started |
|
Long |
No |
Cumulative number of messages sent since broker started |
|
Long |
No |
Cumulative size in bytes of messages received since broker started |
|
Long |
No |
Cumulative size in bytes of messages sent since broker started |
|
Long |
No |
Size in bytes of largest single message received since broker started |
|
Long |
No |
Current total size in bytes of messages stored in memory and persistent store Does not include messages held in transactions. |
|
Long |
No |
Current total size in bytes of messages stored in memory and persistent store that were produced to a remote broker in a cluster. This value does not include messages included in transactions. |
|
Long |
No |
Current total size in bytes of messages being held in memory and persistent store in uncommitted transactions |
|
Long |
No |
Peak total size in bytes of messages stored in memory and persistent store since broker started |
|
Long |
No |
Average total size in bytes of messages stored in memory and persistent store since broker started |
|
Long |
No |
Amount of disk space, in bytes, reserved for destination |
|
Long |
No |
Amount of disk space, in bytes, currently in use by destination |
|
Integer |
No |
Ratio of disk space currently in use to disk space reserved for destination |
Table 3–39 shows the possible values for the Type attribute. These values are defined as static constants in the utility class DestinationType.
Table 3–39 Destination Monitor Type Values
Value |
Utility Constant |
Meaning |
---|---|---|
Queue (point-to-point) destination |
||
Topic (publish/subscribe) destination |
Table 3–40 shows the possible values for the State and StateLabel attributes. These values are defined as static constants in the utility class DestinationState.
Table 3–40 Destination State Values
Value |
Utility Constant |
String Representation |
Meaning |
---|---|---|---|
0 |
RUNNING |
Destination running |
|
1 |
CONSUMERS_PAUSED |
Message consumers paused |
|
2 |
PRODUCERS_PAUSED |
Message producers paused |
|
3 |
PAUSED |
Destination paused |
|
-1 |
UNKNOWN |
Destination state unknown |
The destination monitor MBean supports the operations shown in Table 3–41. The names of these operations are defined as static constants in the utility class DestinationOperations.
Table 3–41 Destination Monitor Operations
The destination monitor MBean supports the notifications shown in Table 3–42. These notifications are instances of the Message Queue JMX class DestinationNotification, and their names are defined as static constants in that class.
Table 3–42 Destination Monitor Notifications
Name |
Utility Constant |
Description |
---|---|---|
Destination paused |
||
Destination resumed |
||
Destination compacted |
||
Destination purged |
Table 3–43 shows the methods defined in class DestinationNotification for obtaining details about a destination monitor notification.
Table 3–43 Data Retrieval Methods for Destination Monitor Notifications
Method |
Result Type |
Description |
---|---|---|
String |
Destination name |
|
String |
Destination type See Table 3–39 for possible values. |
|
Boolean |
Administrator-created destination? |
|
String |
Pause type See Table 3–36 for possible values. |