introduce state unknown for rules that have not been evaluated yet

This commit is contained in:
bergquist
2018-11-05 10:23:43 +01:00
parent 6f748d8a96
commit d25284a364
8 changed files with 46 additions and 7 deletions

View File

@@ -68,6 +68,11 @@ func (c *EvalContext) GetStateModel() *StateDescription {
Color: "#D63232",
Text: "Alerting",
}
case m.AlertStateUnknown:
return &StateDescription{
Color: "888888",
Text: "Unknown",
}
default:
panic("Unknown rule state for alert notifications " + c.Rule.State)
}