Skip to main content

Module handlers

Module handlers 

Source
Available on crate feature serve only.
Expand description

serve HTTP handlers.

Modules§

audit
GET /v1/audit — read the control-plane audit log (RBAC, #205). The route requires the AuditRead permission (admin-only), enforced by the auth middleware, so reaching this handler already means the caller is authorized.
backfill
POST /v1/backfill — submit a windowed backfill (#282) over the control plane. The range is planned server-side (same pure planner as faucet backfill) and one tracked run is submitted per window unit through the standard runner path, so every unit gets the full run lifecycle: history record, SSE logs, cancel, timeout_secs, cluster pull-balancing, and — when the config carries shard: { count } — Mode-B sharding tracked via shard_progress (a single wide window becomes one sharded run).
catalogcatalog
GET /v1/catalog/* — browse the Data Movement Catalog (#279): the accumulated cross-run picture of every dataset the server’s pipelines have touched. Read-only; all three routes require the CatalogRead permission (granted to every role, viewer up), enforced by the auth middleware.
dlq
/v1/dlq/* HTTP handlers — inspect, replay, and discard dead-letter-queue envelopes over the control plane. Thin glue over crate::dlq_replay: deserialize, call the orchestration, map errors to status codes.
doctor
POST /v1/doctor — validate + probe a submitted config WITHOUT running it. Reuses the same preflight as doctor_first: 200 with the report when all probes pass, 422 with the report as details when any fail.
health
Liveness (/healthz), readiness (/readyz), and Prometheus (/metrics) endpoints. All three are unauthenticated (probes / scrapers). Phase 1 /readyz is always-ready; it gains history-degraded / queue-full checks in later phases.
logs
GET /v1/runs/{id}/logs — a run’s captured log lines.
reload
POST /v1/reload — hot-reload the server’s --default-config merge base (#198) without restarting or interrupting in-flight runs.
runs
/v1/runs* HTTP handlers. Thin glue: deserialize, call into runner/history, map to status codes. All run-mutating logic lives in runner.rs.
schemas
GET /v1/schemas (catalog) and GET /v1/schemas/{kind}/{name} (one JSON Schema). Read-only; reuses the CLI’s schema introspection so the catalog always reflects the compiled connectors/transforms.
templatestemplates
/v1/templates* — the pipeline template registry + parameterized trigger API (#444).