Skip to content

Commit b7152b4

Browse files
authored
Add a sample for metric filters
1 parent e60b11d commit b7152b4

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

articles/azure-monitor/app/java-standalone-telemetry-processors.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -616,6 +616,8 @@ To configure this option, under `exclude`, specify the `matchType` one or more `
616616

617617
### Sample usage
618618

619+
The following sample shows how to exclude metrics with names "metricA" and "metricB".
620+
619621
```json
620622
"processors": [
621623
{
@@ -630,6 +632,21 @@ To configure this option, under `exclude`, specify the `matchType` one or more `
630632
}
631633
]
632634
```
635+
636+
The following sample show how to turn off all metrics including the default auto-collected using regexp.
637+
```json
638+
"processors": [
639+
{
640+
"type": "metric-filter",
641+
"exclude": {
642+
"matchType": "regexp",
643+
"metricNames": [
644+
".*"
645+
]
646+
}
647+
}
648+
]
649+
```
633650
### Default metrics captured by Java agent
634651

635652
| Metric name | Metric type | Description | Filterable |

0 commit comments

Comments
 (0)