Liking cljdoc? Tell your friends :D

lb.admin.handlers

Request handlers for Admin REST API endpoints.

Each handler receives a request map with:

  • :exchange - The HttpExchange object
  • :params - Path parameters extracted from URL
  • :body - Parsed JSON request body (or nil)

Each handler returns a result map with either:

  • {:data ...} for success
  • {:error "message" :code "CODE" :status 400} for errors
Request handlers for Admin REST API endpoints.

Each handler receives a request map with:
- :exchange - The HttpExchange object
- :params - Path parameters extracted from URL
- :body - Parsed JSON request body (or nil)

Each handler returns a result map with either:
- {:data ...} for success
- {:error "message" :code "CODE" :status 400} for errors
raw docstring

handle-add-drainclj

(handle-add-drain {:keys [body]})

POST /api/v1/drains - Start draining a backend

POST /api/v1/drains - Start draining a backend
sourceraw docstring

handle-add-proxyclj

(handle-add-proxy {:keys [body]})

POST /api/v1/proxies - Add a new proxy

POST /api/v1/proxies - Add a new proxy
sourceraw docstring

handle-add-sni-routeclj

(handle-add-sni-route {:keys [params body]})

POST /api/v1/proxies/:name/sni-routes - Add an SNI route

POST /api/v1/proxies/:name/sni-routes - Add an SNI route
sourceraw docstring

handle-add-source-routeclj

(handle-add-source-route {:keys [params body]})

POST /api/v1/proxies/:name/routes - Add a source route

POST /api/v1/proxies/:name/routes - Add a source route
sourceraw docstring

handle-clear-connectionsclj

(handle-clear-connections _request)

DELETE /api/v1/connections - Clear all connections

DELETE /api/v1/connections - Clear all connections
sourceraw docstring

handle-clear-rate-limitsclj

(handle-clear-rate-limits _request)

DELETE /api/v1/rate-limits - Clear all rate limits

DELETE /api/v1/rate-limits - Clear all rate limits
sourceraw docstring

handle-force-close-circuitclj

(handle-force-close-circuit {:keys [params]})

POST /api/v1/circuits/:target/close - Force circuit close

POST /api/v1/circuits/:target/close - Force circuit close
sourceraw docstring

handle-force-dns-resolveclj

(handle-force-dns-resolve {:keys [params]})

POST /api/v1/dns/:hostname/resolve - Force DNS resolution

POST /api/v1/dns/:hostname/resolve - Force DNS resolution
sourceraw docstring

handle-force-lb-updateclj

(handle-force-lb-update _request)

POST /api/v1/lb/update - Force load balancing weight update

POST /api/v1/lb/update - Force load balancing weight update
sourceraw docstring

handle-force-open-circuitclj

(handle-force-open-circuit {:keys [params]})

POST /api/v1/circuits/:target/open - Force circuit open

POST /api/v1/circuits/:target/open - Force circuit open
sourceraw docstring

handle-get-all-healthclj

(handle-get-all-health _request)

GET /api/v1/health - Get all health statuses

GET /api/v1/health - Get all health statuses
sourceraw docstring

handle-get-circuitsclj

(handle-get-circuits _request)

GET /api/v1/circuits - Get all circuit breaker states

GET /api/v1/circuits - Get all circuit breaker states
sourceraw docstring

handle-get-configclj

(handle-get-config _request)

GET /api/v1/config - Get current configuration

GET /api/v1/config - Get current configuration
sourceraw docstring

handle-get-connection-countclj

(handle-get-connection-count _request)

GET /api/v1/connections/count - Get connection count

GET /api/v1/connections/count - Get connection count
sourceraw docstring

handle-get-connection-statsclj

(handle-get-connection-stats _request)

GET /api/v1/connections/stats - Get connection statistics

GET /api/v1/connections/stats - Get connection statistics
sourceraw docstring

handle-get-connectionsclj

(handle-get-connections _request)

GET /api/v1/connections - List active connections

GET /api/v1/connections - List active connections
sourceraw docstring

handle-get-dns-statusclj

