Liking cljdoc? Tell your friends :D

lb.latency

Backend latency tracking for the load balancer. Tracks connection lifetime (creation to close) as latency metric. Exposes per-backend histograms for Prometheus export.

Backend latency tracking for the load balancer.
Tracks connection lifetime (creation to close) as latency metric.
Exposes per-backend histograms for Prometheus export.
raw docstring

get-all-histogramsclj

(get-all-histograms)

Get all latency histograms. Returns map of [proxy-name target-id] -> histogram.

Get all latency histograms.
Returns map of [proxy-name target-id] -> histogram.
sourceraw docstring

get-histogramclj

(get-histogram proxy-name target-id)

Get latency histogram for a specific backend. Returns histogram map with :buckets :counts :sum :count, or nil if not found.

Get latency histogram for a specific backend.
Returns histogram map with :buckets :counts :sum :count, or nil if not found.
sourceraw docstring

get-histograms-for-metricsclj

(get-histograms-for-metrics)

Get histograms in format suitable for metrics collector. Returns map of [proxy-name target-ip target-port] -> histogram.

Get histograms in format suitable for metrics collector.
Returns map of [proxy-name target-ip target-port] -> histogram.
sourceraw docstring

get-percentilesclj

(get-percentiles proxy-name target-id)

Get latency percentiles for a backend. Returns {:p50 :p95 :p99 :mean :count} or nil if no data.

Get latency percentiles for a backend.
Returns {:p50 :p95 :p99 :mean :count} or nil if no data.
sourceraw docstring

get-statusclj

(get-status)

Get latency tracking status.

Get latency tracking status.
sourceraw docstring

record-latency!clj

(record-latency! proxy-name target-id latency-sec)

Record a connection latency observation for a backend. latency-sec: connection duration in seconds

Record a connection latency observation for a backend.
latency-sec: connection duration in seconds
sourceraw docstring

reset-histograms!clj

(reset-histograms!)

Reset all latency histogram data.

Reset all latency histogram data.
sourceraw docstring

running?clj

(running?)

Check if latency tracking is running.

Check if latency tracking is running.
sourceraw docstring

start!clj

(start! stats-stream conntrack-map proxy-name)

Start latency tracking. Subscribes to stats event stream.

Parameters: stats-stream: the stats event stream from lb.stats/create-event-stream conntrack-map: the connection tracking BPF map proxy-name: name of the proxy (used for metric labels)

Start latency tracking. Subscribes to stats event stream.

Parameters:
  stats-stream: the stats event stream from lb.stats/create-event-stream
  conntrack-map: the connection tracking BPF map
  proxy-name: name of the proxy (used for metric labels)
sourceraw docstring

stop!clj

(stop!)

Stop latency tracking.

Stop latency tracking.
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