Alerting: Fix unmarshalling of GettableStatus to include time intervals (#112602)

* move test files into test-data

* add test for the bug

* populate time-intervals of gettableStatus config
This commit is contained in:
Yuri Tseretyan
2025-10-21 09:28:04 -04:00
committed by GitHub
parent 6851ca2988
commit 5f9a51418c
6 changed files with 383 additions and 8 deletions
@@ -485,10 +485,12 @@ func (s *GettableStatus) UnmarshalJSON(b []byte) error {
s.Cluster = amStatus.Cluster
s.Config = &PostableApiAlertingConfig{Config: Config{
Global: c.Global,
Route: AsGrafanaRoute(c.Route),
InhibitRules: c.InhibitRules,
Templates: c.Templates,
Global: c.Global,
Route: AsGrafanaRoute(c.Route),
InhibitRules: c.InhibitRules,
Templates: c.Templates,
MuteTimeIntervals: c.MuteTimeIntervals,
TimeIntervals: c.TimeIntervals,
}}
s.Uptime = amStatus.Uptime
s.VersionInfo = amStatus.VersionInfo