Documentation
¶
Overview ¶
Copyright 2025 HAProxy Technologies LLC
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2025 HAProxy Technologies LLC ¶
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2025 HAProxy Technologies LLC ¶
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2025 HAProxy Technologies LLC ¶
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2025 HAProxy Technologies LLC ¶
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2025 HAProxy Technologies LLC ¶
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2025 HAProxy Technologies LLC ¶
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2025 HAProxy Technologies LLC ¶
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2025 HAProxy Technologies LLC ¶
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2025 HAProxy Technologies LLC ¶
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Copyright 2025 HAProxy Technologies LLC ¶
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Index ¶
- Constants
- func DeepCopyBackend(original *models.Backend) (*models.Backend, error)
- func DeepCopyFrontend(original *models.Frontend) (*models.Frontend, error)
- func HashSHA1(data string) string
- type BackendImpactedInCycle
- type BackendOwnerType
- type BackendPort
- type BackendReferencedBy
- type BackendsImpactedInCycle
- type Configuration
- type Endpoints
- type ErrMapRuntimeUpdate
- type FirstSync
- type HaproxyConfMgr
- type HaproxyConfMgrImpl
- type HaproxyConfMgrParams
- type HaproxyConfParams
- type HaproxyConfUpdateResult
- type HaproxyDirs
- type RouteMgrImpl
- type RuntimeServerStateData
- type ServerDiff
- type SvcEndpoints
Constants ¶
const BufferSize = 16000
BufferSize is the default value of HAproxy tune.bufsize. Not recommended to change it Map payload or socket data cannot be bigger than tune.bufsize
Variables ¶
This section is empty.
Functions ¶
Types ¶
type BackendImpactedInCycle ¶
type BackendImpactedInCycle struct {
Name string
HTTPRouteKey client.ObjectKey
BackendRef gatewayv1.HTTPBackendRef
}
type BackendOwnerType ¶
type BackendOwnerType string
const ( BackendOwnerTypeHTTPRoute BackendOwnerType = "HTTPRoute" BackendOwnerTypeTLSRoute BackendOwnerType = "TLSRoute" )
type BackendPort ¶
type BackendPort struct {
// contains filtered or unexported fields
}
BackendPort is used to store both a backend name and the Service Port (not the target Port)
type BackendReferencedBy ¶
type BackendReferencedBy struct {
// contains filtered or unexported fields
}
func NewBackendOwners ¶
func NewBackendOwners() BackendReferencedBy
type BackendsImpactedInCycle ¶
type Configuration ¶
type Configuration struct {
// contains filtered or unexported fields
}
type ErrMapRuntimeUpdate ¶
ErrMapRuntimeUpdate is an error type for runtime map update failures
func (*ErrMapRuntimeUpdate) Error ¶
func (e *ErrMapRuntimeUpdate) Error() string
type HaproxyConfMgr ¶
type HaproxyConfMgr interface {
// ComputeDiffs computes the HAProxy configuration diffs.
ComputeDiffs(ctx context.Context) error
GetDiffs() diffs.HaproxyConfDiffs
}
func NewHaproxyConfMgr ¶
func NewHaproxyConfMgr(logger *slog.Logger, controllerStore *tree.ControllerStore, startupStructured structured.Structured, params HaproxyConfMgrParams, haproxyClient api.HAProxyClient, k8sClient client.Client, ) HaproxyConfMgr
type HaproxyConfMgrImpl ¶
type HaproxyConfMgrImpl struct {
// contains filtered or unexported fields
}
func (*HaproxyConfMgrImpl) ComputeDiffs ¶
func (b *HaproxyConfMgrImpl) ComputeDiffs(ctx context.Context) error
func (*HaproxyConfMgrImpl) GetDiffs ¶
func (b *HaproxyConfMgrImpl) GetDiffs() diffs.HaproxyConfDiffs
type HaproxyConfMgrParams ¶
type HaproxyConfMgrParams struct {
HaproxyConfParams
// contains filtered or unexported fields
}
func NewHaproxyConfMgrParams ¶
func NewHaproxyConfMgrParams(extractGVK utilsk8s.ExtractGVK, haproxyConfParams HaproxyConfParams, certificateStorage storage.CertificateStorage, mapsStorageEx storage.MapsStorageEx, ) (HaproxyConfMgrParams, error)
type HaproxyConfParams ¶
type HaproxyConfParams struct {
// HaproxyDirs contains all the needed dir
// used for example in map files reference
HaproxyDirs
// Templates for all generated names (Frontend, Backend, Server)
templates.Templates
// IPv4BindAddress is the IPv4 address to bind to.
IPv4BindAddress string
// IPv6BindAddress is the IPv6 address to bind to.
IPv6BindAddress string
// DefaultsSectionName is the defaults name to use to create FE/BE/...
DefaultsSectionName string
// StoreCertificateStructureType contains the structure type of the certificates storage
StoreCertificateStructureType storage.StructureType
StoreMapsStructureType storage.StructureType
// LindID: an ID for the link to the cluster
LinkID string
// TimeoutWaitForRuntime speficied the max time to wait for HUG library to the runtime.Runtime at startup
// This is used in combination with UpdateHaproxyThroughRuntime = true
// If UpdateHaproxyThroughRuntime = false, the gate library does not need runtime.Runtime and does not wait for it.
TimeoutWaitForRuntime time.Duration
// DisableIPv4 indicates whether IPv4 is disabled.
DisableIPv4 bool
// DisableIPv6 indicates whether IPv6 is disabled.
DisableIPv6 bool
// RuntimeUpdateHaproxy is a flag that indicates to the gate library to try to perform runtime commands
RuntimeUpdateHaproxy bool
// StoreCertificatesOnDisk is a flag that indicates to the gate library to store certificates on disk
StoreCertificateOnDisk bool
// StoreMapsOnDisk is a flag that indicates to the gate library to store maps on disk
StoreMapsOnDisk bool
}
type HaproxyConfUpdateResult ¶
type HaproxyDirs ¶
type RouteMgrImpl ¶
type RouteMgrImpl struct {
// contains filtered or unexported fields
}
func (*RouteMgrImpl) ResetMapFiles ¶ added in v0.9.0
func (b *RouteMgrImpl) ResetMapFiles()
type RuntimeServerStateData ¶
type ServerDiff ¶ added in v0.9.0
type ServerDiff struct {
// contains filtered or unexported fields
}
type SvcEndpoints ¶
type SvcEndpoints map[discoveryV1.AddressType]Endpoints
SvcEndpoints describes endpoints of a service port map[discoveryV1.AddressType]map[port]map[address]