alertmanagertypes

package
v1.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 10, 2020 License: Apache-2.0 Imports: 2 Imported by: 1 module, 1 package

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Alert

type Alert struct {
	Key       string    `json:"alert_key"`
	Subject   string    `json:"subject"` // same type of error should always have same subject
	Details   string    `json:"details"`
	Timestamp time.Time `json:"timestamp"`
}

func NewAlert

func NewAlert(subject string, details string) Alert

func (*Alert) Equal

func (a *Alert) Equal(other Alert) bool

type DeadMansSwitch

type DeadMansSwitch struct {
	Subject string    `json:"subject"`
	TTL     time.Time `json:"ttl"`
}

func (*DeadMansSwitch) AsAlert

func (d *DeadMansSwitch) AsAlert(now time.Time) Alert

type DeadMansSwitchCheckinRequest

type DeadMansSwitchCheckinRequest struct {
	Subject string `json:"subject"`
	TTL     string `json:"ttl"`
}

otherwise the same but TTL in un-expanded form

func NewDeadMansSwitchCheckinRequest

func NewDeadMansSwitchCheckinRequest(subject string, ttl string) DeadMansSwitchCheckinRequest

func (*DeadMansSwitchCheckinRequest) AsAlert

func (d *DeadMansSwitchCheckinRequest) AsAlert(details string) Alert

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL