loadbalancer

package
v0.0.0-...-a70ee18 Latest Latest
Warning

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

Go to latest
Published: Aug 4, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type LoadBalancer

type LoadBalancer struct {
	Algorithm algorithms.Algorithm
	Servers   []*models.Server
	Port      uint16
}

func New

func New(opts ...LoadBalancerOption) *LoadBalancer

func (*LoadBalancer) Listen

func (lb *LoadBalancer) Listen() error

type LoadBalancerOption

type LoadBalancerOption func(*LoadBalancer)

func WithAlgorithm

func WithAlgorithm(algorithm string) LoadBalancerOption

func WithPort

func WithPort(port uint16) LoadBalancerOption

func WithServers

func WithServers(servers []*models.Server) LoadBalancerOption

Jump to

Keyboard shortcuts

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