connectors

package
v1.6.0 Latest Latest
Warning

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

Go to latest
Published: Feb 21, 2024 License: BSD-3-Clause Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RandStringBytesMaskImpr

func RandStringBytesMaskImpr(n int) string

func RandomAlertId

func RandomAlertId() string

Types

type Alert

type Alert struct {
	Labels      map[string]string
	Start       time.Time
	State       State
	Description string
	Details     string
	Links       []html.HTML
	Silence     SilencerFunc
}

type Collector

type Collector interface {
	Collect(ctx context.Context) ([]Alert, error)
	String() string
}

type Connector

type Connector interface {
	Tag() string
	Collector
}

type SilencerFunc

type SilencerFunc func(ctx context.Context, duration time.Duration, user string) error

type State

type State int
const (
	OK       State = 0
	Warning  State = 1
	Critical State = 2
	Unknown  State = 3
)

func (State) String

func (s State) String() string

Directories

Path Synopsis
Package nagiosapi provides access to nagios-api
Package nagiosapi provides access to nagios-api

Jump to

Keyboard shortcuts

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