Skip to content

Commit 137a58a

Browse files
committed
small updates
1 parent 6e03c91 commit 137a58a

File tree

2 files changed

+27
-2
lines changed

2 files changed

+27
-2
lines changed

articles/azure-monitor/essentials/prometheus-api-promql.md

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ To set up Azure Active Directory authentication, follow the steps below:
3838
1. To register an app, follow the steps in [Register an App to request authorization tokens and work with APIs](../logs/api/register-app-for-token.md?tabs=portal)
3939

4040
### Allow your app access to your workspace
41-
Allow your app to query data from your Azure Monitor workspace.
41+
Assign the *Monitoring Data Reader* role your app so it can query data from your Azure Monitor workspace.
4242

4343
1. Open your Azure Monitor workspace in the Azure portal.
4444

@@ -78,7 +78,7 @@ curl -X POST 'https://login.microsoftonline.com/<tennant ID>/oauth2/token' \
7878
--data-urlencode 'grant_type=client_credentials' \
7979
--data-urlencode 'client_id=<your apps client ID>' \
8080
--data-urlencode 'client_secret=<your apps client secret' \
81-
--data-urlencode 'resource= https://prometheus.monitor.azure.com'
81+
--data-urlencode 'resource=https://prometheus.monitor.azure.com'
8282
```
8383

8484
Sample response body:
@@ -204,6 +204,13 @@ The following limitations are in addition to those detailed in the Prometheus sp
204204

205205
For more information on Prometheus metrics limits, see [Prometheus metrics](../../azure-monitor/service-limits.md#prometheus-metrics)
206206

207+
> [!NOTE]
208+
> Azure managed Prometheus is **case insensitive**. If one time series differs from another only by the casing of a string - metric name, label name, label value etc, it is treated the same time series. This behavior differs from native open source Prometheus which is a case sensitive system. For example, the following two time series are threated as the same time series in Azure managed Prometheus:
209+
> `diskSize(cluster=”eastus”, node=”node1”, filesystem=”usr_mnt”)`
210+
> `diskSize(cluster=”eastus”, node=”node1”, filesystem=”usr_MNT”)`
211+
> For more information on scraping and case sensitivity, see [Customize scraping of Prometheus metrics in Azure Monitor](./prometheus-metrics-scrape-configuration.md#case-sensitivity)
212+
213+
207214
## Next steps
208215

209216
[Azure Monitor workspace overview (preview)](./azure-monitor-workspace-overview.md)

articles/azure-monitor/essentials/prometheus-metrics-scrape-configuration.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,24 @@ ms.reviewer: aul
1111

1212
This article provides instructions on customizing metrics scraping for a Kubernetes cluster with the [metrics addon](prometheus-metrics-enable.md) in Azure Monitor.
1313

14+
## Case sensitivity
15+
Azure managed Prometheus is a case insensitive system. If one time series differs from another only by a difference in the case of a string - metric name, label name, label value etc, it is treated as the same time series. This behavior is different from native open source Prometheus which is a case sensitive system.
16+
17+
In Azure managed Prometheus the follow time series are considered the same:
18+
19+
`diskSize(cluster=”eastus”, node=”node1”, filesystem=”usr_mnt”)`
20+
`diskSize(cluster=”eastus”, node=”node1”, filesystem=”usr_MNT”)`
21+
22+
The above examples are a single time series in time series database.
23+
- Any samples ingested against them will be stored as if they are scraped/ingested against a single time series.
24+
- If the examples above are ingested with the same timestamp, one of them will be dropped randomly.
25+
- The casing that will be stored in the time series database and returned in query, is unpredictable. Different casing at different times for the same time series may be returned.
26+
- Any metric name or label name/value matcher present in the query, will be retrieved from time series database by making a case-insensitive comparison. If there is a case sensitive matcher in a query, it is automatically treated as a case-insensitive matcher when making string comparisons.
27+
28+
It is best practice to insure that a time series is produced/scraped only in 1 unique casing.
29+
30+
In OSS Prometheus the above time series are treated as two different time series. Any samples scraped/ingested against them will be stored separately.
31+
1432
## Configmaps
1533

1634
Three different configmaps can be configured to change the default settings of the metrics addon:

0 commit comments

Comments
 (0)