com.ibm.websphere.pmi.client
Class PmiClient
- java.lang.Object
com.ibm.websphere.pmi.client.PmiClient
Deprecated. As of 6.0, PMI Client API is replaced with JMX interface and MBean StatisticsProvider model. PMI CpdCollection data structure is replaced by J2EE Performance Data Framework defined in
javax.management.j2ee.statistics
package.
The PmiClient class is called by client application to access performance data. The purpose is to free the programmer from implementing the remote data access manually.
The class has two set of APIs. One set of APIs are 4.0 APIs, that use PerfDescriptor to get PMI data and the returned PMI data are CpdData/CpdCollection objects. In both 3.5.5+ and 4.0, the PmiClient API looks up a session bean in adminserver and invokes remote APIs on the session bean.
Another set of APIs are JMX-based API new in 5.0. The new APIs use ObjectName/MBeanStatDescriptor to get PMI data via JMX interface.
A brief calling flow is shown here. Details can be found in InfoCenter and sample code. First, a client application needs create an instance of the PmiClient object by passing the correct host name, port number, version name, and JMX connector types. If the PmiClient instance is successfully created, you are ready to call the methods on it to retrieve the data. You need to set the instrumentation level to enable the data for the first time because PMI data is disabled by default. You can call various list methods to navigate the WebSphere domain for nodes, servers, MBeans (or PerfDescriptor for 4.0 API). If you know the names for the node, server, PMI module, or data, you can call pmiClient to create the MBeanStatDescriptor (or PerfDescriptor for 4.0 API) object. Once you get the ObjectName, MBeansStatDescriptor, or PerfDescriptor, you can call the corresponding getXXX methods to get the PMI data.
Note that the setInstrumentationLevel method changes the level at the server side which means it effects other clients monitoring the same server.
Both 4.0 APIs and 5.0 APIs will be supported in 5.0. However, since the returned data are in different types when using 4.0 and 5.0 APIs, it is recommanded that you do not mix the two APIs together.
- public class PmiClient
- extends java.lang.Object
- implements PmiConstants
Field Summary
Modifier and Type | Field and Description |
---|---|
|
COPYRIGHT
Deprecated.
|
|
DEFAULT_CONNECTOR_PORT
Deprecated.
|
|
DEFAULT_CONNECTOR_TYPE
Deprecated.
|
|
FAILED_TO_CREATE_PMISERVICE_BEAN_OBJECT
Deprecated.
|
|
FAILED_TO_DISABLE_DATA
Deprecated.
|
|
FAILED_TO_ENABLE_DATA
Deprecated.
|
|
FAILED_TO_GET_ADMIN_STATE
Deprecated.
|
|
FAILED_TO_GET_DATA
Deprecated.
|
|
FAILED_TO_GET_INITIAL_CONTEXT
Deprecated.
|
|
FAILED_TO_GET_LEVEL
Deprecated.
|
|
FAILED_TO_LIST_MEMBERS
Deprecated.
|
|
FAILED_TO_LIST_NODES
Deprecated.
|
|
FAILED_TO_LIST_SERVERS
Deprecated.
|
|
FAILED_TO_SET_LEVEL
Deprecated.
|
|
moduleNLSMap
Deprecated.
|
|
NO_COLLECTOR_FOUND
Deprecated.
|
|
NO_ERROR
Deprecated.
|
|
NO_PERFMBEAN_FOUND
Deprecated.
|
|
NO_SUCH_A_NODE
Deprecated.
|
|
NO_SUCH_A_SERVER
Deprecated.
|
|
pmiNLS
Deprecated.
|
|
prefixNLSMap
Deprecated.
|
|
SEPERATOR40
Deprecated.
|
|
SEPERATOR50
Deprecated.
|
|
SERVER_STOPPED
Deprecated.
|
|
VERSION_AE
Deprecated.
|
|
VERSION_AES
Deprecated.
|
|
VERSION_EPM
Deprecated.
|
|
VERSION_WAS50
Deprecated.
|
|
VERSION_WAS50ND
Deprecated.
|
Constructor Summary
Constructor and Description |
---|
PmiClient()
Deprecated. Constructor: assume all defaults: local host, port DEFAULT_CONNECTOR_PORT, and WAS50 version.
|
PmiClient(boolean inAppServer)
Deprecated. Use this constructor only when you are calling it inside an appserver.
|
PmiClient(java.util.Properties props,java.lang.String version)
Deprecated. Constructor: take a Properties and the version.
|
PmiClient(java.lang.String host,java.lang.String port)
Deprecated. Constructor:
|
PmiClient(java.lang.String host,java.lang.String port,java.lang.String version)
Deprecated. Constructor: take host, port, and version.
|
PmiClient(java.lang.String host,java.lang.String port,java.lang.String version,boolean inAppServer,java.lang.String connectorType)
Deprecated. Constructor: take host, port, and version.
|
PmiClient(java.lang.String host,java.lang.String nodeName,java.lang.String port,java.lang.String version)
Deprecated. Constructor: take host, nodeName, port, and version.
|
Method Summary
Modifier and Type | Method and Description |
---|---|
|
add(PerfDescriptor pd)
Deprecated. 4.0 API.
|
createCpdCollection(PerfDescriptor colPd,com.ibm.ws.pmi.wire.WpdCollection wCol)
Deprecated. 4.0 API: create a CpdCollection object from WpdCollection
|
|
|
createCpdData(PmiModuleConfig moduleConfig,PerfDescriptor parent,com.ibm.ws.pmi.wire.WpdData wData)
Deprecated. 4.0 API: create a CpdData object from WpdData
|
|
createMBeanLevelSpec(javax.management.ObjectName oname,int level)
Deprecated. 5.0 API: Create an MBeanLevelSpec object.
|
|
createMBeanLevelSpec(javax.management.ObjectName oname,StatDescriptor sd,int level)
Deprecated. 5.0 API: Create an MBeanLevelSpec object.
|
|
createPerfDescriptor()
Deprecated. 4.0 API.
|
|
createPerfDescriptor(PerfDescriptor parent,int dataId)
Deprecated. 4.0 API.
|
|
createPerfDescriptor(PerfDescriptor parent,int[] dataIds)
Deprecated. 4.0 API.
|
|
createPerfDescriptor(PerfDescriptor parent,java.lang.String name)
Deprecated. 4.0 API.
|
|
createPerfDescriptor(java.lang.String qualifiedDataPath)
Deprecated. 4.0 API.
|
|
createPerfDescriptor(java.lang.String[] dataPath)
Deprecated. 4.0 API.
|
|
createPerfDescriptor(java.lang.String[] dataPath,int dataId)
Deprecated. 4.0 API.
|
|
createPerfDescriptor(java.lang.String[] dataPath,int[] dataIds)
Deprecated. 4.0 API.
|
|
createPerfDescriptor(java.lang.String qualifiedDataPath,int dataId)
Deprecated. 4.0 API.
|
|
createPerfDescriptor(java.lang.String qualifiedDataPath,int[] dataIds)
Deprecated. 4.0 API.
|
createPerfLevelSpec(int level)
Deprecated. 4.0 API.
|
|
createPerfLevelSpec(java.lang.String[] path,int level)
Deprecated. 4.0 API.
|
|
|
createRootCollection()
Deprecated. 4.0 API: Create the root collection for the domain
|
|
end()
Deprecated. Call this method before and ONLY before you are done with PmiClient
|
|
findConfig(PmiModuleConfig[] configs,javax.management.ObjectName on)
Deprecated. Return the config for the MBean ObjectName
|
|
findConfig(PmiModuleConfig[] configs,java.lang.String moduleID)
Deprecated. Return the config for the moduleID
|
get(PerfDescriptor pd,boolean recursive)
Deprecated. 4.0 API: Get PMI data.
|
|
|
getAdminState(java.lang.String nodeName)
Deprecated. Get the administratio state of the node, i.e., start or stop.
|
|
getAdminState(java.lang.String nodeName,java.lang.String serverName)
Deprecated. Get the administratio state of the server, i.e., start or stop.
|
getConfig(java.lang.String moduleName)
Deprecated. Return PmiModuleConfig for the module.
|
|
getConfig(java.lang.String nodeName,java.lang.String serverName,javax.management.ObjectName oName)
Deprecated. 5.0 API: Get PmiModuleConfig for a particular MBean.
|
|
getConfig(java.lang.String nodeName,java.lang.String serverName,java.lang.String moduleName)
Deprecated. Get PmiModuleConfig for a particular PMI module.
|
|
getConfigs()
Deprecated. Get an array of PmiModuleConfig for all the PMI modules.
|
|
getConfigs(java.lang.String nodeName,java.lang.String serverName)
Deprecated. 5.0 API: Get all PmiModuleConfigs for the server.
|
|
|
getConnectedHost()
Deprecated. Return the connected host name: it should be the name of host name passed to PmiClient
or the actual localhost name if "localhost" is passed to PmiClient.
|
|
getDataId(java.lang.String moduleName,java.lang.String dataName)
Deprecated. Convert data name to dataId
|
|
getDataName(java.lang.String moduleName,int dataId)
Deprecated. Convert data id to data name
|
|
getErrorCode()
Deprecated. Check the error code, which could be one of the error constants defined in this class.
|
|
getErrorCode(java.lang.String nodeName)
Deprecated. Check the error code, which could be one of the error constants defined in this class.
|
|
getErrorMessage()
Deprecated. Check the error message.
|
|
getErrorMessage(java.lang.String nodeName)
Deprecated. Check the error message.
|
getInstrumentationLevel(java.lang.String nodeName,java.lang.String serverName)
Deprecated. 4.0 API.
|
|
|
getNLSValue(java.lang.String key)
Deprecated. Replaced by getNLSValue (key, moduleID)
|
|
getNLSValue(java.lang.String key,java.lang.String moduleID)
Deprecated. Get translated key from the resource bundle.
|
gets(boolean recursive)
Deprecated. Get all the data you requested by calling add method.
|
|
gets(PerfDescriptor[] pds,boolean recursive)
Deprecated. 4.0 API.
|
|
gets(PerfDescriptorList pdList,boolean recursive)
Deprecated. 4.0 API.
|
|
getStatLevel(java.lang.String nodeName,java.lang.String serverName,MBeanStatDescriptor msd,boolean recursive)
Deprecated. 5.0 API: Get MBeanLevelSpec[] based on a MBeanStatDescriptor.
|
|
getStatLevel(java.lang.String nodeName,java.lang.String serverName,javax.management.ObjectName oName,boolean recursive)
Deprecated. 5.0 API: Get MBeanLevelSpec[] based on an ObjectName.
|
|
|
getStats(java.lang.String nodeName,java.lang.String serverName,MBeanStatDescriptor[] msds,boolean recursive)
Deprecated. 5.0 API: Return an array of Stats objects.
|
getStats(java.lang.String nodeName,java.lang.String serverName,MBeanStatDescriptor msd,boolean recursive)
Deprecated. 5.0 API: Return a Stats object.
|
|
|
getStats(java.lang.String nodeName,java.lang.String serverName,javax.management.ObjectName[] oNames,boolean recursive)
Deprecated. 5.0 API: Return an array of Stats objects.
|
getStats(java.lang.String nodeName,java.lang.String serverName,javax.management.ObjectName oName,boolean recursive)
Deprecated. 5.0 API: Return a Stats object.
|
|
|
listMBeans(java.lang.String nodeName,java.lang.String serverName)
Deprecated. 5.0 API: List all the MBeans in the server.
|
listMembers(PerfDescriptor pd)
Deprecated. 4.0 API: List all the PMI members (modules, submodules, or data) under the PerfDescriptor.
|
|
listNodes()
Deprecated. List all the nodes in WebSphere domain.
|
|
listServers(PerfDescriptor pd)
Deprecated. List all the serves in the node.
|
|
listServers(java.lang.String nodeName)
Deprecated. List all the servers in the node.
|
|
listStatMembers(java.lang.String nodeName,java.lang.String serverName,MBeanStatDescriptor msd)
Deprecated. 5.0 API: List the MBeanStatDescriptors (if any) under it.
|
|
listStatMembers(java.lang.String nodeName,java.lang.String serverName,javax.management.ObjectName oName)
Deprecated. 5.0 API: List the MBeanStatDescriptors (if any) under it.
|
|
|
refreshModuleConfig(java.lang.String node,java.lang.String server)
Deprecated. Get the module configuration for all the modules from the given node and server
|
|
setDebug(boolean enableDebug)
Deprecated. Pass true to it to enable debug, which is disabled by default.
|
|
setInstrumentationLevel(java.lang.String nodeName,java.lang.String serverName,PerfLevelSpec[] specs,boolean recursive)
Deprecated. 4.0 API.
|
|
setPerfConfigInfo(java.lang.String nodeName,java.lang.String serverName,javax.management.ObjectName oName,StatDescriptor sd,Stats stats)
Deprecated.
|
|
setPerfConfigInfo(java.lang.String nodeName,java.lang.String serverName,javax.management.ObjectName oName,Stats stats)
Deprecated. 5.0 API: Set performance config info for each stats.
|
|
setStatLevel(java.lang.String nodeName,java.lang.String serverName,MBeanLevelSpec[] msds,boolean recursive)
Deprecated. 5.0 API: Set level.
|
|
setStatLevel(java.lang.String nodeName,java.lang.String serverName,MBeanLevelSpec mls,boolean recursive)
Deprecated. 5.0 API: Set level.
|
|
stringToArray(java.lang.String qualifiedName)
Deprecated. 4.0 API.
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail
COPYRIGHT
- public static final java.lang.String COPYRIGHT
VERSION_AE
- public static final java.lang.String VERSION_AE
VERSION_AES
- public static final java.lang.String VERSION_AES
VERSION_EPM
- public static final java.lang.String VERSION_EPM
VERSION_WAS50
- public static final java.lang.String VERSION_WAS50
VERSION_WAS50ND
- public static final java.lang.String VERSION_WAS50ND
NO_ERROR
- public static final int NO_ERROR
FAILED_TO_GET_INITIAL_CONTEXT
- public static final int FAILED_TO_GET_INITIAL_CONTEXT
FAILED_TO_CREATE_PMISERVICE_BEAN_OBJECT
- public static final int FAILED_TO_CREATE_PMISERVICE_BEAN_OBJECT
FAILED_TO_LIST_NODES
- public static final int FAILED_TO_LIST_NODES
FAILED_TO_LIST_SERVERS
- public static final int FAILED_TO_LIST_SERVERS
FAILED_TO_LIST_MEMBERS
- public static final int FAILED_TO_LIST_MEMBERS
FAILED_TO_ENABLE_DATA
- public static final int FAILED_TO_ENABLE_DATA
FAILED_TO_DISABLE_DATA
- public static final int FAILED_TO_DISABLE_DATA
FAILED_TO_SET_LEVEL
- public static final int FAILED_TO_SET_LEVEL
FAILED_TO_GET_LEVEL
- public static final int FAILED_TO_GET_LEVEL
FAILED_TO_GET_DATA
- public static final int FAILED_TO_GET_DATA
FAILED_TO_GET_ADMIN_STATE
- public static final int FAILED_TO_GET_ADMIN_STATE
SERVER_STOPPED
- public static final int SERVER_STOPPED
NO_COLLECTOR_FOUND
- public static final int NO_COLLECTOR_FOUND
NO_SUCH_A_NODE
- public static final int NO_SUCH_A_NODE
NO_SUCH_A_SERVER
- public static final int NO_SUCH_A_SERVER
NO_PERFMBEAN_FOUND
- public static final int NO_PERFMBEAN_FOUND
SEPERATOR50
- public static final java.lang.String SEPERATOR50
SEPERATOR40
- public static final java.lang.String SEPERATOR40
DEFAULT_CONNECTOR_TYPE
- public static final java.lang.String DEFAULT_CONNECTOR_TYPE
DEFAULT_CONNECTOR_PORT
- public static final java.lang.String DEFAULT_CONNECTOR_PORT
pmiNLS
- public static final com.ibm.ejs.sm.client.ui.NLS pmiNLS
moduleNLSMap
- public static java.util.HashMap moduleNLSMap
prefixNLSMap
- public static java.util.HashMap prefixNLSMap
Constructor Detail
PmiClient
- public PmiClient()
- throws java.rmi.RemoteException
java.rmi.RemoteException
PmiClient
- public PmiClient(boolean inAppServer)
- throws java.rmi.RemoteException
inAppServer
- may be true if you are calling it inside an appserver java.rmi.RemoteException
PmiClient
- public PmiClient(java.lang.String host,
- java.lang.String port)
- throws java.rmi.RemoteException
host
- is the host name where adminserver/netManager is running port
- is the port number for adminserver/netManager
Use default version, i.e., WAS50. java.rmi.RemoteException
PmiClient
- public PmiClient(java.lang.String host,
- java.lang.String port,
- java.lang.String version)
- throws java.rmi.RemoteException
host
- is the host name where adminserver/netManager is running port
- is the port number for adminserver/netManager version
- could be "WAS50" for 5.0, "AE" for 4.0x AE, "AES" for 4.0x AEs,
and "EPM" for 3.5 java.rmi.RemoteException
PmiClient
- public PmiClient(java.lang.String host,
- java.lang.String nodeName,
- java.lang.String port,
- java.lang.String version)
- throws java.rmi.RemoteException
host
- is the host name where adminserver/netManager is running port
- is the port number for adminserver/netManager version
- could be "WAS50" for 5.0, "AE" for 4.0x AE, "AES" for 4.0x AEs,
and "EPM" for 3.5 java.rmi.RemoteException
PmiClient
- public PmiClient(java.lang.String host,
- java.lang.String port,
- java.lang.String version,
- boolean inAppServer,
- java.lang.String connectorType)
- throws java.rmi.RemoteException
host
- is the host name where adminserver/netManager is running. If not passed, the default
is localhost. port
- is the port number for adminserver/netManager. If not passed, the default is DEFAULT_CONNECTOR_PORT. version
- could be "WAS50" for 5.0, "AE" for 4.0x and "EPM" for 3.5. If not passed, the default
is WAS50. inAppServer
- should be false unless you are calling from an appserver. If not passed, the default
is false. connectorType
- is either RMI or SOAP. If not passed, the default is DEFAULT_CONNECTOR_TYPE. java.rmi.RemoteException
PmiClient
- public PmiClient(java.util.Properties props,
- java.lang.String version)
- throws java.rmi.RemoteException
If you do not use the default host (localhost), port (8880) and connector type (AdminClient.CONNECTOR_TYPE_SOAP), you have to set the following properties props.setProperty(AdminClient.CONNECTOR_HOST, hostName); props.setProperty(AdminClient.CONNECTOR_PORT, portNumber); props.setProperty(AdminClient.CONNECTOR_TYPE, connectorType);
Enable security for WAS 5.0. The following instruction is copied from AdminClient.
For SOAP based AdminClient, the users need to specifiy the "username" and "password" and explicitly set "securityEnabled" as "true". Some other properties are also required in order to make a SSL connection, these properties can be either specified as a Java system properties or passed as paramemters when invoking AdminClientFactory.createAdminClient(Properties). These properties include
- javax.net.ssl.trustStore
- javax.net.ssl.keyStore
- javax.net.ssl.trustStorePassword
- javax.net.ssl.keyStorePassword
An exmample to make a secure SOAP based AdminClient:
Properties props = new Properties(); props.setProperty(AdminClient.CONNECTOR_HOST, "localhost"); props.setProperty(AdminClient.CONNECTOR_PORT, "8880"); props.setProperty(AdminClient.CONNECTOR_TYPE, AdminClient.CONNECTOR_TYPE_SOAP); props.setProperty(AdminClient.CONNECTOR_SECURITY_ENABLED, "true"); props.setProperty(AdminClient.USERNAME, "user1"); props.setProperty(AdminClient.PASSWORD, "password1"); props.setProperty("javax.net.ssl.trustStore", "C:/WebSphere/AppServer/etc/DummyClientTrustFile.jks"); props.setProperty("javax.net.ssl.keyStore", "C:/WebSphere/AppServer/etc/DummyClientKeyFile.jks"); props.setProperty("javax.net.ssl.trustStorePassword", "WebAS"); props.setProperty("javax.net.ssl.keyStorePassword", "WebAS"); AdminClient client = AdminClientFactory.createAdminClient(props);
To make a secure RMI based AdminClient is a little easier because you can rely on existing "com.ibm.CORBA.ConfigURL" which normal points to a property file, for instance, $WAS_ROOT/properties/sas.client.properites. There are a couple different ways to specify the login username and password and it's determined by "com.ibm.CORBA.loginSource" in "com.ibm.CORBA.ConfigURL". For programmatic login, you can set "com.ibm.CORBA.loginSource" as "none" and then provide your username/password when you create a AdminClient using AdminClientFactory.
For example,
Properties props = new Properties(); props.setProperty(AdminClient.CONNECTOR_HOST, "localhost"); props.setProperty(AdminClient.CONNECTOR_PORT, "2809"); props.setProperty(AdminClient.CONNECTOR_TYPE, AdminClient.CONNECTOR_TYPE_RMI); props.setProperty(AdminClient.CONNECTOR_SECURITY_ENABLED, "true"); props.setProperty(AdminClient.USERNAME, "test"); props.setProperty(AdminClient.PASSWORD, "user4test"); AdminClient client = AdminClientFactory.createAdminClient(props);
java.rmi.RemoteException
Method Detail
getConnectedHost
- public java.lang.String getConnectedHost( )
createCpdData
- public static CpdData createCpdData( PmiModuleConfig moduleConfig,
- PerfDescriptor parent,
- com.ibm.ws.pmi.wire.WpdData wData)
createCpdCollection
- public CpdCollection createCpdCollection( PerfDescriptor colPd,
- com.ibm.ws.pmi.wire.WpdCollection wCol)
createRootCollection
- public static CpdCollection createRootCollection( )
listNodes
- public PerfDescriptor[] listNodes( )
- throws PmiException
listServers
- public PerfDescriptor[] listServers( java.lang.String nodeName)
- throws PmiException
listServers
- public PerfDescriptor[] listServers( PerfDescriptor pd)
- throws PmiException
listMembers
- public PerfDescriptor[] listMembers( PerfDescriptor pd)
- throws PmiException
getConfigs
- public PmiModuleConfig[] getConfigs( )
refreshModuleConfig
- public void refreshModuleConfig( java.lang.String node,
- java.lang.String server)
getConfig
- public PmiModuleConfig getConfig( java.lang.String moduleName)
get
- public CpdCollection get(PerfDescriptor pd,
- boolean recursive)
- throws PmiException
recursive
- If recursive is true, it will return all the subcollections with data.
If recursive is false, it will return the data immediately under the PerfDescriptor
and no subcollection will be returned. gets
- public CpdCollection[] gets(boolean recursive)
- throws PmiException
gets
- public CpdCollection[] gets(PerfDescriptor[] pds,
- boolean recursive)
- throws PmiException
recursive
- If recursive is true, it will return all the subcollections with data.
If recursive is false, it will return the data immediately under the PerfDescriptor
and no subcollection will be returned. gets
- public CpdCollection[] gets(PerfDescriptorList pdList,
- boolean recursive)
- throws PmiException
recursive
- If recursive is true, it will return all the subcollections with data.
If recursive is false, it will return the data immediately under the PerfDescriptor
and no subcollection will be returned. getAdminState
- public int getAdminState(java.lang.String nodeName)
- throws PmiException
getAdminState
- public int getAdminState(java.lang.String nodeName,
- java.lang.String serverName)
- throws PmiException
getErrorCode
- public int getErrorCode()
getErrorMessage
- public java.lang.String getErrorMessage( )
getErrorCode
- public int getErrorCode(java.lang.String nodeName)
getErrorMessage
- public java.lang.String getErrorMessage( java.lang.String nodeName)
add
- public void add(PerfDescriptor pd)
stringToArray
- public static java.lang.String[] stringToArray( java.lang.String qualifiedName)
qualifiedName
- it should look like the following:
nodename,servername,modulename,instancename
The qualifierName can also be nodename/servername/modulename/instancename as supported in 4.0. However, "/" can not be in any name in the path if you use the 4.0 format. Otherwise, PMI will not be able to construct path correctly. You can use a substring of the above starting from node name
createPerfDescriptor
- public static PerfDescriptor createPerfDescriptor( )
createPerfDescriptor
- public static PerfDescriptor createPerfDescriptor( java.lang.String[] dataPath)
createPerfDescriptor
- public static PerfDescriptor createPerfDescriptor( java.lang.String qualifiedDataPath)
qualifiedDataPath
- it should look like the following:
nodename/servername/modulename/instancename.
e.g. node1/server1/connectionPoolModule/datasource1
node1/server1/beanModule/container1.bean1 createPerfDescriptor
- public static PerfDescriptor createPerfDescriptor( java.lang.String[] dataPath,
- int dataId)
createPerfDescriptor
- public static PerfDescriptor createPerfDescriptor( java.lang.String qualifiedDataPath,
- int dataId)
qualifiedDataPath
- it should look like the following:
nodename/servername/modulename/instancename.
e.g. node1/server1/connectionPoolModule/datasource1
node1/server1/beanModule/container1.bean1 createPerfDescriptor
- public static PerfDescriptor createPerfDescriptor( java.lang.String[] dataPath,
- int[] dataIds)
createPerfDescriptor
- public static PerfDescriptor createPerfDescriptor( java.lang.String qualifiedDataPath,
- int[] dataIds)
qualifiedDataPath
- it should look like the following:
nodename/servername/modulename/instancename.
e.g. node1/server1/connectionPoolModule/datasource1
node1/server1/beanModule/container1.bean1 createPerfDescriptor
- public static PerfDescriptor createPerfDescriptor( PerfDescriptor parent,
- java.lang.String name)
createPerfDescriptor
- public static PerfDescriptor createPerfDescriptor( PerfDescriptor parent,
- int dataId)
createPerfDescriptor
- public static PerfDescriptor createPerfDescriptor( PerfDescriptor parent,
- int[] dataIds)
createPerfLevelSpec
- public PerfLevelSpec createPerfLevelSpec( java.lang.String[] path,
- int level)
createPerfLevelSpec
- public PerfLevelSpec createPerfLevelSpec( int level)
getDataName
- public java.lang.String getDataName( java.lang.String moduleName,
- int dataId)
getDataId
- public int getDataId(java.lang.String moduleName,
- java.lang.String dataName)
getInstrumentationLevel
- public PerfLevelSpec[] getInstrumentationLevel( java.lang.String nodeName,
- java.lang.String serverName)
- throws PmiException
setInstrumentationLevel
- public void setInstrumentationLevel( java.lang.String nodeName,
- java.lang.String serverName,
- PerfLevelSpec[] specs,
- boolean recursive)
- throws PmiException
Note: setting levels from PmiClient will change the levels in the affected app server. It will impact other PMI clients that retrieve PMI data from the same app server.
setPerfConfigInfo
- public void setPerfConfigInfo(java.lang.String nodeName,
- java.lang.String serverName,
- javax.management.ObjectName oName,
- Stats stats)
setPerfConfigInfo
- public void setPerfConfigInfo(java.lang.String nodeName,
- java.lang.String serverName,
- javax.management.ObjectName oName,
- StatDescriptor sd,
- Stats stats)
getStats
- public Stats getStats(java.lang.String nodeName,
- java.lang.String serverName,
- javax.management.ObjectName oName,
- boolean recursive)
- throws PmiException
getStats
- public Stats getStats(java.lang.String nodeName,
- java.lang.String serverName,
- MBeanStatDescriptor msd,
- boolean recursive)
- throws PmiException
getStats
- public Stats[] getStats(java.lang.String nodeName,
- java.lang.String serverName,
- javax.management.ObjectName[] oNames,
- boolean recursive)
- throws PmiException
getStats
- public Stats[] getStats(java.lang.String nodeName,
- java.lang.String serverName,
- MBeanStatDescriptor[] msds,
- boolean recursive)
- throws PmiException
listMBeans
- public javax.management.ObjectName[] listMBeans( java.lang.String nodeName,
- java.lang.String serverName)
listStatMembers
- public MBeanStatDescriptor[] listStatMembers( java.lang.String nodeName,
- java.lang.String serverName,
- javax.management.ObjectName oName)
listStatMembers
- public MBeanStatDescriptor[] listStatMembers( java.lang.String nodeName,
- java.lang.String serverName,
- MBeanStatDescriptor msd)
getConfigs
- public PmiModuleConfig[] getConfigs( java.lang.String nodeName,
- java.lang.String serverName)
getConfig
- public PmiModuleConfig getConfig( java.lang.String nodeName,
- java.lang.String serverName,
- javax.management.ObjectName oName)
getConfig
- public PmiModuleConfig getConfig( java.lang.String nodeName,
- java.lang.String serverName,
- java.lang.String moduleName)
setStatLevel
- public void setStatLevel(java.lang.String nodeName,
- java.lang.String serverName,
- MBeanLevelSpec mls,
- boolean recursive)
setStatLevel
- public void setStatLevel(java.lang.String nodeName,
- java.lang.String serverName,
- MBeanLevelSpec[] msds,
- boolean recursive)
getStatLevel
- public MBeanLevelSpec[] getStatLevel( java.lang.String nodeName,
- java.lang.String serverName,
- javax.management.ObjectName oName,
- boolean recursive)
getStatLevel
- public MBeanLevelSpec[] getStatLevel( java.lang.String nodeName,
- java.lang.String serverName,
- MBeanStatDescriptor msd,
- boolean recursive)
createMBeanLevelSpec
- public static MBeanLevelSpec createMBeanLevelSpec( javax.management.ObjectName oname,
- int level)
createMBeanLevelSpec
- public static MBeanLevelSpec createMBeanLevelSpec( javax.management.ObjectName oname,
- StatDescriptor sd,
- int level)
end
- public void end()
getNLSValue
- public static java.lang.String getNLSValue( java.lang.String key)
getNLSValue
- public static java.lang.String getNLSValue( java.lang.String key,
- java.lang.String moduleID)
key
- key to be translated moduleID
- the module name from the PmiModuleConfig. Pass null to use default resource bundle setDebug
- public void setDebug(boolean enableDebug)
findConfig
- public static PmiModuleConfig findConfig( PmiModuleConfig[] configs,
- java.lang.String moduleID)
findConfig
- public static PmiModuleConfig findConfig( PmiModuleConfig[] configs,
- javax.management.ObjectName on)