alias-wake-338: Astra review brief, round 1
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
1 file changed,
+93
−0
docs/superpowers/reviews/CODEX-REVIEW-BRIEF-alias-wake-338.md+93 −0
CI failed — run details
diff --git a/docs/superpowers/reviews/CODEX-REVIEW-BRIEF-alias-wake-338.md b/docs/superpowers/reviews/CODEX-REVIEW-BRIEF-alias-wake-338.md| new file mode 100644 |
| index 000000000..ae34759ff |
| --- /dev/null |
| +++ b/docs/superpowers/reviews/CODEX-REVIEW-BRIEF-alias-wake-338.md |
| @@ -0,0 +1,93 @@ |
| +# Review brief: branch alias-wake-338, round 1 of 3 |
| + |
| +Repo carlos/platform, branch `alias-wake-338`, commit a4824e656daf12928bf8bbcac57e625cd09508d4. |
| +Under review: the diff `d3c5601be33f99fb64f293dc6d308b9301567c08..a4824e656daf12928bf8bbcac57e625cd09508d4` (`git diff origin/main...HEAD`). |
| +Authorities: AGENTS.md on main (stopping rules, the census); amadan |
| +discussions #338 and #392; the merged first fix d3c5601b (aliases follow |
| +their instance's socket). Do not review against unmerged branches. |
| + |
| +You are an independent reviewer. Read the diff, then the code it touches |
| +and calls, and check every claim against that code. |
| + |
| +## The change |
| + |
| +A platform alias (`Route.Platform`, the domains pass's apex mint) shares |
| +its instance's socket. The edge built it as a plain socket proxy |
| +(internal/edge/edge.go, the `t.Socket != ""` arm with Hibernate false), |
| +so it never woke a sleeping instance and answered 502 while it slept. |
| + |
| +internal/edge/platformalias.go `platformAliasFold` and its use in |
| +`Edge.Reload` (after the path fold, before the attached-hostname fold): |
| +an alias with exactly one ready non-platform, non-sidecar route of the |
| +same effective account and app on its socket takes that route's OWN |
| +upstream entry (as #151 attached hostnames do: same proxy, route, |
| +hibernating), so the existing activator wake path applies. An alias |
| +whose socket only another tenant's route holds is dropped from the map. |
| +`currentHosts` keeps a resolved alias (`platformAlias`) in the wildcard |
| +parent set; the #151 fold clears the flag for hostnames attached to it. |
| + |
| +## Fixed: do not re-argue |
| + |
| +- Paul's goal: these addresses work. The coordinator asked for this |
| + follow-up to reuse the existing wake path, never across tenants. |
| +- Behaviour that follows from sharing the instance's entry, intended: |
| + the instance's gate now applies to its alias (it was bypassed); usage, |
| + the version header and purge tenancy are the instance's (as for #151); |
| + the response cache keys on the requested host. |
| + |
| +## What to check |
| + |
| +1. Tenant boundary (the invariant): an alias never resolves to, wakes or |
| + reaches a route of another effective account or app; legacy empty |
| + accounts; ambiguous sockets; an alias that is itself not ready. |
| +2. The wake path is unchanged: activator keying on the instance's host, |
| + one entry, the lease, the maintenance fence, generations |
| + (appSocketProxy), RetireExcept's `managed` set; no second wake path. |
| +3. Edge table side effects: Allowed/ACME (a dropped foreign alias is no |
| + longer Allowed), currentHosts and wildcard parents, homes and edges |
| + file publication, the path fold, attached hostnames to an alias, |
| + static and tunnel or fleet-placed sources, probes and the asset cache. |
| +4. Anything that reads `up.alias` or assumes `m[host].route.Host == host`. |
| +5. Tests: production-wired where they claim (internal/host/aliaswake_test.go |
| + drives a real edge over a real activator and registry), and they fail |
| + when the mechanism is removed. |
| + |
| +## Census |
| + |
| +Give a verdict for every unit and the re-pinned envelope on the card |
| +(docs/superpowers/notes/census-proposal-alias-wake-338.md), per AGENTS.md |
| +"The census": reject if the change lets root open, run, query or follow |
| +anything it did not before from a path or input a tenant, an app or a box |
| +agent can create, write or name; if it weakens a check, refusal, |
| +validation, argument or environment root relies on; if a new disposition |
| +is wrong for the unit's reads; or if the diff cannot settle any of these. |
| +Otherwise approve. Cite the lines you read. |
| + |
| +## Severity |
| + |
| +- **P1**: unsafe, would not compile, a test fails, or it would not work. |
| + Blocks merge. |
| +- **P2**: wrong or missing. Fixed without reopening this review. (The |
| + census, and review of any newly changed security, root, termination |
| + or production-storage behaviour, still check the fix; see AGENTS.md, |
| + "Stopping rules".) |
| +- **P3**: clarity or polish. Goes on a follow-up list; never a reason for |
| + another round. |
| + |
| +A P1 states its failure scenario and the evidence (file:line). Do not |
| +raise a P2 to P1 to keep the review open. |
| + |
| +## Output |
| + |
| +Census verdicts first. Then findings ranked P1, P2, P3. Each gives the |
| +section, the problem, the evidence (file:line, verified), the failure |
| +scenario, a concrete fix and the invariant or trust boundary it breaks |
| +(that is its fault family). End with exactly one verdict: |
| + |
| +- **READY**: no P1 and no P2. |
| +- **READY AFTER FIXES**: no P1. The listed P2s are fixed without another |
| + round. |
| +- **NOT READY**: one or more P1s, listed. |
| + |
| +Do not edit files. Do not spawn Anthropic-model reviewers or subagents of |
| +your own. Do not run the full test suites. |