magicblock-labs / magicblock-labs/redsuite
Index pending WebSocket writes by account
- Dominant language
- Rust
- Stars
- 1
- Forks
- 0
- Avg merge
- 3h 58m
- Merged PRs (30d)
- 48
Description
## Outcome
Account notification processing scales with relevant pending writes rather than the total backlog.
## Scope
[Account notification handling](https://github.com/magicblock-labs/redsuite/blob/06c80157f8bc87c39ac48fd59367a8e9280d2db9/crates/redsuite-core/src/transport/ws.rs#L107) scans the entire pending-write map and collects superseded IDs into a temporary vector for each notification.
Replace that scan with per-account ordered pending-write tracking and drain only the relevant settled prefix. Preserve exact-observation versus supersession accounting, waiter behavior, and timing. Retain the existing connection layer established by #34.
## Acceptance criteria
- [ ] A notification does not scan unrelated accounts' pending writes.
- [ ] Exact observations and superseded writes retain distinct accounting.
- [ ] Waiters settle correctly for observed, superseded, and terminal-failure outcomes.
- [ ] Duplicate or older notifications do not double-count completion.
- [ ] Existing account-update timing semantics remain unchanged.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.