Skip to content

Commit

Permalink
update readme
Browse files Browse the repository at this point in the history
Signed-off-by: Markus Blaschke <[email protected]>
  • Loading branch information
mblaschke committed Jul 23, 2023
1 parent 467959d commit 2e4e131
Showing 1 changed file with 2 additions and 38 deletions.
40 changes: 2 additions & 38 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -247,44 +247,8 @@ Using absolute calculated time:

### ResourceTags handling

Tag can be dynamically added to metrics and processed though filters

format is: `tagname?filter1` or `tagname?filter1&filter2`

| Tag filter | Description |
|------------|-----------------------------|
| `toLower` | Lowercasing Azure tag value |
| `toUpper` | Uppercasing Azure tag value |
see [armclient tagmanager documentation](https://github.com/webdevops/go-common/blob/main/azuresdk/README.md#tag-manager)

### AzureTracing metrics

(with 22.2.0 and later)

Azuretracing metrics collects latency and latency from azure-sdk-for-go and creates metrics and is controllable using
environment variables (eg. setting buckets, disabling metrics or disable autoreset).

| Metric | Description |
|------------------------------------------|----------------------------------------------------------------------------------------|
| `azurerm_api_ratelimit` | Azure ratelimit metrics (only on /metrics, resets after query due to limited validity) |
| `azurerm_api_request_*` | Azure request count and latency as histogram |

#### Settings

| Environment variable | Example | Description |
|------------------------------------------|------------------------------------|----------------------------------------------------------------|
| `METRIC_AZURERM_API_REQUEST_BUCKETS` | `1, 2.5, 5, 10, 30, 60, 90, 120` | Sets buckets for `azurerm_api_request` histogram metric |
| `METRIC_AZURERM_API_REQUEST_ENABLE` | `false` | Enables/disables `azurerm_api_request_*` metric |
| `METRIC_AZURERM_API_REQUEST_LABELS` | `apiEndpoint, method, statusCode` | Controls labels of `azurerm_api_request_*` metric |
| `METRIC_AZURERM_API_RATELIMIT_ENABLE` | `false` | Enables/disables `azurerm_api_ratelimit` metric |
| `METRIC_AZURERM_API_RATELIMIT_AUTORESET` | `false` | Enables/disables `azurerm_api_ratelimit` autoreset after fetch |


| `azurerm_api_request` label | Status | Description |
|-----------------------------|--------------------|----------------------------------------------------------------------------------------------------------|
| `apiEndpoint` | enabled by default | hostname of endpoint (max 3 parts) |
| `routingRegion` | enabled by default | detected region for API call, either routing region from Azure Management API or Azure resource location |
| `subscriptionID` | enabled by default | detected subscriptionID |
| `tenantID` | enabled by default | detected tenantID (extracted from jwt auth token) |
| `resourceProvider` | enabled by default | detected Azure Management API provider |
| `method` | enabled by default | HTTP method |
| `statusCode` | enabled by default | HTTP status code |
see [armclient tracing documentation](https://github.com/webdevops/go-common/blob/main/azuresdk/README.md#azuretracing-metrics)

0 comments on commit 2e4e131

Please sign in to comment.