Expand description
The serving edge: a loopback-only HTTP server over the layout Document.
This crate is where tokio lives (design doc: engine crates stay sync + pure; the
runtime is quarantined to I/O edges). It exposes exactly ONE content endpoint (D12) and
binds 127.0.0.1 only, guarded against DNS rebinding (D6). The document is a snapshot:
serialized once at bind time, then served as immutable bytes — re-polls are answered
with a strong ETag/304 pair, which is all the UI’s disconnect detection needs.
Structs§
- Server
- A bound-but-not-yet-serving server: bind and serve are split so the caller can print the real URL (OS-assigned port included) before the accept loop starts.
Enums§
- Serve
Error - Everything that can go wrong at the serving edge, typed so the CLI can phrase each case.
Constants§
- DOCUMENT_
ROUTE - The one content endpoint (D12): the versioned view-model document, whole.
- PAYLOAD_
ROUTE - Expand-on-demand (issue #30):
POSTaSlotAddresstaken from a truncated slot on the document, get its full text back. A second route rather than a query string on the first — aSlotAddress’s field-diff path can contain arbitrary characters, and it already has aSerialize/Deserializeimpl the web painter can round-trip verbatim without inventing an encoding of its own.