healthcheck

package
v3.0.0 Latest Latest
Warning

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

Go to latest
Published: Apr 29, 2024 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ServiceHealthChecker

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

func NewServiceHealthChecker

func NewServiceHealthChecker(ctx context.Context, metrics metricsHealthCheck, config *dynamic.ServerHealthCheck, service StatusSetter, info *runtime.ServiceInfo, transport http.RoundTripper, targets map[string]*url.URL) *ServiceHealthChecker

func (*ServiceHealthChecker) Launch

func (shc *ServiceHealthChecker) Launch(ctx context.Context)

type StatusSetter

type StatusSetter interface {
	SetStatus(ctx context.Context, childName string, up bool)
}

StatusSetter should be implemented by a service that, when the status of a registered target change, needs to be notified of that change.

type StatusUpdater

type StatusUpdater interface {
	RegisterStatusUpdater(fn func(up bool)) error
}

StatusUpdater should be implemented by a service that, when its status changes (e.g. all if its children are down), needs to propagate upwards (to their parent(s)) that change.

Jump to

Keyboard shortcuts

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