health

package
v0.0.28 Latest Latest
Warning

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

Go to latest
Published: May 2, 2024 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrNoHealthyInstancesAvailable = errors.New("no healthy instances available")

Functions

func HealthyMariaDBReplica added in v0.0.25

func HealthyMariaDBReplica(ctx context.Context, client client.Client, mariadb *mariadbv1alpha1.MariaDB) (*int, error)

func HealthyMaxScalePod added in v0.0.25

func HealthyMaxScalePod(ctx context.Context, client client.Client, maxscale *mariadbv1alpha1.MaxScale) (*int, error)

func IsServiceHealthy added in v0.0.23

func IsServiceHealthy(ctx context.Context, client client.Client, serviceKey types.NamespacedName) (bool, error)

func IsStatefulSetHealthy added in v0.0.25

func IsStatefulSetHealthy(ctx context.Context, client ctrlclient.Client, key types.NamespacedName,
	opts ...HealthOpt) (bool, error)

Types

type EndpointPolicy

type EndpointPolicy string
const (
	EndpointPolicyAll        EndpointPolicy = "All"
	EndpointPolicyAtLeastOne EndpointPolicy = "AtLeastOne"
)

type HealthOpt added in v0.0.25

type HealthOpt func(*HealthOpts)

func WithDesiredReplicas added in v0.0.25

func WithDesiredReplicas(r int32) HealthOpt

func WithEndpointPolicy added in v0.0.25

func WithEndpointPolicy(e EndpointPolicy) HealthOpt

func WithPort added in v0.0.25

func WithPort(p int32) HealthOpt

type HealthOpts added in v0.0.25

type HealthOpts struct {
	DesiredReplicas int32
	Port            *int32
	EndpointPolicy  *EndpointPolicy
}

Jump to

Keyboard shortcuts

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