mirror of
https://github.com/grafana/grafana.git
synced 2025-01-15 19:22:34 -06:00
Docs: adds docs on excluding labels (#78806)
* Docs: adds docs on excluding labels * run prettier * Update docs/sources/alerting/fundamentals/annotation-label/labels-and-label-matchers.md Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com> * adds table for display * ran prettier --------- Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
This commit is contained in:
parent
12b624313c
commit
1b2a621533
@ -50,3 +50,15 @@ then:
|
||||
- A label matcher defined as `id=~[0-9]+` matches this alert rule.
|
||||
- A label matcher defined as `baz!~[0-9]+` matches this alert rule.
|
||||
- Two label matchers defined as `foo=bar` and `id=~[0-9]+` match this alert rule.
|
||||
|
||||
## Exclude labels
|
||||
|
||||
You can also write label matchers to exclude labels.
|
||||
|
||||
Here is an example that shows how to exclude the label `Team`. You can choose between any of the values below to exclude labels.
|
||||
|
||||
| Label | Operator | Value |
|
||||
| ------ | -------- | ----- |
|
||||
| `team` | `=` | `""` |
|
||||
| `team` | `!~` | `.+` |
|
||||
| `team` | `=~` | `^$` |
|
||||
|
Loading…
Reference in New Issue
Block a user