Skip to content

Commit 772654b

Browse files
Merge pull request #262798 from heyams/heya/add-sample
Add a sample for metric filters
2 parents 9da0874 + 3197362 commit 772654b

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

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

Lines changed: 19 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,23 @@ 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 performance metrics like cpu and memory.
637+
638+
```json
639+
"processors": [
640+
{
641+
"type": "metric-filter",
642+
"exclude": {
643+
"matchType": "regexp",
644+
"metricNames": [
645+
".*"
646+
]
647+
}
648+
}
649+
]
650+
```
651+
633652
### Default metrics captured by Java agent
634653

635654
| Metric name | Metric type | Description | Filterable |

0 commit comments

Comments
 (0)