refactor(app): compose atomic frame roots

Move the complete update/render construction graph into a typed Phase-8 owner, explicitly carry the content dependencies it consumes, and publish both roots through one exact lease. Extract lifecycle resource sampling and frame-owned late bindings so partial startup and shutdown withdraw the same generation without window callbacks.

Co-authored-by: Codex <codex@openai.com>
This commit is contained in:
Erik 2026-07-22 19:02:08 +02:00
parent 826f9ea9b5
commit 3628aeb520
21 changed files with 1052 additions and 374 deletions

View file

@ -104,11 +104,11 @@ controllers, selection/radar, landblock publishers, and portal/sky/particle
resources have transactional phase ownership and exact-owner late bindings.
I.7 adds the complete streaming/session/hydration/local-player/teleport phase,
including explicit reversible ownership for every late edge. `GameWindow` is
now 2,149 raw lines after I.8a, which composes the session factory, command
targets, and sole gameplay input subscriber before frame publication. I.8bI.9,
now 1,919 raw lines after I.8b, which also composes and atomically publishes the
complete update/render pair and extracts lifecycle resource sampling. I.8cI.9,
shutdown, canonical soak snapshots, and closeout checkpoints JL remain. The
App gate passes 3,424 tests / 3 intentional skips, the complete Release suite
passes 7,796 tests / 5 skips, and the I.8a corrected-diff review is clean.
App gate passes 3,429 tests / 3 intentional skips, the complete Release suite
passes 7,801 tests / 5 skips, and the I.8b corrected-diff review is clean.
This is a behavior-preserving structural program. Severe regressions still get
root-cause fixes in separate commits; ordinary feature work resumes with M4

View file

@ -60,11 +60,13 @@ publishers, and portal/sky/particle resources have transactional phase
ownership and exact-owner late bindings. I.7 now owns the complete streaming,
session, hydration, local-player, combat, and teleport startup graph, including
named reversible late edges. I.8a adds the focused live-session runtime factory
and attaches command/input owners before frame publication. `GameWindow` is
2,149 raw lines. I.8bI.9 and checkpoints JL remain active. Issue #232 tracks
and attaches command/input owners before frame publication. I.8b composes and
atomically publishes the complete frame pair and extracts lifecycle resource
sampling. `GameWindow` is 1,919 raw lines. I.8cI.9 and checkpoints JL remain
active. Issue #232 tracks
process-residency variance in the soak without loosening its leak threshold.
The App gate passes 3,424 tests / 3 skips, the complete Release suite passes
7,796 tests / 5 skips, and the I.8a corrected-diff review is clean.
The App gate passes 3,429 tests / 3 skips, the complete Release suite passes
7,801 tests / 5 skips, and the I.8b corrected-diff review is clean.
Carried:
#153 far-teleport residual, #116 slide-response, the remaining R6 ownership cleanup plus

View file

@ -294,9 +294,11 @@ ledger only after the complete pipeline is live.
detailed session-binding, atomic-root, and terminal-start plan is
[`2026-07-22-gamewindow-slice-8-checkpoint-i8-frame-roots-session-start.md`](2026-07-22-gamewindow-slice-8-checkpoint-i8-frame-roots-session-start.md).
I.8a is complete: the session factory, command targets, and sole gameplay
input subscriber now belong to Phase 7 and publish before any frame root;
`GameWindow.cs` is 2,149 raw lines. I.8b atomic frame-root composition is the
active cut.
input subscriber now belong to Phase 7 and publish before any frame root.
I.8b composes the unchanged update/render graph in a focused phase, publishes
the pair through an exact owned slot lease, and moves lifecycle resource
sampling out of the window. `GameWindow.cs` is 1,919 raw lines. I.8c terminal
session start is the active cut.
Checkpoint I remains active until I.9 closes the complete nine-phase pipeline.
## 6. Automated acceptance

View file

@ -1,6 +1,6 @@
# GameWindow Slice 8 — Checkpoint I.8 Frame Roots and Session Start
**Status:** Active — I.8a complete; I.8b frame-root composition next
**Status:** Active — I.8aI.8b complete; I.8c terminal start next
**Parent:** `2026-07-22-gamewindow-slice-8-checkpoint-i-ordered-composition.md`
@ -81,6 +81,16 @@ Phase-7 suffix in reverse order.
## 3. I.8b — atomic frame-root composition
**Completed 2026-07-22.** `FrameRootCompositionPhase` now constructs the
unchanged render and update graphs from explicit prior-phase results and
focused runtime owners. `GameFrameGraphSlot.PublishOwned` publishes and
withdraws one exact pair. Optional lifecycle automation has a Phase-8 binding
owner, and `WorldLifecycleResourceSnapshotSource` samples the same canonical
owners without window callbacks or mirrored counters. The Phase-8 contract now
receives the Phase-2 content result explicitly because scripts and particles
are real frame dependencies; this removes a hidden reach-back through the
window shell.
Add `FrameRootCompositionPhase` implementing the existing
`IFrameRootCompositionPhase` contract. Its dependencies are focused App owners;
prior phase results supply all resources created during startup.

View file

@ -29,8 +29,8 @@ audit.
- [x] H — give terrain atlas, sky shader, retained `UiHost`, and both frame roots
explicit single ownership and transfer seams.
- [ ] I — group `OnLoad` into small ordered, fakeable composition phases with
transactional partial-acquisition rollback. I.1I.7 and I.8a are complete;
I.8b atomic frame-root publication is active. Detailed plan:
transactional partial-acquisition rollback. I.1I.8b are complete; I.8c
terminal session start is active. Detailed plan:
[`2026-07-22-gamewindow-slice-8-checkpoint-i-ordered-composition.md`](2026-07-22-gamewindow-slice-8-checkpoint-i-ordered-composition.md).
- [ ] J — move the exact retryable shutdown manifest to a focused lifetime
owner and prove all partial-load/reentrant/retry paths.