mirror of
https://github.com/prometheus/alertmanager
synced 2024-12-27 08:32:15 +00:00
The default group_by is meant to be no labels. (#1287)
This is what the intended default is, and what the documentation says.
This commit is contained in:
parent
8c9e0cf50c
commit
aa950668bf
@ -31,9 +31,7 @@ var DefaultRouteOpts = RouteOpts{
|
|||||||
GroupWait: 30 * time.Second,
|
GroupWait: 30 * time.Second,
|
||||||
GroupInterval: 5 * time.Minute,
|
GroupInterval: 5 * time.Minute,
|
||||||
RepeatInterval: 4 * time.Hour,
|
RepeatInterval: 4 * time.Hour,
|
||||||
GroupBy: map[model.LabelName]struct{}{
|
GroupBy: map[model.LabelName]struct{}{},
|
||||||
model.AlertNameLabel: struct{}{},
|
|
||||||
},
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// A Route is a node that contains definitions of how to handle alerts.
|
// A Route is a node that contains definitions of how to handle alerts.
|
||||||
|
@ -33,7 +33,7 @@ func TestMergeAlerts(t *testing.T) {
|
|||||||
conf := `
|
conf := `
|
||||||
route:
|
route:
|
||||||
receiver: "default"
|
receiver: "default"
|
||||||
group_by: []
|
group_by: [alertname]
|
||||||
group_wait: 1s
|
group_wait: 1s
|
||||||
group_interval: 1s
|
group_interval: 1s
|
||||||
repeat_interval: 1ms
|
repeat_interval: 1ms
|
||||||
@ -109,7 +109,7 @@ func TestRepeat(t *testing.T) {
|
|||||||
conf := `
|
conf := `
|
||||||
route:
|
route:
|
||||||
receiver: "default"
|
receiver: "default"
|
||||||
group_by: []
|
group_by: [alertname]
|
||||||
group_wait: 1s
|
group_wait: 1s
|
||||||
group_interval: 1s
|
group_interval: 1s
|
||||||
repeat_interval: 1ms
|
repeat_interval: 1ms
|
||||||
@ -168,7 +168,7 @@ func TestRetry(t *testing.T) {
|
|||||||
conf := `
|
conf := `
|
||||||
route:
|
route:
|
||||||
receiver: "default"
|
receiver: "default"
|
||||||
group_by: []
|
group_by: [alertname]
|
||||||
group_wait: 1s
|
group_wait: 1s
|
||||||
group_interval: 1s
|
group_interval: 1s
|
||||||
repeat_interval: 3s
|
repeat_interval: 3s
|
||||||
|
Loading…
Reference in New Issue
Block a user