Liking cljdoc? Tell your friends :D

lb.dns.manager

Background daemon for periodic DNS re-resolution.

Follows the same pattern as lb.health.manager:

  • ScheduledExecutorService for periodic tasks
  • Jitter to avoid thundering herd
  • Callbacks to update BPF maps on IP changes
  • Last-known-good fallback on failures
Background daemon for periodic DNS re-resolution.

Follows the same pattern as lb.health.manager:
- ScheduledExecutorService for periodic tasks
- Jitter to avoid thundering herd
- Callbacks to update BPF maps on IP changes
- Last-known-good fallback on failures
raw docstring

force-resolve!clj

(force-resolve! proxy-name hostname)

Force immediate DNS re-resolution for a hostname.

Force immediate DNS re-resolution for a hostname.
sourceraw docstring

get-all-dns-statusclj

(get-all-dns-status)

Get DNS resolution status for all proxies.

Get DNS resolution status for all proxies.
sourceraw docstring

get-dns-statusclj

(get-dns-status proxy-name)

Get DNS resolution status for a proxy.

Get DNS resolution status for a proxy.
sourceraw docstring

register-dns-target!clj

(register-dns-target! proxy-name hostname config update-callback)

Register a DNS-backed target for periodic resolution.

Parameters: proxy-name - Name of the proxy this target belongs to hostname - DNS hostname to resolve config - Map with: :port - Target port :weight - Weight for this target (1-100) :dns-refresh-seconds - Refresh interval (default 30) :health-check - Optional health check config update-callback - Function called with (hostname target-group) when IPs change

Returns true if registered successfully.

Note: Performs initial resolution synchronously. If initial resolution fails, throws an exception (startup failure).

Register a DNS-backed target for periodic resolution.

Parameters:
  proxy-name - Name of the proxy this target belongs to
  hostname - DNS hostname to resolve
  config - Map with:
    :port - Target port
    :weight - Weight for this target (1-100)
    :dns-refresh-seconds - Refresh interval (default 30)
    :health-check - Optional health check config
  update-callback - Function called with (hostname target-group) when IPs change

Returns true if registered successfully.

Note: Performs initial resolution synchronously. If initial resolution fails,
throws an exception (startup failure).
sourceraw docstring

running?clj

(running?)

Check if the DNS manager is running.

Check if the DNS manager is running.
sourceraw docstring

start!clj

(start!)

Start the DNS resolution manager.

Start the DNS resolution manager.
sourceraw docstring

stop!clj

(stop!)

Stop the DNS resolution manager.

Stop the DNS resolution manager.
sourceraw docstring

subscribe!clj

(subscribe! callback)

Subscribe to DNS events.

Callback receives events with keys: :type - :dns-resolved or :dns-failed :proxy-name - Proxy name :hostname - Hostname that was resolved :timestamp - Event timestamp :data - Event-specific data

Returns unsubscribe function.

Subscribe to DNS events.

Callback receives events with keys:
  :type - :dns-resolved or :dns-failed
  :proxy-name - Proxy name
  :hostname - Hostname that was resolved
  :timestamp - Event timestamp
  :data - Event-specific data

Returns unsubscribe function.
sourceraw docstring

unregister-dns-target!clj

(unregister-dns-target! proxy-name hostname)

Unregister a DNS target and stop its refresh task.

Unregister a DNS target and stop its refresh task.
sourceraw docstring

unregister-proxy!clj

(unregister-proxy! proxy-name)

Unregister all DNS targets for a proxy.

Unregister all DNS targets for a proxy.
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