Jump to content United States-English
HP.com Home Products and Services Support and Drivers Solutions How to Buy
» Contact HP
More options
HP.com home
HPjmeter Version 3.1 User's Guide > Chapter 7 Using the Console

Using Alerts

» 

Technical documentation

Complete book in PDF
» Feedback
Content starts here

 » Table of Contents

 » Glossary

 » Index

The console provides a way for you to enable and disable alerts for specific events when monitoring an application. Enabled alerts can be deactivated and reactivated during the session as needed by using the Alert Controller. In addition, you can set thresholds in the Alert Controller to vary the sensitivity of the console to enabled alert conditions, and you can edit e-mail notification attributes submitted when you set session preferences.

When active alerts are triggered, a notification appears in the main pane of the console window. To view details about the application behavior that triggered the notification, double-click on the specific alert that you want to see. A metric window associated with the alert will open. See “Responding to Alerts” for information on specific alert notifications.

The console displays an alert while the alert condition exists, and stops displaying when the alert condition no longer exists.

A displayed alert may also stop displaying when HPjmeter recalculates the alert based on real-time information.

The console displays a warning icon in the lower right corner of the window showing the current number of alerts detected.

Using the Alert Controller

To open the Alert Controller, double-click on an Alerts counter row in the data tree.

Figure 7-6 Appearance of Alert Notices in the Main Console Pane

Appearance of Alert Notices in the Main Console Pane

In the Controller, you can see all alerts enabled for that session. Some are turned on by default; others must be turned on in the Alert Controller.

NOTE: If you disabled specific alerts when you set your session preferences, information for those alerts will not be available in the Alert Controller or the main console pane. To enable those alerts, you must start a new session and enable the alert in the session preferences for that session.

Figure 7-7 Alert Controller Window

Alert Controller Window

You can use the Alert Controller in these ways:

Deactivate or reactivate enabled alerts.  To deactivate or reactivate alerts once a session has started, use the check box next to the alert name.

  • When you deactivate an alert, the console stops reporting that alert to the console main pane. Note that a record of the alert activity up to that point has been written into a log file for reference.

  • Remember that you can only deactivate or reactivate alerts that are enabled when you open the session.

Set alert thresholds.  You can use default settings or set values for enabled alerts. For each alert enabled, you can select a numerical threshold and a time constraint. The alert is triggered when the threshold is passed for the duration of the allotted time.

For example, if you are setting values for Heap Usage Notification, and you choose ≥ 50 MB and a time constraint of 60 seconds, the alert will trigger when the heap usage in the application exceeds the 50 MB threshold for at least 60 seconds. A notification appears in the console main panel for as long as the threshold is crossed, periodically updating to show the current value of the heap usage.

New values for alerts are applied immediately when you select Apply.

Viewing a Log of the Alert History

From the Alert Controller, select the Alert Log button to see a history of alerts noted during the monitoring session.

Figure 7-8 Example Alert Log

Example Alert Log

Change the alert log capacity.  From the Alert Log window, click the “Select Log Capacity” icon to open the log capacity window. Change the value as desired for number of lines to include in the log.

Editing E-mail Notification Attributes

From the Alert Controller, click Edit Notification to see the Alert Notification Editor and the settings you entered for this monitoring session.

Figure 7-9 Example Alert Notification Editor

Example Alert Notification Editor

The following table explains available options.

Table 7-6 E-mail Notification Fields and Options for Receiving Alerts

Fields/OptionsExpected Attribute ValuesDescription
SMTP E-mail Server:Correctly constructed host name of a valid SMTP server that allows connection without authentication.To locate the desired mail server
From:HP provides a default HPjmeter address; however, this field can be edited to enter an alternative addressTo provide an identifiable and memorable address that distinguishes HPjmeter alerts from other e-mail
To:Valid user or distribution list e-mail address; one or more addresses can be entered; use a comma-separated list for multiple addresses.To send e-mail alerts to intended receiver(s)
Activate e-mail notificationClick box to turn on or offOff by default. Check mark indicates e-mail notification is on.
Send all status changes corresponding to an enabled alertClick box to turn on or offOff by default; operative only when e-mail notification is activated.

When this setting is off, only the first occurrence of an alert event will be sent in e-mail. A check mark on this option indicates that notification will be sent every time an alert is activated during a session.

 

