Summary
Track the follow-up work to make RxDB collection reset operations safe and predictable across multiple open POS tabs/windows.
Why
As part of the RxDB 17 / storage migration work, web will move to OPFS for performance. That migration is intentionally scoped to storage/platform changes only.
However, collection lifecycle operations like clear and refresh still need their own design for multi-tab behavior:
- one tab may remove and recreate a collection
- other tabs may still hold stale JS
RxCollection references
- local-only observables like
collections$ are not enough by themselves for cross-tab coordination
Goal
Design and implement a robust cross-tab coordination model for collection reset flows so that when one tab clears/recreates a collection, other tabs either:
- safely rebind to the new collection instance, or
- gracefully soft-reload / recover without data corruption or broken queries
Suggested investigation topics
- current use of
collection.onRemove() and other lifecycle hooks
- whether to coordinate via
BroadcastChannel, RxState, or another shared channel
- how non-originating tabs discover reset completion and reacquire fresh collection instances
- timeout / failure / retry behavior
- UX when recovery is not immediate
- whether
closeDuplicates is compatible with supported multi-tab POS usage
Acceptance criteria
- documented expected behavior for clear-and-refresh with 2+ open tabs
- explicit coordination protocol for reset lifecycle events
- recovery path for non-originating tabs
- tests or manual verification steps covering multi-tab scenarios
Summary
Track the follow-up work to make RxDB collection reset operations safe and predictable across multiple open POS tabs/windows.
Why
As part of the RxDB 17 / storage migration work, web will move to OPFS for performance. That migration is intentionally scoped to storage/platform changes only.
However, collection lifecycle operations like clear and refresh still need their own design for multi-tab behavior:
RxCollectionreferencescollections$are not enough by themselves for cross-tab coordinationGoal
Design and implement a robust cross-tab coordination model for collection reset flows so that when one tab clears/recreates a collection, other tabs either:
Suggested investigation topics
collection.onRemove()and other lifecycle hooksBroadcastChannel,RxState, or another shared channelcloseDuplicatesis compatible with supported multi-tab POS usageAcceptance criteria