Java EE 5 SDK

com.sun.appserv.management.monitor
Interface MonitoringStats

All Superinterfaces:
AMX, AMXMBeanLogging, Monitoring, NotificationBroadcaster, NotificationEmitter
All Known Subinterfaces:
BeanCacheMonitor, BeanMethodMonitor, BeanMonitor, BeanPoolMonitor, ConnectionManagerMonitor, ConnectionQueueMonitor, ConnectorConnectionPoolMonitor, EntityBeanMonitor, FileCacheMonitor, HTTPListenerMonitor, HTTPServiceVirtualServerMonitor, JDBCConnectionPoolMonitor, JVMMonitor, KeepAliveMonitor, LoadBalancerContextRootMonitor, LoadBalancerServerMonitor, MessageDrivenBeanMonitor, ServletMonitor, StatefulSessionBeanMonitor, StatelessSessionBeanMonitor, ThreadPoolMonitor, TransactionServiceMonitor, WebModuleVirtualServerMonitor, WebServiceEndpointMonitor

public interface MonitoringStats
extends Monitoring

Monitoring MBeans which expose one or more Statistic implement this interface.

Each MonitoringStats MBean exposes Statistics as Attributes formed using the following pattern:

    statistic-name_field-name 
For example, a CountStatistic names "Hosts" would generate the following Attributes: For most purposes, it is the "name_Count" value which should be of primary interest.

The type of the Statistic will govern how many Attributes are generated, based on its actual fields, but every Statistic interface will have at least the Name, Description, Unit, StartTime and LastSampleTime fields present.

Note: These derived Attributes are not made available directly in the interface for the MBean; please refer to the documentation for each MonitoringStats MBean to determine which Statistics are available, and thus which derived Attributes available.

See Also:
AMX, StdAttributesAccess, Util.getExtra(com.sun.appserv.management.base.AMX), Extra, Statistic

Field Summary
 
Fields inherited from interface com.sun.appserv.management.base.AMX
FULL_TYPE_DELIM, GROUP_CONFIGURATION, GROUP_JSR77, GROUP_MONITORING, GROUP_OTHER, GROUP_UTILITY, J2EE_TYPE_KEY, JMX_DOMAIN, NAME_KEY, NO_NAME, NOTIFICATION_PREFIX, NULL_NAME
 
Method Summary
 CompositeDataSupport getOpenStatistic(String name)
          Get a JSR 77 Statistic encoded as a standard serializable JMX OpenType.
 CompositeDataSupport[] getOpenStatistics(String[] names)
          Get JSR 77 Statistics encoded as a standard serializable JMX OpenTypes.
 CompositeDataSupport getOpenStats()
          Get a JSR 77 Stats object encoded as a standard serializable JMX OpenType.
 Statistic getStatistic(String name)
          Get a specific JSR 77 Statistic.
 String[] getStatisticNames()
          Get the names of all available Statistics.
 Statistic[] getStatistics(String[] names)
          Get specific JSR 77 Statistics.
 Stats getStats()
          Get a JSR 77 Stats object for all available statistics.
 String getStatsInterfaceName()
           
 boolean refresh()
          Refresh any stale data.
 
Methods inherited from interface com.sun.appserv.management.monitor.Monitoring
getServerRootMonitor
 
Methods inherited from interface com.sun.appserv.management.base.AMX
getContainer, getDomainRoot, getFullType, getGroup, getJ2EEType, getName, isDAS
 
Methods inherited from interface javax.management.NotificationEmitter
removeNotificationListener
 
Methods inherited from interface javax.management.NotificationBroadcaster
addNotificationListener, getNotificationInfo, removeNotificationListener
 
Methods inherited from interface com.sun.appserv.management.base.AMXMBeanLogging
getMBeanLoggerName, getMBeanLogLevel, setMBeanLogLevel
 

Method Detail

getStats

Stats getStats()
Get a JSR 77 Stats object for all available statistics. Semantically, the returned Stats object MUST be a "snapshot" to the current state of the world.


getStatsInterfaceName

String getStatsInterfaceName()

getStatistic

Statistic getStatistic(String name)
Get a specific JSR 77 Statistic.

Parameters:
name - the Statistic name

getStatistics

Statistic[] getStatistics(String[] names)
Get specific JSR 77 Statistics. If a Statistic is not found, then null is returned in its array slot.

Parameters:
names - the Statistic names
Returns:
corresponding values for the names

getStatisticNames

String[] getStatisticNames()
Get the names of all available Statistics.


getOpenStats

CompositeDataSupport getOpenStats()
Get a JSR 77 Stats object encoded as a standard serializable JMX OpenType.


getOpenStatistic

CompositeDataSupport getOpenStatistic(String name)
Get a JSR 77 Statistic encoded as a standard serializable JMX OpenType.

Parameters:
name - the Statistic name

getOpenStatistics

CompositeDataSupport[] getOpenStatistics(String[] names)
Get JSR 77 Statistics encoded as a standard serializable JMX OpenTypes. If a Statistic is not found, then null is returned in its array slot.

Parameters:
names - the Statistic names
Returns:
corresponding values for the names

refresh

boolean refresh()
Refresh any stale data. This may or may not be applicable, depending on how the implementation performs its data collection. If the data is always "live", then the implementation of this routine does nothing.

Returns:
true if there may be new data present, false otherwise

Java EE 5 SDK

Submit a bug or feature

Copyright 2006 Sun Microsystems, Inc. All rights reserved.