The runner's pod launcher stores its warm status, placement and crate mirror
allowlist reads in the settings row warm_report (bumping the envs topic only).
GET /api/envs/caches and autocraft-server envs caches combine it with the warm
tasks, default-branch heads and warm targets: the warm state per repository,
what each node holds and has pending, where each key is placed and whether the
placed nodes hold its newest version, and the mirror's git allowlist.
Each launcher pass reads a running step container's new output (one read of at
most 512 KB, complete lines only) and appends it to the task log; the rest
follows when the step ends. Reads start at a whole second before the last
appended line (sinceTime, timestamps) and skip the lines of that window already
appended, so lines sharing a timestamp at the boundary are neither dropped nor
repeated. The position is kept per container in build_pod_runs.log_positions and
written in the same transaction as the appended lines, so a runner restart
resumes exactly where it stopped.
Screenshots shows while an enabled build environment reports a display, Nightly checks while
one reports a nightly check's toolchain. The repo page follows environment changes live. The
mock Kubernetes environment gets the display setting.
- Db.fresh runs its reads past the request's shared reads. The session token refresh, the user-token vault, the check and workspace relays and their lease checks use it, since each reads a row again until another process changes it.
- The item page reads the stamp first on every load, so a stamp never runs ahead of the data it is sent with.
- One shareReads scope keeps at most 2,000 statements; later ones read uncached.
featureOn reads only the repo switch; a one-time migration keeps a repo on only where the
global switch was on too, then removes the global rows (scan-tests keeps its instance-wide row).
The repo page shows Tests before push, Build batches and Implement queued issues with one line
each; operators and maintainers with write permission flip them. Screenshots, Nightly checks,
Build pull requests and scan tests keep their code and stored state without a switch. The
Build environments page drops its Build features section.
- Db.shareReads: within one read-only request, a Kysely SELECT with the same text and parameters is read once and handed out as copies; any write forgets them. The server runs every API GET in it.
- Stuck items: one title query instead of one per item; liveness reads together.
- Build tasks: batch PRs and item kinds read in one query each; artifacts, batches and the confidential check together.
- Repo settings list: each repo's parts read together, four repos at a time; label plan and seen checks read their inputs together.
- Decisions: toDecision starts its reads together; one decision and the item's decision read their rows through decisionPage; the list reads its counts alongside the page.
- Needs: feedback, counts and stopped rows together; feedback items in one query.
- Item page: a first load reads the stamp alongside the page, parts start as their inputs arrive; trace context, header and fingerprint read in one wave each; itemCore reuses its files and checks reads.
- Settle memo: concurrent callers wait for one roles read.
- scripts/page-bench.ts: route timings and round trips on a seeded Postgres through the latency proxy.