parse_rust_server/routes/health.rs
1//! `GET /health`. Credential-free upstream, and the endpoint every bring-up script polls.
2//!
3//! It reports liveness only, and that is now a known gap rather than a pending one: storage has
4//! landed, so this must learn to distinguish "process up" from "database reachable". A health
5//! endpoint that returns ok before its dependencies are connected turns every startup race into a
6//! mystery test failure, because the harness stops polling exactly when the server is least ready.
7
8use axum::response::{IntoResponse, Response};
9use serde_json::json;
10
11pub async fn health() -> Response {
12 axum::Json(json!({ "status": "ok" })).into_response()
13}