Documentation ¶
Index ¶
- type Host
- type Registry
- func (r *Registry) Cleanup()
- func (r *Registry) Collect(ch chan<- prometheus.Metric)
- func (r *Registry) Describe(ch chan<- *prometheus.Desc)
- func (r *Registry) HostState(name string) (bool, bool)
- func (r *Registry) Hosts() []*Host
- func (r *Registry) IsLeading() bool
- func (r *Registry) Leading(leading bool)
- func (r *Registry) Register(name string)
- func (r *Registry) UpdateHostState(host string, state bool, reachable bool)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Host ¶
Host holds the state of a registered host
func (*Host) IsAlive ¶
IsAlive reports if the host is up or down. If the host has been unavailable 5 times in a row, it's considered "down". One successful request marks it as "up" again
func (*Host) UpdateStatus ¶
UpdateStatus updates the status of the host
Click to show internal directories.
Click to hide internal directories.