health

package
v1.6.1 Latest Latest
Warning

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

Go to latest
Published: May 17, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	OK = "ok"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type ExecProbe

type ExecProbe struct {
	Command    string `yaml:"command,omitempty"`
	WorkingDir string `yaml:"working_dir,omitempty"`
}

type HttpProbe

type HttpProbe struct {
	Host   string `yaml:"host,omitempty"`
	Path   string `yaml:"path,omitempty"`
	Scheme string `yaml:"scheme,omitempty"`
	Port   int    `yaml:"port,omitempty"`
}

type Probe

type Probe struct {
	Exec             *ExecProbe `yaml:"exec,omitempty"`
	HttpGet          *HttpProbe `yaml:"http_get,omitempty"`
	InitialDelay     int        `yaml:"initial_delay_seconds,omitempty"`
	PeriodSeconds    int        `yaml:"period_seconds,omitempty"`
	TimeoutSeconds   int        `yaml:"timeout_seconds,omitempty"`
	SuccessThreshold int        `yaml:"success_threshold,omitempty"`
	FailureThreshold int        `yaml:"failure_threshold,omitempty"`
}

type Prober

type Prober struct {
	// contains filtered or unexported fields
}

func New

func New(name string, probe Probe, onCheckEnd func(bool, bool, string)) (*Prober, error)

func (*Prober) Start

func (p *Prober) Start()

func (*Prober) Stop

func (p *Prober) Stop()

Jump to

Keyboard shortcuts

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