Skip to content

Commit 7a14e72

Browse files
authored
Merge pull request #55499 from bburt-rh/RHDEVDOCS-4892-add-deprecated-alertmanager-keywords
RHDEVDOCS-4892-add-deprecated-alertmanager-key-names
2 parents a0143e6 + 28ac940 commit 7a14e72

File tree

1 file changed

+21
-12
lines changed

1 file changed

+21
-12
lines changed

modules/monitoring-applying-custom-alertmanager-configuration.adoc

Lines changed: 21 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -35,15 +35,15 @@ route:
3535
repeat_interval: 12h
3636
receiver: default
3737
routes:
38-
- match:
39-
alertname: Watchdog
38+
- matchers:
39+
- "alertname=Watchdog"
4040
repeat_interval: 5m
4141
receiver: watchdog
42-
- match:
43-
service: <your_service> <1>
42+
- matchers:
43+
- "service=<your_service>" <1>
4444
routes:
45-
- match:
46-
<your_matching_rules> <2>
45+
- matchers:
46+
- <your_matching_rules> <2>
4747
receiver: <receiver> <3>
4848
receivers:
4949
- name: default
@@ -55,6 +55,15 @@ receivers:
5555
<2> `<your_matching_rules>` specifies the target alerts.
5656
<3> `receiver` specifies the receiver to use for the alert.
5757
+
58+
[NOTE]
59+
====
60+
Use the `matchers` key name to indicate the matchers that an alert has to fulfill to match the node.
61+
Do not use the `match` or `match_re` key names, which are both deprecated and planned for removal in a future release.
62+
63+
In addition, if you define inhibition rules, use the `target_matchers` key name to indicate the target matchers and the `source_matchers` key name to indicate the source matchers.
64+
Do not use the `target_match`, `target_match_re`, `source_match`, or `source_match_re` key names, which are deprecated and planned for removal in a future release.
65+
====
66+
+
5867
The following Alertmanager configuration example configures PagerDuty as an alert receiver:
5968
+
6069
[source,yaml,subs=quotes]
@@ -67,15 +76,15 @@ route:
6776
repeat_interval: 12h
6877
receiver: default
6978
routes:
70-
- match:
71-
alertname: Watchdog
79+
- matchers:
80+
- "alertname=Watchdog"
7281
repeat_interval: 5m
7382
receiver: watchdog
74-
*- match:
75-
service: example-app
83+
*- matchers:
84+
- "service=example-app"
7685
routes:
77-
- match:
78-
severity: critical
86+
- matchers:
87+
- "severity=critical"
7988
receiver: team-frontend-page*
8089
receivers:
8190
- name: default

0 commit comments

Comments
 (0)