The combination of WebSphere 4.0 FixPak 2 and WebSphere 3.5.5 allows the Performance Monitoring Infrastructure (PMI) to be used with a WebSphere Version 3.5.5 or later application server. To enable this feature, you must make two configuration changes and one programmatic change.
For PMI to interact correctly with WebSphere 3.5.x application servers, you must upgrade both the WebSphere 3.5.x runtime environment and the PMI JAR files to the levels specified below. In addition, you must prepend the repository.jar file from the upgraded WebSphere 3.5.x runtime environment to the PMI client's runtime classpath.
Ensure the WebSphere 3.5 environment is at WebSphere Version 3.5.5 or later.
A new constructor for PmiClient allows a client to monitor WebSphere Version 3.5.5 or later application servers. The new constructor takes three String parameters: hostName, serverName, and Version.
public PmiClient(String host, String port, String version)
Using this constructor with "EPM" as the third parameter creates a PmiClient that may retrieve data from WebSphere 3.5.5+ application servers.
PmiClient pmiClnt = new PmiClient(hostName, portNumber, "EPM");
No other programmatic changes, API or otherwise, are needed to use PMI with WebSphere 3.5.5+ application servers.
For a more complete description of the PmiClient class and using the Performance Monitoring Infrastructure, see the InfoCenter article "9.2: Performance Monitoring infrastructure client package."
Below are tables comparing the PMI counters available in Version 4.0.x to those available in Version 3.5.5 or later. For more information, see the InfoCenter article "6.6.21: Performance data reported with Resource Analyzer." The PMI counters are available for WebSphere for the following resource categories:
The following performance data is available for enterprise beans.
Name | Available in 4.0.x | Available in 3.5.5+ |
---|---|---|
Num Creates | YES | YES |
Num Removes | YES | YES |
Num Activates | YES | YES |
Num Passivates | YES | YES |
Num Instantiates | YES | YES |
Num Destroys | YES | YES |
Num Loads | YES | YES |
Num Stores | YES | YES |
Concurrent Actives | YES | YES |
Concurrent Lives | YES | YES |
Total Method Calls | YES | YES |
Avg Method Rt (ms) | YES | YES |
Avg CreateTime (ms) | YES | NO |
Avg Remove Time (ms) | YES | NO |
Active Methods | YES | YES |
Gets from Pool | YES | YES |
Gets Found | YES | YES |
Returns to Pool | YES | YES |
Returns Discarded | YES | YES |
Drains from Pool | YES | YES |
Avg Drain Size | YES | YES |
Pool Size | YES | YES |
Each data source (database instance) has a connection pool.
Name | Available in 4.0.x | Available in 3.5.5+ |
---|---|---|
Num Creates | YES | YES |
Num Destroys | YES | YES |
Num Returns | YES | NO |
Num Allocates | YES | YES |
Pool Size | YES | YES |
Concurrent Waiters | YES | YES |
Avg Wait Time (ms) | YES | YES |
Faults | YES | YES |
Percents Used | YES | YES |
Percents Maxed | YES | YES |
PrepStmt Cache Discards | YES | NO |
The following performance data is available for J2C Connectors.
Name | Available in 4.0.x | Available in 3.5.5+ |
---|---|---|
Num Managed Connections | YES | NO |
Num Connections | YES | NO |
The following performance data is available for the Java Virtual Machine (JVM) run time.
Name | Available in 4.0.x | Available in 3.5.5+ |
---|---|---|
Total Memory (bytes) | YES | YES |
Free Memory (bytes) | YES | YES |
Used Memory (bytes) | YES | YES |
Resource Analyzer leverages a Java Virtual Machine Profiler Interface (JVMPI) to enablea more comprehensive performance analysis. This profiling tool enables the collection of information about the Java Virtual Machine (JVM) that runs the application server. For information on this tool, see the InfoCenter article "Enabling JVMPI data reporting."
Name | Available in 4.0.x | Available in 3.5.5+ |
---|---|---|
Num Calls | YES | NO |
Avg Time Between Calls | YES | NO |
Avg Duration | YES | NO |
Num Waiters | YES | NO |
Avg Wait Time | YES | NO |
Num Objects Alloc | YES | NO |
Num Objects Freed | YES | NO |
Num Objects Moved | YES | NO |
Num Threads Started | YES | NO |
Num Threads Dead | YES | NO |
Performance data for HTTP sessions is shown in the table below.
Performance data for a servlet is collected only if the servlet is loaded when the application server starts. To ensure that data is collected for a servlet, see the InfoCenter article "Starting data retrieval."
Name | Available in 4.0.x | Available in 3.5.5+ |
---|---|---|
Created Sessions | YES | YES |
Invalidated Sessions | YES | YES |
Finalized Sessions | YES | YES |
Session Lifetime | YES | YES |
Session Invalidate Time | YES | YES |
Active Sessions | YES | YES |
Live Sessions | YES | YES |
The following performance data is available for the ORB thread pool.
Name | Available in 4.0.x | Available in 3.5.5+ |
---|---|---|
Thread Creates | YES | YES |
Thread Destroys | YES | YES |
Active Threads | YES | YES |
Pool Size | YES | YES |
Percent Maxed | YES | YES |
The following performance data is available for the Web container thread pool.
Name | Available in 4.0.x | Available in 3.5.5+ |
---|---|---|
Thread Creates | YES | NO |
Thread Destroys | YES | NO |
Active Threads | YES | NO |
Pool Size | YES | NO |
Percent Maxed | YES | NO |
The following performance data is available for container transactions.
Name | Available in 4.0.x | Available in 3.5.5+ |
---|---|---|
Global Trans Begun | YES | NO |
Global Trans Involved | YES | NO |
Local Trans Begun | YES | NO |
Active Global Trans | YES | YES |
Active Local Trans | YES | NO |
Global Trans Duration | YES | YES |
Local Trans Duration | YES | NO |
Global Before Completion Duration | YES | NO |
Global Prepare Duration | YES | NO |
Global Commit Duration | YES | NO |
Local Before Completion Duration | YES | NO |
Local Commit Duration | YES | NO |
Num Optimizations | YES | NO |
Global Trans Committed | YES | YES |
Local Trans Committed | YES | NO |
Global Trans RolledBack | YES | YES |
Local Trans RolledBack | YES | NO |
Global Trans Timeout | YES | NO |
Local Trans Timeout | YES | NO |
The following performance data is available for Web applications.
Name | Available in 4.0.x | Available in 3.5.5+ |
---|---|---|
Num Loaded Servlets | YES | YES |
Num Reloads | YES | YES |
Total Requests | YES | YES |
Concurrent Requests | YES | YES |
Response Time (ms) | YES | YES |
Num Errors | YES | YES |
When using the Resource Analyzer, you might encounter the problems with counters described in this section.
If you have database connection pool counters on WebSphere Application Server Version 3.5.5 and you set the performance monitoring level for the database connection pool module, later changing it to a lower level disables some of the counters. After you disable the counters, you will not be able to re-enable the counters without restarting the application server.
To work around the problem, do not lower the level for connection pool counters. If you do, you will have to restart the application server in order to enable them again.
You might encounter negative numbers in the Resource Analyzer in the following situations:
The Resource Analyzer allows you to reset counters so that you can get counter values from the reset point. If you reset counters on the Resource Analyzer and then restart the application server, you might see negative numbers for some counters. This is the expected behavior because the counters in the application server are reset to zero (0) but their old values in the Resource Analayzer are still stored to calculate the difference. To see the correct values, invoke a reset from the Resource Analyzer again.
The Resource Analyzer provides three options for displaying counters: current, change, and rate. If you choose the change or rate options, you might see negative numbers. This is the expected behavior. It means that a counter has changed to a lower value.
When you run the Resource Analyzer or use the PMI client to monitor performance data in a Version 3.5.x application server or when you use the Advanced Edition Version 4.0.1, you might see negative numbers for some counters that track concurrent values. For example, concurrent waiters for a connection pool, concurrent servlet requests, and other load data counters might show negative values. High concurrency and lack of synchronization for performance data updates cause the negative values.
To minimize the overhead of performance monitoring, the Resource Analyzer does not provide synchronization when updating EPM/PMI counters. Thus, when multiple threads try to update a counter at the same time, some updates might be lost due to concurrency. For example, if two servlet requests come concurrently, they will both try to increment concurrentRequests by 1 at the same time. As a result, you might see the counter incremented by 1 instead of 2. When the two requests are completed, each will decrement the same counter by 1, which might result in -1 value. Note that the server keeps an accumulated value for each concurrent counter, so a counter value might accumulate to a large negative number in some cases. To offset any negative number, invoke a reset on the Resource Analyzer.
The percentUsed counter for a database connection pool might be over 100% or be a negative number in some cases, especially when an application has high concurrency.
Because the EpmService session bean in Version 3.5.5 is a stateful session bean, you cannot call the same PmiClient object in multiple threads at the same time. Doing so gives you a BeanNotRetrantException. There is no such restriction when calling PmiClient against a Version 4.0.x server.