healthz

package
v0.17.3 Latest Latest
Warning

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

Go to latest
Published: Dec 14, 2023 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewHealthzerFn

func NewHealthzerFn(handle func(context.Context) error) healther

Types

type BoolHealthzer

type BoolHealthzer interface {
	Healthz() bool
}

BoolHealthzer interface

type BoolHealthzerWithContext

type BoolHealthzerWithContext interface {
	Healthz(ctx context.Context) bool
}

BoolHealthzerWithContext interface

type ErrorHealthzWithContext

type ErrorHealthzWithContext interface {
	Healthz(ctx context.Context) error
}

ErrorHealthzWithContext interface

type ErrorHealthzer

type ErrorHealthzer interface {
	Healthz() error
}

ErrorHealthzer interface

type Type

type Type string

Type type https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/

const (
	// TypeAlways will run on any checks
	TypeAlways Type = "always"
	// TypeStartup will run on /healthz/startup checks
	// > The kubelet uses startup probes to know when a container application has started. If such a probe is configured,
	// > it disables liveness and readiness checks until it succeeds, making sure those probes don't interfere with the
	// > application startup. This can be used to adopt liveness checks on slow starting containers, avoiding them getting
	// > killed by the kubelet before they are up and running.
	TypeStartup Type = "startup"
	// TypeReadiness will run on /healthz/readiness checks
	// > The kubelet uses readiness probes to know when a container is ready to start accepting traffic.
	// > A Pod is considered ready when all of its containers are ready. One use of this signal is to control
	// > which Pods are used as backends for Services. When a Pod is not ready, it is removed from Service load balancers.
	TypeReadiness Type = "readiness"
	// TypeLiveness  will run on /healthz/liveness checks
	// > The kubelet uses liveness probes to know when to restart a container. For example, liveness probes could catch
	// > a deadlock, where an application is running, but unable to make progress. Restarting a container in such a state
	// > can help to make the application more available despite bugs.
	TypeLiveness Type = "liveness"
)

func (Type) String

func (t Type) String() string

String interface

Jump to

Keyboard shortcuts

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