v0.28.4 Latest Latest

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

Go to latest
Published: Nov 15, 2023 License: Apache-2.0 Imports: 4 Imported by: 14




This section is empty.


This section is empty.


func NamedHealthChecker

func NamedHealthChecker(name string, check UnnamedHealthChecker) healthz.HealthChecker

NamedHealthChecker creates a named health check from an unnamed one.

func NamedPingChecker

func NamedPingChecker(name string) healthz.HealthChecker

NamedPingChecker returns a health check with given name that returns no error when checked.


type MutableHealthzHandler

type MutableHealthzHandler struct {
	// contains filtered or unexported fields

MutableHealthzHandler returns a http.Handler that handles "/healthz" following the standard healthz mechanism.

This handler can register health checks after its creation, which is originally not allowed with standard healthz handler.

func NewMutableHealthzHandler

func NewMutableHealthzHandler(checks ...healthz.HealthChecker) *MutableHealthzHandler

func (*MutableHealthzHandler) AddHealthChecker

func (h *MutableHealthzHandler) AddHealthChecker(checks ...healthz.HealthChecker)

AddHealthChecker adds health check(s) to the handler.

Every time this function is called, the handler have to be re-initiated. It is advised to add as many checks at once as possible.

func (*MutableHealthzHandler) ServeHTTP

func (h *MutableHealthzHandler) ServeHTTP(writer http.ResponseWriter, request *http.Request)

type UnnamedHealthChecker

type UnnamedHealthChecker interface {
	Check(req *http.Request) error

UnnamedHealthChecker is an unnamed healthz checker. The name of the check can be set by the controller manager.

Jump to

Keyboard shortcuts

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