ActiveMQ is an open source, JMS 1.1 compliant, message-oriented middleware (MOM) from the Apache Software Foundation that provides high-availability, performance, scalability, reliability and security for enterprise messaging.
The ActiveMQ Monitoring extension collects metrics from an ActiveMQ messaging server and uploads them to the AppDynamics Metric Browser.
<MACHINE_AGENT_HOME>/monitors/
.NOTE: Please place the extension in the "monitors" directory of your Machine Agent installation
directory. Do not place the extension in the "extensions" directory of your Machine Agent
installation directory.
Note : Please make sure to not use tab (\t) while editing yaml files. You may want to validate the yaml file using a yaml validator
Before configuring the extension, please make sure to run the below steps to check if the set up is correct.
Telnet into your activemq server from the box where the extension is deployed.
telnet
<port> - It is the jmxremote.port specified.
<hostname> - IP address
If telnet works, it confirm the access to the activemq server.
Start jconsole. Jconsole comes as a utitlity with installed jdk. After giving the correct host and port , check if activemq
mbean shows up.
Configure the ActiveMQ instances by editing the config.yml file in <MACHINE_AGENT_HOME>/monitors/ActiveMQMonitor/
.
There are a few fields that you need to make sure are filled in correctly.
Once done with them, they should allow you to establish a successful connection
with your server. They are :
servers:
- displayName: ""
host: ""
port:
# serviceUrl: ""
username: ""
password: ""
#encryptedPassword: ""
You should either use HOST AND PORT or just the SERVICEURL in order to establish a connection.
#Encryption key for Encrypted password.
encryptionKey: "axcdde43535hdhdgfiniyy576"
numberOfThreads: 15
You should either use the Normal PASSWORD or the encryptedPassword and encryptionKey in order to establish a connection. Please read below to find more information on Password Encryption.
<TIER NAME OR TIER ID>
in<TIER NAME OR TIER ID>
|Custom Metrics|ActiveMQ". For example, metricPrefix: "Server|Component:Extensions tier|Custom Metrics|ActiveMQ"
The objectNames mentioned in the above yaml may not match your environment exactly. Please use jconsole to extract the objectName and configure it
accordingly in the config.yaml.
You can use this extension to get all metrics that are available through the JMX Messaging service. In order to do so though, you will have to make sure that all metrics are defined correctly.
Please follow the next few steps in order to get this right.
mbeans:
- objectName: "org.apache.activemq:type=Broker,brokerName=*"
mbeanKeys: ["type", "brokerName"]
metrics:
include:
- name: "StorePercentUsage"
alias: "Store Percent Usage"
There are several properties that are associated with each metric. They are:
This format enables you to change some of the metric properties from what the default configurations are.
In Order to use them for each metric, please use the following example.
- objectName: "org.apache.activemq:type=Broker,brokerName=*,destinationType=Queue,destinationName=*"
mbeanKeys: ["type", "brokerName","destinationType","destinationName"]
metrics:
include:
- name: "AverageEnqueueTime"
alias: "Average Enqueue Time"
clusterRollUpType: "AVERAGE"
timeRollUpType: "SUM"
aggregationType: "SUM"
- objectName: "java.lang:type=Memory"
mbeanKeys: ["type"]
metrics:
include:
- name: "HeapMemoryUsage.committed"
alias: "Heap Memory Usage|Committed"
- name: "HeapMemoryUsage.used"
alias: "Heap Memory Usage|Used"
- objectName: "java.lang:type=Memory"
mbeanKeys: ["type"]
metrics:
include:
# Map Metric Level 1
- name: "MapOfString.key1"
alias: "Map 1|Key 1"
- name: "MapOfString.key2"
alias: "Map 1|Key 2"
# Map Metric Level 2
- name: "MapOfString.map2.key2"
alias: "Map 1|Map 2|Key 2"
# Map Metric Level 3
- name: "MapOfString.map2.map3.key32"
alias: "Map 1|Map 2|Map 3|Key 32"
multiplier: "20"
delta: false
aggregationType: "OBSERVATION"
timeRollUpType: "AVERAGE"
clusterRollUpType: "INDIVIDUAL"
convert : {
"ENDANGERED" : "1",
"NODE-SAFE" : "2",
"MACHINE-SAFE" : "3"
}
- objectName: "java.lang:type=Memory"
mbeanKeys: ["type"]
metrics:
include:
# List Metrics Can be set in the following ways:
- name: "listOfString.metric one"
alias: "listOfString|metric one"
- name: "listOfString.metric two"
alias: "listOfString|metric two"
- name: "listOfString.metric three"
alias: "listOfString|metric three"
Please visit this page to get detailed instructions on configuring Metric Path Character sequence replacements in Extensions.
Please visit Encryption Guidelines to get detailed instructions on password encryption. The steps in this document will guide you through the whole process.
If you want to use password encryption, please send arguments as connectionProperties. You will have to fill in the encrypted Password and Encryption Key fields in the config but you will also have to give an empty "" value to the password field and the encrypted password will be automatically picked up.
Workbench is an inbuilt feature provided with each extension in order to assist you to fine tune the extension setup before you actually
deploy it on the controller. Please review the following document on How to use the Extensions WorkBench
Please follow the steps listed in this troubleshooting-document in order to troubleshoot your issue.
These are a set of common issues that customers might have faced during the installation of the extension.
Always feel free to fork and contribute any changes directly here on GitHub.
Name | Version |
---|---|
Extension Version | 5.1.1 |
Product Tested On | ActiveMQ 5.16.0 |
Last Update | 12/01/2021 |
Changes list | Change log |
Note: While extensions are maintained and supported by customers under the open-source licensing model, they interact with agents and Controllers that are subject to AppDynamics’ maintenance and support policy. Some extensions have been tested with AppDynamics 4.5.13+ artifacts, but you are strongly recommended against using versions that are no longer supported.
Owner
Contributors
Categories
Products
AppDynamicsProgramming Languages
JavaLicense
Code Exchange Community
Get help, share code, and collaborate with other developers in the Code Exchange community.View Community