healthcheck

package
v0.9.0 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AggregateHealthCheck added in v0.9.0

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

func NewHealthCheck added in v0.7.5

func NewHealthCheck(logger *zerolog.Logger, interval time.Duration, services []HealthCheck) *AggregateHealthCheck

func (*AggregateHealthCheck) AnyServiceUnhealthy added in v0.9.0

func (c *AggregateHealthCheck) AnyServiceUnhealthy() bool

func (*AggregateHealthCheck) CheckForFailures added in v0.9.0

func (c *AggregateHealthCheck) CheckForFailures() error

type ClientHealthChecker

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

ClientHealthChecker contains the port and check function callback

func NewClientHealthChecker

func NewClientHealthChecker(port string, f func() error) *ClientHealthChecker

NewClientHealthChecker function will return new ClientHealthChecker struct with specified port and checkFunction

func (*ClientHealthChecker) StartProbes

func (s *ClientHealthChecker) StartProbes()

StartProbes will initilize http endpoint for(/health) check

type HealthCheck added in v0.7.5

type HealthCheck struct {
	Ping        func() error
	ServiceName string
	// contains filtered or unexported fields
}

type HealthChecker added in v0.7.5

type HealthChecker interface {
	// HealthCheck checks whether the underlying connection is still ongoing.
	HealthCheck() error
}

Jump to

Keyboard shortcuts

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