Move resolve views to IndexAbstractionOptions#143741
Merged
elasticsearchmachine merged 6 commits intoelastic:mainfrom Mar 11, 2026
Merged
Move resolve views to IndexAbstractionOptions#143741elasticsearchmachine merged 6 commits intoelastic:mainfrom
elasticsearchmachine merged 6 commits intoelastic:mainfrom
Conversation
56927ce to
1a9b7c9
Compare
idegtiarenko
approved these changes
Mar 9, 2026
1a9b7c9 to
c699c49
Compare
Collaborator
|
Pinging @elastic/es-security (Team:Security) |
9cbb77c to
06d665d
Compare
06d665d to
c2f1139
Compare
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.
There has been several discussions on this topic since I opened #141050 and @idegtiarenko also mentioned this in #143561 (comment).
The issue is that both
resolveViewsandresolveAliasesare inWildcardOptionsbut are used when resolving both concrete index pattern targets and wildcard targets. This PR movesresolveViewsfromIndicesOptions.WildcardOptionsinto a newIndicesOptions.IndexAbstractionOptionsrecord to address this confusing inconsistency.This is in preparation for sending
resolveViewsas a parameter to field caps for remote view resolving where more work will be done to serializeresolveViewsand not having this in place would make for confusing code. See #143384 for more information on the upcoming serialization ofresolveViews.Note:
resolveAliasesis moved in a follow up PR since it's decoupled from the resolveViews changes. #143953Note:
IndicesRequest.includeDataStreams()is the same type of flag asresolveAliasesandresolveViews, it controls whether data streams participate in index resolution. It's a candidate forIndexAbstractionOptionsbut currently lives onIndicesRequest(notIndicesOptions) and is threaded separately throughIndexNameExpressionResolver.Contextas a constructor parameter. Moving it would touch 60+ files and change theIndicesRequestinterface. Because of how big that change would be, I have not considered doing that in this PR (or at all).