Phase 3 — Bring non-PIT onto the new foundation (Task 13 of 17)
Goal: Keep the optimization entirely within the existing per-instance callback pair, without cross-instance coordination.
Design doc: docs/shard-serialization.md — Technical Roadmap
Dependencies
Description
Add per-snapshot-instance state that lets `OnDbChange` record a suppression decision (SkipBoth) for mutations whose effects will be covered by future traversal, and lets the same instance's `ConsumeJournalChange` consult and clear that state.
Guidelines
Architecture
- Each `SliceSnapshot` (or `RestoreStreamer`) instance has its own `OnDbChange` and `ConsumeJournalChange`.
- The suppression decision is instance-local: multiple snapshots on the same shard make independent decisions based on their own `snapshot_version_` and traversal progress.
- No shard-wide or cross-instance aggregation.
Suppression state
- Add a set/map to `SliceSnapshot` that records suppressed mutations (keyed by LSN or key name).
- `OnDbChange` adds entries when SkipBoth conditions are met (conditions defined in task 14).
- `ConsumeJournalChange` checks the set: if the mutation is suppressed, skip the journal write and clear the entry.
Scope
- This task adds the mechanism only — the suppression set and the check/clear logic.
- The actual eligibility logic (when to set SkipBoth) comes in task 14.
- Initially the set remains empty (no mutations are suppressed yet).
Acceptance criteria
Phase 3 — Bring non-PIT onto the new foundation (Task 13 of 17)
Goal: Keep the optimization entirely within the existing per-instance callback pair, without cross-instance coordination.
Design doc: docs/shard-serialization.md — Technical Roadmap
Dependencies
Description
Add per-snapshot-instance state that lets `OnDbChange` record a suppression decision (SkipBoth) for mutations whose effects will be covered by future traversal, and lets the same instance's `ConsumeJournalChange` consult and clear that state.
Guidelines
Architecture
Suppression state
Scope
Acceptance criteria