Expand description
The deploy wire: config resources, scan-lock and scan calls on a trait of their own.
A separate trait by roadmap lock: super::GatewayApi has 15
hand-written test doubles, and the deploy wire must not force a change
on any of them. Every method here maps to exactly one EndpointDecl
in DEPLOY_ENDPOINTS, whose declared ResponseShape is enforced in
one place, send_shaped. Only id and shape are read at runtime; the
method and path_template columns are tied to what each method sends
by the wire_matches_the_endpoint_table contract test. A state-changing call is confirmed by a
follow-up read, never by its status: the scan POST’s own 200 is a
trigger-time snapshot (D4), and an acquire’s 200 body adds nothing the
info read does not give.
ReqwestGatewayApi::apply_auth is the only credential site; every
request built here passes through it before it is sent.
No POST (lock acquire, scan trigger, redundancy resync) is ever retried, refusals included: a repeated non-idempotent call against a production gateway is never silent. The poll engine wraps only the GET probes.
Structs§
- Endpoint
Decl - One declared endpoint: its id, wire verb, path and 2xx shape, and the capture block the shape was read from.
Enums§
- Response
Shape - What a 2xx answer on an endpoint may look like.
- Secret
Name Listing - What a secret provider’s name listing answered.
Constants§
- ACQUIRE_
TIMEOUT_ SLACK - Added to
acquireTimeoutfor the per-request client timeout, so a gateway that does wait out the acquire window answers before the client gives up and reports a fakenetwork_error(RESEARCH Pitfall 4). The live gateway never waited (D1); the slack costs nothing when it does not. - DEPLOY_
ENDPOINTS - The declared deploy endpoints. Shapes are copied from the
20-LIVE-CAPTURES.mdEndpoint shapes table.
Traits§
- Deploy
Api - The deploy-facing gateway calls. Not part of
super::GatewayApi.
Functions§
- endpoint_
decl - Look a declared endpoint up by id.
- resource_
list_ in_ collection - Read every resource of a type from one NAMED collection.
- scan_
and_ wait - Trigger a scan and wait until it is done:
scanActiveis false andlastScanTimestampexceeds the pre-trigger value read from the same gateway. An HTTP 200 on the trigger is never success on its own.