Get relevant incident, fix config bug

- Make generic makeRequest fn
This commit is contained in:
Matej Kramny
2015-03-20 19:10:29 +01:00
parent f5826d7832
commit 8e17ebceef
5 changed files with 73 additions and 38 deletions

View File

@@ -83,7 +83,13 @@ func (monitor *Monitor) AnalyseData() {
monitor.Incident.Message += "\n\n" + *monitor.LastFailReason
}
// set investigating status
monitor.Incident.SetInvestigating()
// lookup relevant incident
monitor.Incident.GetSimilarIncidentId()
// create/update incident
monitor.Incident.Send()
} else if t < monitor.Threshold && monitor.Incident != nil {
// was down, created an incident, its now ok, make it resolved.