macula_gateway_health (macula v0.20.5)

View Source

Macula Gateway Health Check Server

Provides HTTP health endpoints for Kubernetes liveness and readiness probes. Runs on a separate port (8080) from the main QUIC gateway (9443).

Endpoints: GET /health - Overall health status GET /ready - Readiness check (can accept traffic) GET /live - Liveness check (process is alive) GET /metrics - Basic metrics (optional)

Summary

Functions

Check if the gateway is healthy.

Set the readiness state.

Start the health check server.

Stop the health check server.

Functions

handle_call(Request, From, State)

handle_cast(Request, State)

handle_info(Info, State)

init(Opts)

is_healthy()

-spec is_healthy() -> boolean().

Check if the gateway is healthy.

set_ready(Ready)

-spec set_ready(boolean()) -> ok.

Set the readiness state.

start_link(Opts)

-spec start_link(proplists:proplist()) -> {ok, pid()} | {error, term()}.

Start the health check server.

stop()

-spec stop() -> ok.

Stop the health check server.

terminate(Reason, State)