Expand description
The UDS door (§2.5, Phase 5) — .flint-sync/ctl.sock.
Three verbs: POST /v1/boundary, POST /v1/sync, GET /v1/status.
It is deliberately sugar over the file protocol, not a second
protocol: a request lands in the same pending record a
.flint/publish touch would, so min-interval, coalescing, the
work-metered budget, the covered-nonce ack and every crash rule
apply to it without a second implementation that could disagree
with the first. What the socket buys is a SYNCHRONOUS answer —
the caller gets the ack in the response instead of polling
.flint/publish.ack.
Why it is pod-internal only, and stays that way: the socket lives in the state directory, which is outside the scan by the shipped exclusion and inside the emptyDir every container in the pod shares. There is no TCP listener and no authentication, because the trust boundary is the pod — exactly as it is for the file sentinels, which any process in the pod can already touch (§3 residual 6). A TCP listener would be a new remote surface, which is a stated non-goal.
The listener owns NO syncer state. It forwards requests over a
channel to the run loop, which is the single thread that holds the
lease and the state directory — the same reason flint-sync status
reads files instead of claiming anything.
Enums§
- CtlRequest
- What the socket asks the run loop to do.
Functions§
- bind
- Bind the socket, replacing a stale one left by a crashed container.
- serve
- Serve until the listener dies. One connection, one request, one
response — HTTP/1.1 with no keep-alive, which is all
curl --unix-socketand every agent library needs. - socket_
path - Where the socket lives: the state directory, which is outside the scan and shared by every container in the pod.