Liking cljdoc? Tell your friends :D

lb.lb-manager

Background manager for least-connections load balancing. Periodically scans connection tracking to compute and update weights based on the current connection distribution across backends.

Background manager for least-connections load balancing.
Periodically scans connection tracking to compute and update weights
based on the current connection distribution across backends.
raw docstring

force-update!clj

(force-update!)

Force an immediate weight update cycle.

Force an immediate weight update cycle.
sourceraw docstring

get-algorithmclj

(get-algorithm)

Get the current load balancing algorithm.

Get the current load balancing algorithm.
sourceraw docstring

get-connection-countsclj

(get-connection-counts)

Get current connection counts per backend for metrics. Returns map of {proxy-name {ip-port connection-count}}.

Get current connection counts per backend for metrics.
Returns map of {proxy-name {ip-port connection-count}}.
sourceraw docstring

get-proxy-infoclj

(get-proxy-info proxy-name)

Get current info for a specific proxy.

Get current info for a specific proxy.
sourceraw docstring

get-statusclj

(get-status)

Get current LB manager status.

Get current LB manager status.
sourceraw docstring

manager-stateclj

source

register-proxy!clj

(register-proxy! proxy-name
                 target-group
                 interfaces
                 port
                 listen-map
                 &
                 {:keys [get-health-fn get-drain-fn get-cb-fn]})

Register a proxy for least-connections weight management.

proxy-name: Unique identifier for the proxy target-group: TargetGroup record interfaces: Vector of interface names to update port: Listen port listen-map: BPF listen map reference opts: Optional callbacks for integration: :get-health-fn - Returns vector of health booleans :get-drain-fn - Returns vector of drain booleans :get-cb-fn - Returns vector of circuit breaker states

Register a proxy for least-connections weight management.

proxy-name: Unique identifier for the proxy
target-group: TargetGroup record
interfaces: Vector of interface names to update
port: Listen port
listen-map: BPF listen map reference
opts: Optional callbacks for integration:
      :get-health-fn - Returns vector of health booleans
      :get-drain-fn - Returns vector of drain booleans
      :get-cb-fn - Returns vector of circuit breaker states
sourceraw docstring

running?clj

(running?)

Check if the LB manager is running.

Check if the LB manager is running.
sourceraw docstring

start!clj

(start! conntrack-map lb-config)

Start the LB manager background daemon.

conntrack-map: BPF conntrack map for connection counting lb-config: LoadBalancingConfig record with algorithm settings

Start the LB manager background daemon.

conntrack-map: BPF conntrack map for connection counting
lb-config: LoadBalancingConfig record with algorithm settings
sourceraw docstring

stop!clj

(stop!)

Stop the LB manager background daemon.

Stop the LB manager background daemon.
sourceraw docstring

unregister-proxy!clj

(unregister-proxy! proxy-name)

Unregister a proxy from least-connections weight management.

Unregister a proxy from least-connections weight management.
sourceraw docstring

update-proxy-target-group!clj

(update-proxy-target-group! proxy-name new-target-group)

Update the target group for a registered proxy. Used when targets change due to DNS resolution etc.

Update the target group for a registered proxy.
Used when targets change due to DNS resolution etc.
sourceraw docstring

cljdoc builds & hosts documentation for Clojure/Script libraries

Keyboard shortcuts
Ctrl+kJump to recent docs
Move to previous article
Move to next article
Ctrl+/Jump to the search field
× close