fix: respect the old data filter on inverted index#6216
Open
westonpace wants to merge 4 commits intolance-format:mainfrom
Open
fix: respect the old data filter on inverted index#6216westonpace wants to merge 4 commits intolance-format:mainfrom
westonpace wants to merge 4 commits intolance-format:mainfrom
Conversation
Xuanwo
reviewed
Mar 18, 2026
| #[derive(Debug, Clone)] | ||
| pub enum OldIndexDataFilter { | ||
| /// Keep old rows whose row-address fragment is in this bitmap. | ||
| /// Keeps track of which fragments are still valid and which are no longer valid. |
Collaborator
There was a problem hiding this comment.
Does this fix work for tables with stable row IDs?
Codecov Report❌ Patch coverage is 📢 Thoughts on this report? Let us know! |
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.
This is basically the same problem encountered in #5929
However, the solution there (and in other indices fixed since then) has been to prune indices during the update phase to remove old fragments. Unfortunately, FTS indices are maybe too large for this pruning to make sense (it would require a complete scan through of the old index) though I haven't verified how bad the performance would be.
This PR instead keeps track of which fragments have been invalidated. It then uses this as a block-list at search time.