lb

package
v0.4.1 Latest Latest
Warning

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

Go to latest
Published: Aug 29, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrWaitExternalIP = errors.New("service is waiting for external IP")
)

Functions

This section is empty.

Types

type BackendServer added in v0.2.0

type BackendServer interface {
	GetUID() types.UID
	GetNamespace() string
	GetName() string
	GetAddress() (string, bool)
}

type HealthCheckHandler added in v0.4.1

type HealthCheckHandler func(namespace, name string) error

type Manager

type Manager interface {
	// Step 1. Ensure loadbalancer
	EnsureLoadBalancer(lb *lbv1.LoadBalancer) error
	DeleteLoadBalancer(lb *lbv1.LoadBalancer) error

	// Step 2. Ensure loadbalancer external IP
	EnsureLoadBalancerServiceIP(lb *lbv1.LoadBalancer) (string, error)

	// Step 3. Ensure service backend servers
	EnsureBackendServers(lb *lbv1.LoadBalancer) ([]BackendServer, error)

	ListBackendServers(lb *lbv1.LoadBalancer) ([]BackendServer, error)

	// return the count of endpoints which are probed as Ready
	// if probe is disabled, then return the count of all endpoints
	GetProbeReadyBackendServerCount(lb *lbv1.LoadBalancer) (int, error)

	// register a handler to get which lb is happending changes per health check
	RegisterHealthCheckHandler(handler HealthCheckHandler) error
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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