httpapi

package
v0.14.1 Latest Latest
Warning

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

Go to latest
Published: Oct 29, 2026 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewServer

func NewServer(deps ServerDeps) *http.Server

Types

type Reloader added in v0.14.0

type Reloader interface {
	Reload(ctx context.Context) model.ReloadStatus
	Status() model.ConfigStatus
}

Reloader is the part of reload.Reloader the API uses.

type ServerDeps

type ServerDeps struct {
	Config  *config.Config
	Metrics *metrics.Metrics
	BGP     *bgp.Manager
	Policy  *policy.Manager
	// Schedulers holds one scheduler per check, keyed by VIP name. It is
	// the static list used when Registry is nil (tests).
	Schedulers map[string][]*checks.Scheduler
	// Registry is the live scheduler list; a config reload changes it.
	Registry *checks.Registry
	// Reloader serves POST /api/v1/reload and the config block of /status;
	// nil disables both.
	Reloader Reloader
}

Jump to

Keyboard shortcuts

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