AppDynamics Application Intelligence Platform

3.8.x Documentation

PDFs

Videos

Release Notes

Skip to end of metadata
Go to start of metadata

This topic discusses how to provide visibility into the JMX metrics for your JVM and application server.

JMX and MBeans Monitoring Application Infrastructure

As discussed at Monitor JVMs and Monitor Java App Servers, AppDynamics uses JMX (Java Management Extensions) to monitor Java applications.

JMX uses objects called MBeans (Managed Beans) to expose data and resources from your application. You can use one or more MBean attributes to create persistent JMX metrics in AppDynamics. In addition, you can import and export JMX metric configurations from one version or instance of AppDynamics to another.

Prerequisites for JMX Monitoring

AppDynamics can capture MBean data, when these conditions are met:

  • The monitored system must be running on Java 1.5 or later.
  • Each monitored Java process must enable JMX. See the JMX documentation.

Additional MBean data may be available when a monitored business application exposes Managed Beans (MBeans) using standard JMX. See the MBean documentation.

Preconfigured JMX Metrics

AppDynamics provides preconfigured JMX metrics for several common app server environments:

  • Apache ActiveMQ
  • Cassandra
  • Coherence
  • GlassFish
  • HornetQ
  • JBoss
  • Apache Solr
  • Apache Tomcat
  • Oracle WebLogic Server
  • WebSphere PMI

For application server environments that are not instrumented by default, you can configure new JMX metrics configurations. You can also add new JMX metric rules. See Configure JMX Metrics from MBeans. You can also add new metric rules to the existing set of configurations. For example, Glassfish JDBC connection pools can be manually configured using MBean attributes and custom JMX metrics.

To view the configuration of the preconfigured JMX metrics

  1. In the left navigation pane, click Configure -> Instrumentation and select the JMX tab. 
  2. The list of JMX Metric Configurations appears.
    Click a metric configuration to view the preconfigured JMX metrics for that app server.
  3. For example, selecting Cassandra shows the preconfigured JMX Metric Rules for Apache Cassandra.
    Double-click a metric rule to see configuration details such as the MBeans matching criteria and the MBean attributes being used to define the metric.
     

You can view, delete, and edit the existing JMX metric rules.

Using AppDynamics for JMX Monitoring

You can view MBean-based metrics using the Node Dashboard and the Metric Browser. In addition, the MBean Browser enables you to view all the MBeans defined in the system.

To view JMX metrics in the Metrics Browser

  1. In the left navigation pane, click Servers -> App Servers -> <Tier> -> <Node>. The Node Dashboard opens.
  2. Click the JMX tab. The JMX Metrics browser opens and displays the MBeans in a Metric Tree.
  3. To monitor a particular metric, double-click or drag and drop the metric onto the graph panel.
  4. Browse the default JMX metrics.
  5. You can perform all the operations that are provided by the Metric Browser such as:
  • Drill-down
  • Analyze the transaction snapshot for a selected time duration
  • Set the selected time range as a global time range

Trending MBeans Using Live Graphs

You can monitor the trend of a particular MBean attribute over time using the Live Graph.

To monitor the real-time trend of an MBean

  1. In the left navigation pane, click Servers -> App Servers -> <Tier> -> <Node>. The Node Dashboard opens.
  2. Click the JMX tab. 

  3. Click the MBean Browser sub-tab.

    Alternate Path to JMX Metrics

    Alternatively, in the left navigation pane, click Servers -> App Servers -> JMX. The JMX window appears
    If you haven't already selected a node, you are prompted to select a node and then a tier and then the JMX window appears

     

  4. Select the domain for which you want to monitor MBeans. For a description of domains see Monitor JVMs
  5. In the domain tree, expand the domains to find and then select the MBean that is of interest to you. 
  6. Expand the Attributes section and then choose an attribute of the MBean.
  7. Click Start Live Graph for Attribute and then click Start Live Graph. You can see the runtime values.
  8. Select an attribute and click Live Graph for Attribute to see a larger view of a particular graph.

Working with MBean Values

When troubleshooting or monitoring a Java-based system, you may want to change the values of composite mBeans and execute mBean methods. Using the JMX window, you can accomplish these tasks.

Prerequisite for Setting MBean Attributes and Invoking Operations

  • To change the value of an MBean attribute or invoke operation, your user account must have "Set JMX MBean Attributes and Invoke Operations" permissions for the application. For information about configuring user permissions for applications, see To Configure the Default Application Permissions.

To View and Edit the MBean Attribute Values

  1. From the JMX window, select MBean Browser.
  2. In the Domain tree, search and find the MBean that interests you.
  3. Select an editable attribute, one that has Yes in the Editable column, and then click View/Edit Attribute.
  4. In the MBean Attribute window that displays, you see the current value of the MBean Attribute.
  5. You can change the value of an editable MBean Attribute by entering a new value in the Value field.

To invoke MBean Operations

Using the JMX viewer, you can invoke an mBean operation, specify standard java language strings for the parameters, and view the return values from the mBean invocation.

  1. From the JMX window, select MBean Browser.
  2. In the Domain tree, search and find the MBean that interests you.
  3. Open the Operations pane, scroll to find the operation that interests you, and double-click the Invoke Action activator. 
  4. Enter the parameter values for the operation and then click Invoke. Click OK to invoke the operation.
    Scalar values for constructors of complex types, such as getMBeanInfo(java.util.Locale) allow you to enter "en-us".
    A message appears indicating that the operation is in progress and the number of seconds elapsed. When the operation completes, the results display.
    The method return result from an invocation can also be a complex attribute.  In this case the name, description, type, and editable attributes of the method are also displace in the MBean Operation Result area.

To view Complex MBean Attributes

When the MBean is a complex type, you can view its details by double-clicking it as shown below.

Configuring New JMX Metrics

Required User Permissions

In addition to the preconfigured metrics, you can define a new persistent metric using a JMX Metric Rule that maps a set of attributes from one or more MBeans.

You can create a JMX metric from any MBean attribute or set of attributes. Once you create a persistent JMX metric, you can:

  • View it in the Metric Browser
  • Add it to a Custom Dashboard
  • Create a health rule for it so that you can receive alerts

The JMX Metrics Configuration panel is the central configuration interface for all of the JMX metrics that AppDynamics reports. You can use the MBean Browser to view MBeans exposed in your environment. From there, you can access the JMX Metrics Configuration panel by selecting an MBean attribute and clicking Create Metric.

For details, see Configure JMX Metrics from MBeans.

Reusing JMX Metric Configurations

Once you create a custom JMX metric configuration, you can keep the configuration for upgrade or other purposes. The JMX metric information is stored in an XML file that you can export and then import to another AppDynamics system. For instructions see Create, Import or Export JMX Metric Configurations.

Understanding JMX Metrics

Java Management Extensions (JMX) is a public specification for monitoring and managing Java applications. Through JMX, Appdynamics can access Java class properties that collect management data, such as the resources your application is consuming.

For information on the specific metrics available for you environment, see the documentation provided by your vendor. 

Learn More