[pull] master from molvqingtai:master - #32
Merged
Conversation
Replace the single host-wide Artico peer with one scoped owner per room: a dedicated World peer and one dedicated Chat peer per active domain. Each owner carries its own fresh physical identity, single allowed room, restart owner, pending joins, and listener fence; the facade routes joins, leaves, sends, membership reads, and provider callbacks by roomId to the exact owner without coalescing identities or sharing desired-room state, restarts, or timers across scopes. RoomTransport gains peerIdOf(roomId) so Wire's PeerIdQuery becomes scope-aware: World presence uses the World peer identity, each domain Chat uses its own peer, and the Runtime snapshot's world peerId reports the World scope. Reconnecting a domain now stops and disposes the old owner before the replacement joins with a rotated physical identity while logical presence stays stable; structural controls prove distinct identities per scope, identity rotation on rejoin, restart containment to the closing owner, and settlement of scoped leave/dispose against only their exact owner. The external peer schemas, codec, namespaces, room identifiers, payloads, persistence, public ChatRoom port, and UI are unchanged. The maintained architecture diagram now shows the dedicated World peer, per-domain Chat peers, and the replacement identity rule. Verified: 80 files / 814 tests pass, tsc 0, oxfmt clean, oxlint 0 errors, Chrome MV3 and Firefox MV2 builds pass, OpenSpec strict valid.
…restart Repair the V5 review findings on the scoped-peer composition: - Initial World/Chat attempt failures now keep Runtime-owned bounded retry: the public operation settles while the domain retains the preserved typed join input and schedules a fresh generation at the same 5s cadence. - A domain release now physically leaves the Chat peer first and only then publishes the World removal; a final-site release publishes the empty sites snapshot and waits for it before the release owner closes, with the existing live continuation retrying only the remaining World step. - Provider errors carry their exact room scope, are fenced by the current owner generation and disposal state, map Chat-room failures to their domain, and can no longer leak from retired owners or across domains. - A scoped restart now retires and closes the predecessor before the successor is constructed and genuinely rebinds its room, while owner identity is retained only within close-driven same-owner repair and rotated whenever a fresh owner is created. - The deprecated host-wide RoomTransport.peerId compatibility surface is deleted from the interface, implementation, extern, and every fixture; identity queries use peerIdOf(exactRoomId) only. Verified: 79 files / 821 tests pass, tsc 0, oxfmt clean, oxlint 0 errors, Chrome MV3 and Firefox MV2 builds pass, OpenSpec strict valid.
- rotate the physical peer id on every startPeer replacement generation - keep room-to-domain authority across prepared and live-release states - queue release-fenced joins behind the single closing release and coalesce them - complete the page join when a committed local session projects after failure
- gate the projection join completion on the live reconnect/retry owner - keep one live release owner: settled cleanup is never replayed by late leases - settle a final-removal World publication as release facts only, then accept a staged cross-domain join from a follow-up snapshot containing its own site
- track release cleanup as pending/failed/settled: a late lease never re-issues a pending write and only an observed failure retries it - roll back the World projection when the last deferred staged owner aborts: settle joined=false, empty presences, and no recovery
Ordinary same-domain attempt supersession aborts the predecessor's staged World registration while the same physical World owner stays joined; only the intentional physical World leave settles joined/presences/recovery truth.
An unrelated domain's provisional Chat failure must never leave the shared World room while another domain's live release continuation and pending final publication still own it: gate the physical departure on WorldDemandQuery instead of the Session/attempt proxy.
…ership refactor(runtime): scope every physical peer to its single room
docs(openspec): complete per-domain peer tasks
## [2.4.8](v2.4.7...v2.4.8) (2026-08-12) ### Bug Fixes * **runtime:** align content URL eligibility ([8f8303a](8f8303a)) * **runtime:** complete per-room repair round four ([e5794da](e5794da)) * **runtime:** complete per-room repair round three ([20f466d](20f466d)) * **runtime:** complete per-room repair round two ([e080d63](e080d63)) * **runtime:** derive physical World departure from exact World demand ([a25d4c5](a25d4c5)) * **runtime:** settle release order, retry ownership, and scoped peer restart ([7b6dbd5](7b6dbd5)) * **runtime:** tie World projection clearing to physical departure ([0417202](0417202)) ### Performance Improvements * **content:** narrow excluded hosts ([53e17cb](53e17cb))
…targeting-docs-closeout
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
See Commits and Changes for more details.
Created by
pull[bot] (v2.0.0-alpha.4)
Can you help keep this open source service alive? 💖 Please sponsor : )