forked from elastic/elasticsearch
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove the
lowercase_expanded_terms
and locale
options from `(sim…
…ple_)query_string`. This pull request uses the `MultiTermAwareComponent` interface in order to figure out how to deal with queries that match partial strings. This provides a better out-of-the-box experience and allows to remove the `lowercase_expanded_terms` and `locale` (which was only used for lowercasing) options. Things are expected to work well for custom analyzers. However, built-in analyzers make it challenging to know which components should be kept for multi-term analysis. The way it is implemented today is thet there is a default implementation that returns a lowercasing analyzer, which should be fine for most language analyzers for european languages. I did not want to go crazy with configuring the correct multi-term analyzer for those until we have a way to test that we are sync'ed with what happens in Lucene like we do for testing which factories need to implement `MultiTermAwareComponent`. In the future we could consider removing `analyze_wildcards` as well, but the query parser currently has the ability to tokenize it and generate a term query for the n-1 first tokens and a wildcard query on the last token. I suspect some users are relying on this behaviour so I think this should be explored in a separate change. Closes elastic#9978
- Loading branch information
Showing
107 changed files
with
1,134 additions
and
684 deletions.
There are no files selected for viewing
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
Oops, something went wrong.