This extension works only with the standalone machine agent.
Monitor Metrics provided by the Azure Monitor/Service Fabric APIs and let them report into the AppDynamics Metric Browser.
- This extension requires the Java Machine Agent.
Either Download the Extension from the AppDynamics Marketplace or Download the Extension from the Github releases or Build from Source.
- Deploy the
AzureMonitor-<VERSION>.zip
file into the<machine agent home>/monitors
directory.
> unzip AzureMonitor-<VERSION>.zip -d <machine agent home>/monitors/
- Set up
config.yml
. At minimum this is:
# Client ID obtained from the Azure Portal
clientId: ""
# Client Key for the upper ID obtained from the Azure Portal
clientKey: ""
# Tenant ID obtained from the Azure Portal
tenantId: ""
# Subscription ID obtained from the Azure Portal
subscriptionId: ""
Details for the Setup can be found in the Azure - Resource Manager - Howto - Control Access - Create Service Principal - Azure Portal
- Restart the Machine Agent.
- Clone this repository
- Run
mvn -DskipTests clean install
- The
AzureMonitor-<VERSION>.zip
file can be found in thetarget
directory
Directory/File | Description |
---|---|
src/main/resources/config | Contains monitor.xml and config.yml |
src/main/java | Contains source code for the Azure monitoring extension |
src/test/java | Contains test code for the Azure monitoring extension |
target | Only obtained when using maven. Run 'maven clean install' to get the distributable .zip file. |
pom.xml | maven build script to package the project (required only if changing Java code) |
Metrics available for Azure are maintained within the Azure Monitor Documentation - Reference - Metrics Supported
You can exclude certain Metrics by adding an exclude within a filter Resource Element. To do this the following configuration in config.yml
is required:
filter:
- resourceType: "Microsoft.Storage/storageAccounts"
exclude: ".*"
A regular expression is needed. Any match will be ignored for that specific resource.
If you do not want to store the Client Key from the Service Principal that is used to query Resources, Metric Definitions and Metrics you can obtain the Key from an Azure Key Vault Secret.
To achieve this the following configuration in config.yml
is required:
# Keyvault Client ID obtained from the Azure Portal
keyvaultClientId: ""
# Keyvault Key for the upper ID obtained from the Azure Portal
keyvaultClientKey: ""
# Keyvault Client Secret Url. From this URL the clientKey will be obtained
keyvaultClientSecretUrl: ""
# Client ID obtained from the Azure Portal
clientId: ""
The Key Vault Client Key can also be encrypted just as the normal Client Key.
Currently the Extension supports Certificate based Authentication to gather the Health Status of your Service Fabric Clusters. To use this those properties in config.yml
have to be used:
serviceFabricCert: 'monitors/AzureMonitor/your-cert.pfx'
serviceFabricPassphrase: ''
To avoid setting the clear text password in the config.yml
. Please follow the process to encrypt the password and set the encrypted password and the key in the config.yml
.
- Download the util jar to encrypt the password from here
- Encrypt password from the commandline
java -cp appd-exts-commons-<VERSION>.jar com.appdynamics.extensions.crypto.Encryptor myEncryptionKey myPasswordToEnrypt
Always feel free to fork and contribute any changes directly via GitHub.
- Verify Machine Agent Data: Please start the Machine Agent without the extension and make sure that it reports data. Verify that the machine agent status is UP and it is reporting Hardware Metrics.
config.yml
: Validate the file here.- Metric Limit: Please start the machine agent with the argument
-Dappdynamics.agent.maxMetrics=5000
if there is a metric limit reached error in the logs. If you don't see the expected metrics, this could be the cause. - Check Logs: There could be some obvious errors in the machine agent logs. Please take a look.
The config cannot be null
error: This usually happens when on a windows machine inmonitor.xml
you giveconfig.yml
file path with linux file path separator/
. Use Windows file path separator\
e.g.monitors\Monitor\config.yml
. For Windows, please specify the complete path.- Collect Debug Logs: Edit the file,
<MachineAgent>/conf/logging/log4j.xml
and update the level of the appendercom.appdynamics
andcom.singularity
to debug. Let it run for 5-10 minutes and attach the logs to a support ticket.
For any questions or feature request, please contact AppDynamics Center of Excellence.