Add documentation for alerts

This commit is contained in:
TwinProduction
2020-08-22 14:15:44 -04:00
parent 22fef4e9aa
commit af6298de05
2 changed files with 52 additions and 15 deletions

View File

@ -1,10 +1,18 @@
package core
// Alert is the service's alert configuration
type Alert struct {
Type AlertType `yaml:"type"`
Enabled bool `yaml:"enabled"`
Threshold int `yaml:"threshold"`
Description string `yaml:"description"`
// Type of alert
Type AlertType `yaml:"type"`
// Enabled defines whether or not the alert is enabled
Enabled bool `yaml:"enabled"`
// Threshold is the number of failures in a row needed before triggering the alert
Threshold int `yaml:"threshold"`
// Description of the alert. Will be included in the alert sent.
Description string `yaml:"description"`
}
type AlertType string