The extension collects metrics supported by Azure Monitor using the Azure management APIs and displays them in the AppDynamics Metric Browser. Please refer the link below for details on supported metrics. https://docs.microsoft.com/en-us/azure/azure-monitor/platform/metrics-supported
NOTE: The extension is built using Azure Java SDK and may not monitor all the Azure services.
-
Before the extension is installed, the prerequisites mentioned here need to be met. Please do not proceed with the extension installation if the specified prerequisites are not met.
-
The extension collects metrics, which are supported with Azure Monitor using the Azure management APIs. In order to query the APIs, you should have the following Ids from App registrations in Azure Active Directory.
client:
tenant:
secret:
subscriptionId:
Please refer the link below for detailed steps here
- The extension should be able to connect to the Azure management Apis in order to collect and send metrics. To do this, you will have to either establish a remote connection in between the extension and the product, or have an agent on the same machine running the product in order for the extension to collect and send the metrics.
- Run 'mvn clean install' from azure-monitoring-extension
- Copy and unzip AzureMonitor-<version>.zip from 'target' directory into <machine_agent_dir>/monitors/
- Edit config.yml file in AzureMonitor/conf and provide the required configuration (see Configuration section)
- Restart the Machine Agent.
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.
In order to use the extension, you need to update the config.yml file that is present in the extension folder. Please find a detailed explanation for the configurable fields in the config.yml file.
- If SIM is enabled, then use the following metricPrefix
metricPrefix: "Custom Metrics|Azure"
else configure the "COMPONENT_ID" under which the metrics need to be reported. This can be done by changing the value of <COMPONENT_ID> inmetricPrefix: "Server|Component:<COMPONENT_ID>|Custom Metrics|Azure|"
.
For example,metricPrefix: "Server|Component:100|Custom Metrics|Azure|"
More details for metric prefix can be found here
-
Provide the Azure client, tenant, secret and SubscriptionId under the credentials.
credentials: client: "********-****-****-****-************" tenant: "********-****-****-****-************" secret: "*******" subscriptionId: "********-****-****-****-************"
services: - resourceGroups: ["my.resource-group"] # please put the required resourceGroups only serviceName: "Virtual machine" regions: [""East US""] # supports regex .* serviceInstances: ["my-vm"] #supports regex .*
resourceGroups: Azure Resource groups (this accepts an array of Resource groups with regex matching supported)
resourceGroups: ["myResourceGroups", "myResourceGroup1", "app.*"]
service: Name of the service or the resource that you want to monitor for e.g. Virtual machine or Storage account or SQL server. Clearly, this accepts a single entry for service. You can find the serviceName from Azure portal which is type of the resource.
serviceName: "Virtual machine"
regions: A list of entries for the regions of the service to be monitored.
regions: ["East US 2", "East US"]
serviceInstances: service instance or resource name which we want to monitor.
serviceInstances: ["myvm1", "myvm2"]
credentials: Azure Active Directory registered application credentials. You need to provide the client, tenant, secret and subscriptionId under it. Please refer the link for more details.
Example:
Configuration for Cosmos DB, where its instance belongs to a resourceGroup test-ext-appd
and have 2 instances running (say cosmos1
and cosmos2
) in 2 different regions, East US 2
and East US
. You should configure as below in the config.yml.
- displayName: "Azure Cosmos DB"
resourceGroups: ["test-ext-appd"] # Please put the concerned resourceGroups only
serviceName: "Cosmos DB account"
regions: ["East US", "East US 2"]
serviceInstances: ["cosmos1", "cosmos2"]
Configuration for Storage Account.
- displayName: "AzureAccount Storage"
resourceGroups: ["test-ext.*"]
service: "Storage account"
regions: ["East US"]
serviceInstances: [".*"]
NOTE: Since the resourceGroups, regions and serviceInstances support regex matching/filtering which means putting ".*" includes and queries for all the available resources from the account. Depending on the number of instances/resources that is being monitored, the extension may hit into rate limit issues(429 Too Many Requests) from Azure or even metrics explosion to the Appd Controller. Refer here for more details.
-
Configure the metrics in the metrics.xml.
For configuring the metrics in the metrics.xml, the following properties can be used:
Property Default value Possible values Description alias metric name Any string The substitute name to be used in the metric browser instead of metric name. statType "ave" "AVERAGE", "SUM", "MIN", "MAX" Azure configured values as returned by API aggregationType "AVERAGE" "AVERAGE", "SUM", "OBSERVATION" Aggregation qualifier timeRollUpType "AVERAGE" "AVERAGE", "SUM", "CURRENT" Time roll-up qualifier clusterRollUpType "INDIVIDUAL" "INDIVIDUAL", "COLLECTIVE" Cluster roll-up qualifier multiplier 1 Any number Value with which the metric needs to be multiplied. convert null Any key value map Set of key value pairs that indicates the value to which the metrics need to be transformed. eg: UP:0, DOWN:1 delta false true, false If enabled, gives the delta values of metrics instead of actual values. All these metric properties are optional, and the default value shown in the table is applied to the metric(if a property has not been specified) by default.
Metrics will be collected for the services and stats configured here. By default we have added the stats for Virtual machine. Please make sure to add the service and stats details for monitoring.
Please avoid using tab (\t) when editing yaml files. Please copy all the contents of the config.yml file and go to Yaml Validator . On reaching the website, paste the contents and press the “Validate YAML” button. If you get a valid output, that means your formatting is correct and you may move on to the next step.
Below is an example config for monitoring VMs for an account and regions:
#prefix used to show metrics in AppDynamics
metricPrefix: "Server|Component:<TIER_ID>|Custom Metrics|Azure|"
#metricPrefix: "Custom Metrics|Azure|"
accounts:
- displayName: "Az VM Instances"
credentials:
client: ""
tenant: ""
secret: ""
subscriptionId: ""
services:
- resourceGroups: ["my.*"] # Please put the required resourceGroups only
serviceName: "Virtual machine"
regions: [".*"]
serviceInstances: [".*"]
Below is the list of services which is supported by the extension:
1.Virtual machine
2.Storage account
3.Container instances
4.SQL server
5.App Service
6.App Service plan
7.ApplicationGateway
8.Cosmos DB Account
Typical metric path: Application Infrastructure Performance|<Tier>|Custom Metrics|Azure|<Account DisplayName>|<serviceName>|serviceInstanceName|<metric> followed by the metrics defined in the link below:
Please visit this page to get detailed instructions on password encryption. The steps in this document will guide you through the whole process.
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 | 1.0.5 |
Last Update | 11 May, 2021 |
Changes list | ChangeLog |
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.