healthz

package module
v0.0.0-...-43a3337 Latest Latest
Warning

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

Go to latest
Published: Dec 14, 2020 License: MIT Imports: 16 Imported by: 0

README

healthz

a GRPC/HTTP library to register healthcheck endpoints for k8s liveness and readiness

License

healthz is free and released under the MIT License

Authors

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrUnsuccessful = errors.New("unsuccessful health check")

Functions

func Register

func Register(opts ...HealthCheckOptions)

func Unregister

func Unregister()

Types

type HealthCheckOptions

type HealthCheckOptions func(c *serverCheckers)

func WithChecker

func WithChecker(chkr HealthChecker) HealthCheckOptions

func WithGRPCPort

func WithGRPCPort(port uint16) HealthCheckOptions

func WithGRPCServer

func WithGRPCServer(srv *grpc.Server) HealthCheckOptions

func WithHTTPPort

func WithHTTPPort(port uint16) HealthCheckOptions

type HealthChecker

type HealthChecker interface {
	HealthCheck(ctx context.Context) bool
}

Directories

Path Synopsis
proto
health/v1
Package proto is a reverse proxy.
Package proto is a reverse proxy.

Jump to

Keyboard shortcuts

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