Infrastructure agent - Remote JMX extension - metric filtering options
search cancel

Infrastructure agent - Remote JMX extension - metric filtering options

book

Article ID: 192738

calendar_today

Updated On:

Products

CA Application Performance Management Agent (APM / Wily / Introscope) CA Application Performance Management (APM / Wily / Introscope) INTROSCOPE DX Application Performance Management

Issue/Introduction

The Remote JMX monitoring extension for the APM Infrastructure Agent metrics allows the selection of which JMX data is to be reported. The documentation
 
 
describes how to use the Whitelist to specify for which Mbean objects JMX attributes are reported, and the module jmx.yml files to specify which attributes are reported.
 
By default all attributes of string or numeric types are reported for all MBeans
 
This KB gives some specific examples to aid in the configuration of this filtering.

Environment

Release : 11..x 19.x 20.x

Component : APM Agents

Resolution

Using the default property values in the extension the JMX branches reported for an example Tomcat agent look like this

 
Using the Whitelist feature it is possible to reduce the branches reported by setting the following property value
 
introscope.agent.remotejmx.system.s1.mbeanPatternsWhiteList=Users:type=Role,*;Catalina:type=Manager,*

To just the following

Below ‘Default’ only ‘Users’ and ‘Catalina’ branches are present, and below ‘Users’ only objects of type=Role are present.
 
If it is desired to restrict the attributes reported for an object then the modules approach is required.

For example to report only the processingTime attribute is required for Objects of Type=Manager under the Catalina branch
 
 

Using Jconsole it is possible to see the details of how this is exposed object is exposed

Create a new module (mymetrics) by creating a new module folder mymetrics under the extensions/remotejmx-dd040621-20.1.0.44/config/modules folder i.e.

/APMIA/apmia20.1.0.44/extensions/remotejmx-dd040621-20.1.0.44/config/modules/mymetrics

in here create a file jmx.yml with the following content

version: "1.0"
configElements:
  - objectName: "Catalina:type=Manager,*"
    attribute: "processingTime"
    metricName: "{rootNode}|{domain}|Context={context}|{host}|Type={type}:processingTime"
    metricType: "counter"

Note the wildcard in the ObjectName specification and how that relates to what is in Jconsole – it is possible to be more specific by defining additional elements of the name. Also note the use of  variables in the metricName and how they are expanded in the investigator (below)

Finally set the modules property in the bundles.properties file to include this new module

introscope.agent.remotejmx.system.s1.config.modules=jvm,mymetrics

 

And with the Whitelist defined as

introscope.agent.remotejmx.system.s1.mbeanPatternsWhiteList=Users:type=Role,*

This now reports as