feat(data_plane): retire DualWriteSink; precompute writes go to SketchIndex only - #160
Merged
Merged
Conversation
…hIndex only Phase 5 M2.3.6a — first step of the SketchStore retirement. The production OutputSink is now `SketchIndexSink` (renamed and slimmed-down successor to `DualWriteSink` from PR #156); it writes ONLY to `SketchIndex` via `append_precompute`. The legacy `SketchStore` agg_id-keyed write path is gone from `main.rs`. Reads have already migrated to `SketchIndex` in PR #159 (M2.3.5b), so the legacy store no longer participates in either side of the ingest / query loop. The `Store` trait, `store/{global,per_key, common}.rs`, and the eviction service still exist; subsequent M2.3.6 sub-PRs delete them and rename `SketchIndex → SketchStore`. Test fixtures and the schema eviction service kept their existing `Store` plumbing untouched (so this PR's blast radius stays contained). 804/806 lib tests pass — the 2 pre-existing `schema_timeline_dispatch` failures predate this change. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2 tasks
zzylol
added a commit
that referenced
this pull request
May 13, 2026
Phase 5 M2.3.6c — adds `SketchIndex::start_persistence` and `SketchIndexPersistence` (the live persistence harness — manifest + part cache + flusher handle), and constructs one in `main.rs` when `--persistence-enabled` is passed. The new persistence layer writes to `<disk_path>/sketch_index/`, a subdir distinct from the legacy `SketchStore` layout — keeps the two coexisting until the legacy can be deleted in subsequent sub-PRs. The flusher loop is unchanged — it's generic over `EpochSource` (PR #162's `SketchIndex` impl drives the new path; the legacy `SketchStorePerKey` impl drives the deprecated one which now sees no writes after M2.3.6a / PR #160). Read-back from disk on query is NOT in scope here — the in-memory `query_range` / `query_precomputes_by_agg` paths don't yet consult `PartCache`. That's a follow-up: subsequent M2.3.6 sub-PRs add the disk-read glue (the legacy `SketchStorePerKey` similarly stubbed this; see `source.rs:35`'s "Ok(None) until then" comment). Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
Phase 5 M2.3.6a — first step of the
SketchStoreretirement. The productionOutputSinkis nowSketchIndexSink(renamed + slimmed successor toDualWriteSinkfrom PR #156); it writes ONLY toSketchIndexviaappend_precompute.Reads migrated to
SketchIndexin PR #159 (M2.3.5b), so the legacySketchStoreno longer participates in either ingest or query. TheStoretrait,store/{global,per_key,common}.rs, and the eviction service still exist; subsequent M2.3.6 sub-PRs delete them and renameSketchIndex→SketchStore.Test plan
cargo build --bin data_planeclean.cargo test -p data_plane --lib— 804/806 (2 pre-existingschema_timeline_dispatchfailures unrelated).cargo check --workspaceclean.What's next
store/{global,per_key,common}.rs, theStoretrait,StoreOutputSink,RawPassthroughSink, plus dependent infrastructure (SchemaEvictionService'sdrop_agg_idpath, backfill processor's store writes, persistence). High blast radius — ~90 references.SketchIndex→SketchStore(the final name).🤖 Generated with Claude Code