New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Special case the _index
field in queries
#12027
Closed
Closed
Conversation
This file contains 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
…allows queries to test the name of the index. Adding this capability means we can deprecate the specialist indices query. IndexFieldMapper is changed to make the term query factories produce match_all or match_none queries based on tests on the index name. Closes #3316
markharwood
added
v2.0.0-beta1
review
:Search/Search
Search-related issues that do not fall into other categories
labels
Jul 3, 2015
clintongormley
added
:Query DSL
and removed
:Search/Search
Search-related issues that do not fall into other categories
labels
Jul 5, 2015
clintongormley
changed the title
Search enhancement: adds a special case for the “_index” field
Special case the Jul 5, 2015
_index
field in queries
LGTM! |
Pushed to master f95981b |
|
||
/** | ||
* This termQuery impl looks at the context to determine the index that | ||
* is being queried and then returns a MATCH_ALL_QUERY or MATCH_NO_QUERY |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
MATCH_NO_DOCS_QUERY?
@markharwood Should it be closed since it was pushed? |
rjernst
added a commit
to rjernst/elasticsearch
that referenced
this pull request
Jul 21, 2015
The `_index` field is now a completely virtual field thanks to elastic#12027. It is no longer necessary to index the actual value of the index name. closes elastic#12329
clintongormley
added
:Search/Search
Search-related issues that do not fall into other categories
and removed
:Query DSL
labels
Feb 14, 2018
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
>enhancement
:Search/Search
Search-related issues that do not fall into other categories
v2.0.0-beta1
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 change allows queries to test the name of the index by referring to the _index field in query clauses. Adding this capability means we can deprecate the specialist indices query.
IndexFieldMapper is changed to make the term(s) query factory methods instead produce match_all or match_none queries based on tests of the index name.
Closes #3316