LearnNewsExamplesServices
Frontmatter
id18315
titleHydrate cold dock topologies and rebind warm reloads
stateClosed
labels
enhancementaitestingarchitecturecoredashboard
assigneesneo-gpt
createdAtSep 4, 2026, 8:17 PM
updatedAtSep 5, 2026, 11:32 PM
githubUrlhttps://github.com/neomjs/neo/issues/18315
authorneo-gpt
commentsCount2
parentIssue18303
subIssues[]
subIssuesCompleted0
subIssuesTotal0
contentTrust
projected
quarantined0
signals[]
blockedBy[x] 18310 Add immutable per-group transaction history and cursor, [x] 18309 Bind transaction groups across window generations, [x] 18308 Hard-cut dock topology persistence to keyed workspace records
blocking[x] 18311 window/TearOut.mjs has been imported for months while its ~280 lines of pane-handle choreography stayed in Workspace, [x] 18316 Add Workstation multi-window undo, redo, save, and reload, [x] 18272 An N-slot topology commit restores N documents and one view: no consumer has a sibling projection to converge
closedAtSep 5, 2026, 11:32 PM

Hydrate cold dock topologies and rebind warm reloads

Closed v13.2.0/archive-v13-2-0-chunk-19 enhancementaitestingarchitecturecoredashboard
neo-gpt
neo-gpt commented on Sep 4, 2026, 8:17 PM

Context

Undo history and reload persistence have different lifetimes. Warm F5 happens while the SharedWorker Group survives and should rebind without replay. Cold boot starts a new Group, hydrates one durable topology snapshot, and has empty history. Popup creation is user-activation gated and restore must not depend on permission.

The Problem

Current consumers persist partial live-layout state per window and identify additional documents positionally. Reload can leave two live root Workspaces, bind the popup to the orphan, or require popup permission before semantic restore exists. Cold selection among multiple saved roots is implicit.

The Architectural Reality

A Group topology library owns keyed Workspace documents, placement hints, active layout identity, and fingerprint. It is distinct from the single-Workspace PerspectiveLibrary and from session history. TopologyLibrary-class persistence belongs beside the existing dock persistence siblings; warm rebind belongs to the Group carrier, cold materialization to the root controller.

The Fix

Persist/select keyed topology snapshots; define cold active-layout selection; create a new Group with empty history; hydrate all semantic participants before presentation; open popup slots only behind user activation; preserve headless participants and fallback affordances on refusal. Warm reload claims the surviving (groupId, workspaceKey) and moves the same Workspace/panes into the new document without a write or popup recreation. Retire a zero-binding Group only after durable persistence and a bounded reconnect lease.

Structural Placement

A new topology persistence class matches src/dashboard/dock/persistence/PerspectiveLibrary.mjs; sibling-file-lift applies in that directory. Generic lease/binding logic stays in the Group.

Contract Ledger

Target Surface Source of Authority Proposed Behavior Fallback Docs Evidence
topology library keyed topology schema leaf named/active snapshots per logical root fail closed on unknown schema guide/JSDoc round-trip collection arms
warm reload D#18224 criterion 13 rebind same Group/Workspace/history, no write duplicate live binder forks JSDoc F5 identity/cursor arm
cold boot D#18224 criterion 13 new Group, one selected snapshot, empty history explicit selection/new blank topology guide two-saved-root selection arm
popup materialization browser activation boundary semantic hydrate first; user-activated windows second headless participants + open-as-window/fallback guide blocked-popup control
retirement lease bounded connect-window precedent retire only after durable snapshot and zero references headless-dirty + retry on persistence failure JSDoc lease/late-connect/failure arms

Decision Record impact

Implements amended ADR 0029 topology persistence and lifecycle.

Decision Record

Required prerequisite: the hard-cut ADR/wire leaf.

Discussion Criteria Mapping

Owns criterion 4 and the hydrate/materialization/retirement half of criterion 13.

Acceptance Criteria

  • Cold boot with two saved roots requires deterministic active/selected topology input; it never picks by registration order.
  • Cold hydrate creates one new Group, materializes every semantic Workspace from keyed records, and starts with empty history.
  • Warm F5 preserves Group, Workspace/pane identities, cursor, and history; it opens no replacement popup and records no transaction.
  • Popup refusal leaves the full semantic topology headless and exposes a user-activation recovery affordance; restore success never depends on popup permission.
  • A stale popup carrier cannot resurrect an unrelated stored topology.
  • Close-all clears the session carrier; a zero-binding Group retires only after durable persistence, no retained reference, and bounded lease expiry.
  • Persistence failure leaves a visible headless-dirty Group and retries rather than discarding the only truth.
  • The consumer-level restore arm saves a multi-window composition, cold reloads it, and proves the same keyed composition without history replay.

Out of Scope

Projection of sibling views, undo command routing, or cross-application Group bridging.

Avoided Traps

No replay-on-boot; no popup-first hydrate; no implicit only-snapshot choice; no unbounded lease; no lossy retirement; no per-window localStorage authority.

Related

Part of #18303. Blocked by the hard-cut and Group identity leaves. Enables #18272 and the Workstation journey.

Origin Session ID: 01a06b6d-3323-7fa0-a10b-bbc4871c8780

Retrieval Hint: D18224 warm F5 rebind cold topology hydrate popup activation headless dirty

Creation freshness: live latest-open and all-status A2A sweeps found no equivalent hydrate/rebind leaf; #18272 owns projection after adoption.

tobiu cross-referenced by PR #18374 on Sep 5, 2026, 8:48 PM