Resolve all high-severity architecture review findings

This commit is contained in:
Joseph Doherty
2026-09-09 16:13:58 -04:00
parent 8bfe65512e
commit 146a13238f
192 changed files with 3160 additions and 753 deletions
+17
View File
@@ -881,3 +881,20 @@ orphaned entries) and in the CLI's `audit tree` output.
reusing the existing audit-KPI reads; the resulting `totalEventsLastHour` /
`errorEventsLastHour` / `backlogTotal` series render as trends on the Audit Log
page via `KpiTrendChart`.
### Serialized-byte budgets for telemetry and reconciliation (2026-09-09)
The audit-only drain, combined cached telemetry drain, and site reconciliation responses use
`AuditWireBudget`: the complete protobuf row (including error message/detail, summaries, extra,
provenance and nested operational fields), repeated-message tag/length prefixes, five-byte gRPC
frame and the continuation flag must fit a normal **2 MiB** budget. A drain sends a prefix and
marks only acknowledged rows forwarded. A byte-limited pull returns `MoreAvailable = true`;
its cursor advances from the last returned row, so unreturned rows remain available.
A single row exceeding 2 MiB is sent alone if it fits the coordinated **32 MiB** channel ceiling.
A row exceeding that ceiling is never truncated, falsely acknowledged or silently skipped:
the operation reports `ResourceExhausted` with its row identifier and required byte count, and
the row remains durable locally. Good rows preceding it can still advance. Operators must
reduce that oversized payload or deploy coordinated larger limits to resume past it; repeated
drain failures are logged. A lost response retains the existing at-least-once retry/cursor
semantics. The separate Flow Debugger trace pull remains governed by its own contract.