(handle-get-dns-status _request)

GET /api/v1/dns - Get all DNS resolution status

GET /api/v1/dns - Get all DNS resolution status
sourceraw docstring

handle-get-drainsclj

(handle-get-drains _request)

GET /api/v1/drains - Get all draining backends

GET /api/v1/drains - Get all draining backends
sourceraw docstring

handle-get-lb-statusclj

(handle-get-lb-status _request)

GET /api/v1/lb - Get load balancing status

GET /api/v1/lb - Get load balancing status
sourceraw docstring

handle-get-proxyclj

(handle-get-proxy {:keys [params]})

GET /api/v1/proxies/:name - Get a specific proxy

GET /api/v1/proxies/:name - Get a specific proxy
sourceraw docstring

handle-get-proxy-healthclj

(handle-get-proxy-health {:keys [params]})

GET /api/v1/health/:proxy - Get health status for a proxy

GET /api/v1/health/:proxy - Get health status for a proxy
sourceraw docstring

handle-get-rate-limitsclj

(handle-get-rate-limits _request)

GET /api/v1/rate-limits - Get rate limit configuration

GET /api/v1/rate-limits - Get rate limit configuration
sourceraw docstring

handle-get-statusclj

(handle-get-status _request)

GET /api/v1/status - Get overall LB status

GET /api/v1/status - Get overall LB status
sourceraw docstring

handle-list-proxiesclj

(handle-list-proxies _request)

GET /api/v1/proxies - List all proxies

GET /api/v1/proxies - List all proxies
sourceraw docstring

handle-list-sni-routesclj

(handle-list-sni-routes {:keys [params]})

GET /api/v1/proxies/:name/sni-routes - List SNI routes for a proxy

GET /api/v1/proxies/:name/sni-routes - List SNI routes for a proxy
sourceraw docstring

handle-list-source-routesclj

(handle-list-source-routes {:keys [params]})

GET /api/v1/proxies/:name/routes - List source routes for a proxy

GET /api/v1/proxies/:name/routes - List source routes for a proxy
sourceraw docstring

handle-reload-configclj

(handle-reload-config _request)

POST /api/v1/reload - Reload configuration from file

POST /api/v1/reload - Reload configuration from file
sourceraw docstring

handle-remove-drainclj

(handle-remove-drain {:keys [params body]})

DELETE /api/v1/drains/:target - Cancel draining for a backend

DELETE /api/v1/drains/:target - Cancel draining for a backend
sourceraw docstring

handle-remove-proxyclj

(handle-remove-proxy {:keys [params]})

DELETE /api/v1/proxies/:name - Remove a proxy

DELETE /api/v1/proxies/:name - Remove a proxy
sourceraw docstring

handle-remove-sni-routeclj

(handle-remove-sni-route {:keys [params]})

DELETE /api/v1/proxies/:name/sni-routes/:hostname - Remove an SNI route

DELETE /api/v1/proxies/:name/sni-routes/:hostname - Remove an SNI route
sourceraw docstring

handle-remove-source-routeclj

(handle-remove-source-route {:keys [params]})

DELETE /api/v1/proxies/:name/routes/:source - Remove a source route

DELETE /api/v1/proxies/:name/routes/:source - Remove a source route
sourceraw docstring

handle-reset-circuitclj

(handle-reset-circuit {:keys [params]})

POST /api/v1/circuits/:target/reset - Reset circuit

POST /api/v1/circuits/:target/reset - Reset circuit
sourceraw docstring

handle-set-backend-rate-limitclj

(handle-set-backend-rate-limit {:keys [body]})

POST /api/v1/rate-limits/backend - Set backend rate limit

POST /api/v1/rate-limits/backend - Set backend rate limit
sourceraw docstring

handle-set-source-rate-limitclj

(handle-set-source-rate-limit {:keys [body]})

POST /api/v1/rate-limits/source - Set source rate limit

POST /api/v1/rate-limits/source - Set source rate limit
sourceraw docstring

routesclj

All API route definitions.

All API route definitions.
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