Health Check
system
Health Check
Liveness/health check for Railway monitoring and the in-container watchdog.
Declared async (not def) so it is served directly on the event loop
and never needs an anyio threadpool slot. A flood of slow synchronous
endpoints (e.g. /v1/categories’ 3-4s aggregation) can pin all 40 threadpool
threads; a sync /health would queue behind them, miss the watchdog’s
consecutive liveness checks, and trip the hard-exit crash loop (issue #203).
Returning a static payload off the threadpool keeps liveness answerable
under that load.
GET
Health Check