The following table explains the button controls in the Alert Notification Editor.

Table 7-7 Alert Notification Editor Controls

ControlsDescription
SaveSaves and applies changes to attributes and options for the duration of the monitoring session.
Send TestTests that the e-mail function is working; sends a test e-mail to the To: address designated in the editor.
CancelCancels the editing of the alert notification settings; previous settings are still in effect.
HelpOpens HPjmeter help to the beginning of this help topic.

 

Notification for a session ends when the monitoring session is closed.

Responding to Alerts

Alerts are automatically posted to the main console in the appropriate data tree, and if set, they are also sent to an email address. To investigate the alert further, double-click on the individual alert listed in the data tree in the main console window to open a window containing metric information for that particular alert.

The following information is specific for each alert type.

Abnormal Thread Termination Alert

HPjmeter detects threads that terminate abnormally because of an uncaught exception.

When HPjmeter detects that a thread terminated abnormally, the console main window displays an Abnormal Thread Termination Alert.

Double-clicking on the alert in the main window displays the uncaught exception window. The window shows:

  • Thread name

  • Exception

  • Source location where the exception was thrown

Figure 7-10 Abnormal Thread Termination Alert Visualizer

Abnormal Thread Termination Alert Visualizer

You can use this information to debug the cause of the exception. For example, each row in the Abnormal Thread Termination window represents a thread in the Thread Histogram window.

You can open the Thread Histogram metric, and notice that when a thread terminates, the associated bar in the Thread Histogram display is shorter than the others. Note that the thread histogram does not distinguish between threads that terminate normally or abnormally.

Symptoms that an application might show if it has abnormally terminating threads include:

  • Poor application response.

    If worker threads terminate, then the application might continue to work, but at a reduced speed.

  • The entire application terminates.

    Usually the application itself does not terminate as the result of one thread dying. However, it is possible that the entire application might eventually terminate if it cannot handle the loss of a thread.

See also:

Uncaught Exception Statistics

These statistics are derived from more than one metric.

The Uncaught Exception Statistics display shows you:

  • Thread name

  • Type of Exception

  • Time thrown, as the time from the start of the application

  • Throw point as a subentry

The window shows events in a hierarchical tree.

  • Select the View->Show Packages menu item to alternatively hide or show the Java package names to shorten the lines in the display.

  • Select the View->Show Stacktraces menu item to alternatively expand or collapse the thrown stack traces of all the exception nodes, or click on a specific node to expand or collapse its thrown stack trace only.

The results are cumulative over the life time of the session.

See also:

Excessive Compilation Alert

HPjmeter detects when a method is repeatedly compiled.

Double-click on the Excessive Compilation alert to display the metrics for excessive method compilation.

See also: Identifying Excessive Method Compilation .

Expected OutOfMemory Error Alert

HPjmeter detects memory leaks automatically and reports an alert before a crash occurs.

Double-click on the alert to open the Heap Monitor display.

The heuristic algorithms for alert triggers are tuned for server-oriented applications. The alerts are based on heuristic algorithms and are not offered with 100 percent certainty. Fluctuations in the application load may cause a transient increase in memory usage.

To confirm the leak, monitor the application for one hour or longer; then review the Garbage Collections metrics.

See also:

Heap Usage Alert

It can be useful to change the heap usage threshold in order to observe the heap structure at the selected usage point.

You can also set this threshold to notify you when heap usage exceeds your maximum or minimum expectations for the application.

For example, if you expect that your application should never consume more than 100 MB of heap for a target period of time, set the threshold fields for heap size and time sustained, and check that the alert is enabled. If the set values are exceeded, an alert is generated and recorded in the alert log. An alert notice is posted on the console.

Double-click on the alert to display the Heap Monitor visualizer. In this visualizer, you can see the memory allocated to the heap compared to usage over time, and including indicators for garbage collection events and their duration.

See also:

Memory Leak Locations Alert

HPjmeter detects potential Java collection memory leaks and identifies the source-file line of the leak.

The console main window displays a Memory Leak Locations Alert when a Java collection class memory leak is detected.

Double-clicking on the alert displays the Memory Leak Locations Window. The window shows:

  • Each detected Java collection leak object type

  • The leak source location

  • The life time of the leak

  • The collection object's current size

