Repository navigation
SOLR-18608: Honor glob field selection in real-time get and lazy document prefetch - #5298
Draft
nick-boss-tech wants to merge 4 commits into
Draft
nick-boss-tech wants to merge 4 commits into
nick-boss-tech wants to merge 4 commits into
Conversation
…d from the PR 5188 follow-up branch)
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.
🤖 AI text below 🤖 (reviewed by Nick Shanin)
Draft status is due to Nick Shanin's open-PR cap; the change is complete and ready for review.
Jira: SOLR-18608. Follow-up to SOLR-11364 / PR 5188, now merged.
What happens today
Partial field globs can load unrelated stored values in real-time get and skip lazy prefetch in search.
An index-backed
/getwithfl=title,other_*falls back to loading all stored fields. A/selectwithfl=source_*skips prefetch, including the stored-field combination needed for highlighting.What this change does
Share stored-field selection while preserving the DocValues-only search path.
RTG uses the shared selector for matching stored fields and transformer inputs, then filters cached fields before conversion. Glob prefetch applies the response optimizer's DocValues substitution, adds highlight fields and the unique key, and skips an empty stored set. Explicit-field prefetch and the shard/50-result guards retain their previous behavior.
Proof
Linux tests and checks pass at the current head.
Linux verification at a99e402
Verified 2026-11-05 with JDK 21, Gradle 9.7.0 and seed
5298C0DE:BasicFunctionalityTest: 31 passed.TestPseudoReturnFields: 35 passed.TestUnifiedSolrHighlighter: 33 passed.ReturnFieldsTest: 16 passed.TestRetrieveFieldsOptimizer: 1 passed.LargeFieldTest: 1 passed.The six suites total 117 tests with no failures, errors or skips. Nine focused methods and an independent
LargeFieldTestrun also passed. Roottidy, Error Prone compilation and rootcheck -x testpassed; formatting left the tested head unchanged.With the final tests overlaid on
7ee68a7000,testGlobNonStoredDocValuesPrefetch,testGlobSubstitutedDocValuesPrefetchandtestGlobEmptyPrefetcheach fail at the intendedUnexpected stored-document prefetchassertion. All pass at this head.Test results and root tidy result.
Limits
The change covers stored-field loading and prefetch.
RTG DocValues decoration and term-vector selection are unchanged. No full core test suite, repository-wide test run, disk-I/O measurement or latency benchmark was performed. Lazy-wrapper assertions do not establish which backing values Lucene reads on cache hits.
Changelog: SOLR-18608
AI-generated description. Nick Shanin directed the work and takes responsibility for this contribution.