carlos / platform Public

Managed fleets 1b: plan and ledger notes reflect option 2

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
claude agent, operated by paul@keymail.dev 78f3d59053966019dbf72e0e2708d315b2480318 parent aaa9d15
2 files changed, +6 −0
  • docs/superpowers/notes/managed-fleets-1b-ledger.md +4 −0
  • docs/superpowers/plans/2026-10-30-managed-fleets-1b-box-per-instance.md +2 −0
diff --git a/docs/superpowers/notes/managed-fleets-1b-ledger.md b/docs/superpowers/notes/managed-fleets-1b-ledger.md
index 7d28286c7..dce9f7b7f 100644
--- a/docs/superpowers/notes/managed-fleets-1b-ledger.md
+++ b/docs/superpowers/notes/managed-fleets-1b-ledger.md
@@ -1,5 +1,7 @@
# Managed fleets 1b: build rulings and deferred minors (from the SDD ledger)
+Later rulings supersede earlier ones on the same point; the drain rule and Task 6a records were removed by the final ruling (option 2).
+
| T1 self | test "SetRecordRegion ... keep FleetBoxMoved as is" reads muddled | Ruling: SetRecordRegion clears FleetBox and FleetBoxAt and leaves FleetBoxMoved unchanged (a placement change between fleets is cut after hostname-history activation anyway) — cost if wrong: one field |
| T6 self | spans box side (heartbeat fields, durable failed-final-sync record in activator/host/status) and console side (worker, drain, detach, CLI, docs, registry columns) | Ruling: split into T6a (box side) and T6b (console side, consumes T6a's heartbeat fields) — two review surfaces, same plan text — cost if wrong: one extra dispatch |
Task 1: Ruling: TestPlan14RootReadCensus envelope drift (internal/provision) is left for Task 8 Step 1 (one census-propose for the whole branch) — every later task moves the envelope again — cost if wrong: CI red on intermediate pushes only
@@ -47,3 +49,5 @@ Task 7: minor (deferred): lost-box test should assert acquisition happens only a
Task 7: minor (deferred): restore runs emit Litestream diagnostics in test output
Task 7: minor (deferred): GOOS=darwin vet of internal/host fails on hawake_wiring_test.go:34 claimsOnEnv (reported pre-existing)
Task 8: Ruling: Luna D4 drops "after 20 minutes" (the lost-box threshold) — accepted verbatim per the copy precedent; the vaguer sentence is still true — cost if wrong: the docs omit a timing detail
+Final: Ruling (Paul, 2026-10-31, option 2): fix the pending-wake case centrally; replace the drain-completion evidence with terminate-confirmed detach (a box that ever held labelled records detaches only with --terminated); remove drainDone and Task 6a's box-side records and heartbeat fields (no remaining consumer; the wake refusal on record I/O errors would be behaviour with no purpose); the pre-existing Litestream SyncAndWait error discard becomes a follow-up discussion — cost: an unreplicated tail on a box terminated without a clean drain is lost
+Final: Ruling: after a fleet box acquires the lease for a labelled route it re-reads the instance RECORD from the bucket (through the store door) and refuses unless the record names this box with the same FleetBoxAt; one GET per cold wake of a labelled fleet route, no polling — the registry-only re-read misses a box whose reconcile lags, which could boot and then overwrite newer data — cost: one bucket GET per wake on labelled fleets
diff --git a/docs/superpowers/plans/2026-10-30-managed-fleets-1b-box-per-instance.md b/docs/superpowers/plans/2026-10-30-managed-fleets-1b-box-per-instance.md
index 0b0adbf00..48576709d 100644
--- a/docs/superpowers/plans/2026-10-30-managed-fleets-1b-box-per-instance.md
+++ b/docs/superpowers/plans/2026-10-30-managed-fleets-1b-box-per-instance.md
@@ -12,6 +12,8 @@
## Global Constraints
+> **Superseded in part (Paul, 2026-10-31, after the whole-branch review R1):** the drain rule (`drainDone`), the heartbeat fields `LeasesHeld`/`ReplicationFailures` and Task 6a's durable records were removed. A box that has ever held labelled records is detached only with `--terminated`. A wake on a labelled fleet route re-checks its registry row and its record under the lease. See spec "1b addendum" item 5 and `docs/superpowers/notes/managed-fleets-1b-ledger.md`.
+
- Unlabelled records behave exactly as on main. Single-box fleets, fleets with sidecars, and fleets holding any record the platform does not run (`Addr`/`Addrs` set, or a binary with hibernation off) are never labelled (`movable(rec)`, Task 2).
- **Activation gate** (`release.FleetBoxLabelFloor = "v0.33.0"`; the release that ships this must be v0.33.0 or later): the console labels a fleet only when (a) the fleet has two or more active boxes, (b) the fleet has no sidecar records, (c) every box in the deployment, platform and fleet, reports a version at or above the floor in its heartbeat (the same complete box listing `carlos system status` reads; an incomplete listing counts as not met), and (d) the console's own version is at or above it.
- **Alert:** once a fleet has labels, a box in it reporting a version below the floor pauses all relabelling for that fleet and raises an alert (an ERROR log line naming fleet, box and version, plus `LABELS PAUSED` in `carlos fleets ls`), until every box is back at or above the floor.