Repository navigation
[core] Fix FAST scalar matches with multiple index types on one column - #11250
Closed
JingsongLi wants to merge 5 commits into
Closed
JingsongLi wants to merge 5 commits into
JingsongLi wants to merge 5 commits into
Conversation
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.
Purpose
Fix scalar equality lookups on a Data Evolution column with both a B-tree and a full-text index. A full-text reader can decline equality. Previously its presence could cause a fast lookup to fall back to scanning rows the B-tree had not matched.
Fast mode uses the matches returned by readers that handle the predicate. Full and detail modes additionally read source rows only in ranges those readers did not cover. A successful lookup with zero matches still covers its range.
The eager scan uses the existing evaluation that reports per-reader coverage. A deferred split remembers when several index types were available for a predicate, even if only one overlaps that split. Index lookups stay on the reader when configured.
A separate Flink build change removes a misleading row-count warning. A writer that processes three rows can emit files with two and one rows. The builder was comparing the first file's count with all three input rows. It continues to log the total input and number of output files. The manifest records each file's own count.
Tests
A regression checks candidate row-ID ranges before residual filtering. It covers eager scans, combined and separate reader splits after serialization, partial and complete B-tree coverage, and a lookup with zero matches. All three configurations failed on master before the fix. A separate two-file test checks the individual manifest counts. All 240 focused core and Flink tests passed.
The scalar search-mode contract is documented in the global index guide and in the repository's AGENTS.md. This is the prerequisite for #11238.