Skip to main content

Module bridge

Module bridge 

Source
Expand description

The node-local HTTP bridge: POST /api/v1/store/ingest.

A deliberately small HTTP/1.1 server: one request per connection, Content-Length bodies only, strict limits, no keep-alive (the Seed ingest endpoint stalls keep-alive connections, so cogs already cope).

Order of checks per request: request line, headers (size-bounded), token (401 unknown, 403 another instance’s), per-instance request rate (429), body length (411/413), body read, shape validation (400/413), per-instance vector budget (429), then the store owner. Nothing is read from the body of an unauthenticated request.

Structs§

BridgeConfig
Bridge settings.
BridgeHandle
A running listener.
BridgeStats
Counters, for evidence and tests.
IngestBridge
The bridge.

Enums§

BridgeScope
Which instances a listener accepts.

Constants§

MAX_CONNECTIONS
Most concurrent connections one bridge listener serves.
MAX_HEAD_BYTES
Largest request head (request line and headers).