Help us shape the future of Go! Take the 2026 Go Developer Survey

haproxy

package
v2.9.1 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Dump

func Dump(file string)

func GetConfigFilePath

func GetConfigFilePath(endpointID string) string

func GetPidFilePath

func GetPidFilePath(endpointID string) string

func GetStatsSocketPath

func GetStatsSocketPath(endpointID string) string

func TryRemoveFile

func TryRemoveFile(file string)

Types

type FakeHaproxy

type FakeHaproxy struct {
	Running                bool
	AddInstanceReturnError error
}

func NewFakeHaproxy

func NewFakeHaproxy() *FakeHaproxy

func (*FakeHaproxy) AddInstance

func (h *FakeHaproxy) AddInstance(injection *models.ServiceInjection) error

func (*FakeHaproxy) CollectStats

func (h *FakeHaproxy) CollectStats()

func (*FakeHaproxy) IsRunning

func (h *FakeHaproxy) IsRunning(endpointID string) bool

func (*FakeHaproxy) RemoveInstance

func (h *FakeHaproxy) RemoveInstance(endpointID string) error

func (*FakeHaproxy) Run

func (h *FakeHaproxy) Run(ctx context.Context)

type HAProxy

type HAProxy interface {
	CollectStats()
	IsRunning(endpointID string) bool
	AddInstance(injection *models.ServiceInjection) error
	RemoveInstance(endpointID string) error
	Run(ctx context.Context)
}

type HAProxyController

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

func NewHAProxyController

func NewHAProxyController() *HAProxyController

func (*HAProxyController) AddInstance

func (h *HAProxyController) AddInstance(si *models.ServiceInjection) error

func (*HAProxyController) CollectStats

func (h *HAProxyController) CollectStats()

func (*HAProxyController) IsRunning

func (h *HAProxyController) IsRunning(endpointID string) bool

func (*HAProxyController) RemoveInstance

func (h *HAProxyController) RemoveInstance(endpointID string) error

func (*HAProxyController) Run

func (h *HAProxyController) Run(ctx context.Context)

Jump to

Keyboard shortcuts

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