hyperlane-plugin-maintenance
Lock-free atomic maintenance and read-only mode middleware for Hyperlane.
Features
- Single atomic load on the
Activefast path (zero allocations, zero locks). - Instant zero-restart live transitions between
Active,ReadOnly(blocks non-safe HTTP methods), andMaintenance. - Exact path exemptions, segment-bounded prefix exemptions, and constant-time secret header token bypasses.
- Prebuilt
503 Service Unavailablewire buffers with configurableRetry-Afterand JSON/text payloads. - Transparent (
Status::Continue) when unconfigured (#[hyperlane::request_middleware(-109)]).
Quick Start
use ;
let plugin = init;
plugin.set_mode;