Figure 7-11 Memory Leak Locations Visualizer

Memory Leak Locations Visualizer

After some time, the alert icon may disappear if:

  • HPjmeter determines that the previously reported leak object is not a leak.

  • The leak-related collection object is removed by garbage collection.

HPjmeter has removed the alert icon when it removes all the leak nodes and no new memory leak detected.

See also:

Process CPU Utilization Alert

Enable this alert to track target levels of process CPU utilization. Significant variance from target levels may indicate the presence of performance bottlenecks. Bottlenecks are caused by thread starvation that occurs when the application is using all available CPU resources or when processes other than your application are using the available CPU resources.

Procedure 7-4 To Set the Process CPU Utilization Alert

  1. Connect to the server, and click the appropriate check box to enable the Process CPU Utilization Alert on the Alert tab in the Set Preferences window.

  2. Once connected to the JVM, open the Alert Controller.

  3. Scroll down if needed to see the Process CPU Utilization Alert. Check this box also to turn this alert on.

  4. Set the utilization threshold to reflect the expected consumption and designate a duration, if desired.

  5. Click Apply to activate checking for this threshold.

When the set threshold is met, an alert notice is posted on the console.

Double-click on the console alert to display the Percent CPU Utilization visualizer. In this visualizer, you can see system and process CPU usage during the period of the monitoring session plotted against the known resources of the server.

As an example, assume that you have a 4-CPU system, and you expect your Java application to consume at least 1.5 CPU.

HPjmeter presents CPU utilization percentages as the number of CPUs x 100 to arrive at the total possible percent of use. Therefore, expected use of 1.5 CPU would be equal to or greater than 150% of 1 CPU out of a total of 4 available CPU. By applying this value (150%) in the Alert Controller, HPjmeter notifies you when that value is exceeded during the monitoring session. A notification is generated for display on the console and recorded in the alert log.

Conversely, if you expect that your application will always use at least 100% of 1 CPU, set the operator at less than or equal to 100% to trigger a notification that the application is not consuming resources as expected.

For more information, see also:

System CPU Utilization Alert

Enable this alert to track target levels of system-level CPU usage. Significant variance from target levels may indicate over- or under-utilization of system resources.

Procedure 7-5 To Set the System CPU Utilization Alert

  1. Connect to the server, and click the appropriate check box to enable the System CPU Utilization Alert on the Alert tab in the Set Preferences window.

  2. Once connected to the JVM, open the Alert Controller.

  3. Scroll down if needed to see the System CPU Utilization Alert. Check this box also to turn this alert on.

  4. Set the utilization threshold to reflect the consumption threshold and designate a duration, if desired.

  5. Click Apply to activate checking for this threshold.

When the set threshold is met, an alert notice is posted on the console.

Double-click on the console alert to display the Percent CPU Utilization visualizer. In this visualizer, you can see system and process CPU usage during the period of the monitoring session plotted against the known resources of the server.

As an example, assume that you have a 4-CPU system, and you expect your Java application to consume no more than 3 CPU over any 5–minute period.

HPjmeter presents CPU utilization percentages as the number of CPUs x 100 to arrive at the total possible percent of use. Therefore, maximum use of 3 CPU would be equal to or greater than 300% of 1 CPU out of a total of 4 available CPU. By applying this value (300%) for a 5–minute duration in the Alert Controller, HPjmeter notifies you each time that value is exceeded for 5 minutes during the monitoring session. A notification is generated for display on the console and recorded in the alert log.

Conversely, if you expect that your application will always use at least 100% of 1 CPU, set the operator at less than or equal to 100% to trigger a notification that the application is not consuming resources as expected.

For more information, see also:

Thread Deadlock Alert

HPjmeter reports the possibility that two or more threads are attempting to acquire Java locks that have been acquired already by this set of threads.

Double-click the alert to display the thread histogram window. This allows you to determine which threads are deadlocked.

Deadlocked threads represent a multi-threaded program error.

An application experiencing a deadlock may not crash, but it is unresponsive to requests.

If the alert persists, it suggests a problem in the application logic that will need to be addressed by developers.

See also:

Printable version
Privacy statement Using this site means you accept its terms Feedback to webmaster
© 2005-2008 Hewlett-Packard Development Company, L.P.