Skip to content

[core] Preserve deletion vectors when regrouping sorted index splits - #11522

Open
JustinBinber wants to merge 2 commits into
apache:masterfrom
JustinBinber:codex/de-sorted-index-preserve-dv
Open

JustinBinber wants to merge 2 commits into
apache:masterfrom
JustinBinber:codex/de-sorted-index-preserve-dv

Conversation

@JustinBinber

Copy link
Copy Markdown
Contributor

Purpose

Fixes #11520.

The sorted global-index builder repacks Data Evolution files into disjoint contiguous RowID splits. Preserve the deletion-file slot associated with each data file when building the new split, including after the files are reordered. Keep the existing range boundaries, writer and refresh behavior.

Tests

The tests-only base at 8b641ae1f3 failed both Flink B-tree and Bitmap cases by indexing deleted rows. The candidate was verified with Core split and scanner tests, Flink B-tree/Bitmap build and refresh cases, and Spark indexed queries and refresh cases.

In an earlier alternating A/B single-host Spark 3.5.9 comparison with independent copies of the same snapshot, 135,000 of 150,000 physical rows were deleted. Index entries changed from 150,000 to 15,000, files from 16 to 4, and shuffle write from 1,249,729 to 126,130 bytes. Range query results matched all 15,000 live IDs in every run. That fixture does not establish a production point-query latency change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] Sorted Data Evolution index builds include deleted rows after split regrouping

1 participant