-
Notifications
You must be signed in to change notification settings - Fork 25k
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
Match phrase queries against non-indexed fields should throw an exception #31060
Conversation
Pinging @elastic/es-search-aggs |
@@ -15,6 +15,9 @@ | |||
* The boundary specified using geohashes in the `geo_bounding_box` query | |||
now include entire geohash cell, instead of just geohash center. | |||
|
|||
* Attempts to generate multi-term phrase queries against non-indexed fields | |||
will now throw an exception |
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.
Only if you force an analyzer for all fields in the query ? This limits the scope of the breaking change so I think it's important to mention it.
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.
also maybe "non-indexed" should be "non-text" since eg. dates are conceptually indexed, just differently. Or alternatively "against fields that do not index positions"
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.
I left another comment about the docs.
@@ -15,6 +15,9 @@ | |||
* The boundary specified using geohashes in the `geo_bounding_box` query | |||
now include entire geohash cell, instead of just geohash center. | |||
|
|||
* Attempts to generate multi-term phrase queries against non-indexed fields | |||
will now throw an exception |
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.
also maybe "non-indexed" should be "non-text" since eg. dates are conceptually indexed, just differently. Or alternatively "against fields that do not index positions"
We need to handle MultiMatch queries here too, which means ignoring exceptions if |
Good catch. |
Failure above is because I changed |
* master: Match phrase queries against non-indexed fields should throw an exception (#31060) In the internal highlighter APIs, use the field type as opposed to the mapper. (#31039) [DOCS] Removes duplicated authentication pages Enable customizing REST tests blacklist (#31074) Make sure KeywordFieldMapper#clone preserves split_queries_on_whitespace. (#31049) [DOCS] Moves machine learning overview to stack-docs [ML] Add secondary sort to ML events (#31063) [Rollup] Specialize validation exception for easier management (#30339) Adapt bwc versions after backporting #31045 to 6.3 Remove usage of explicit type in docs (#29667) Share common readFrom/writeTo code in AcknowledgeResponse (#30983) Adapt bwc versions after backporting #31045 to 6.x Mute MatchPhrase*QueryBuilderTests [Docs] Fix typo in watcher conditions documentation (#30989) Remove wrong link in index phrases doc Move pipeline APIs to ingest namespace (#31027) [DOCS] Fixes accounting setting names (#30863) [DOCS] Rewords _field_names documentation (#31029) Index phrases (#30450) Remove leftover debugging from PTCMDT Fix PTCMDT#testMinVersionSerialization Make Persistent Tasks implementations version and feature aware (#31045)
I'll open a separate PR against 6.x to issue a deprecation warning instead of throwing an exception.