health

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Aug 25, 2023 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Heartbeat

func Heartbeat(ctx context.Context, tick <-chan time.Time, listenAddr string, logger log.StructuredLogger)

Heartbeat kicks off a goroutine that polls the /health endpoint at intervals determined by how frequently events are sent on the tick channel.

func NewEnvironmentHealthTracker

func NewEnvironmentHealthTracker(ctx context.Context, envs []string, s streamStatuser, t time.Duration) func() []domain.EnvironmentHealth

NewEnvironmentHealthTracker creates an EnvironmentHealthTracker

func StreamHealthCheck

func StreamHealthCheck() error

StreamHealthCheck checks if the GripControl stream is available - this is required to enable streaming mode

Types

type EnvironmentHealthTracker

type EnvironmentHealthTracker struct {
	*sync.RWMutex
	// contains filtered or unexported fields
}

EnvironmentHealthTracker tracks the health of environments

func (EnvironmentHealthTracker) GetEnvHealth

GetEnvHealth is a function that checks the health of all connected environments

Jump to

Keyboard shortcuts

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