-
Notifications
You must be signed in to change notification settings - Fork 24.9k
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
Search performance - better caching logic for queries on wildcard field #76035
Conversation
Pinging @elastic/es-search (Team:Search) |
a6d6c41
to
36d7a5b
Compare
...src/main/java/org/elasticsearch/xpack/wildcard/mapper/ApproximationAndVerificationQuery.java
Outdated
Show resolved
Hide resolved
...src/main/java/org/elasticsearch/xpack/wildcard/mapper/ApproximationAndVerificationQuery.java
Outdated
Show resolved
Hide resolved
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.
This looks good to me! I left some very minor comments.
...d/src/main/java/org/elasticsearch/xpack/wildcard/mapper/BinaryDvConfirmedAutomatonQuery.java
Outdated
Show resolved
Hide resolved
...d/src/main/java/org/elasticsearch/xpack/wildcard/mapper/BinaryDvConfirmedAutomatonQuery.java
Show resolved
Hide resolved
...ugin/wildcard/src/main/java/org/elasticsearch/xpack/wildcard/mapper/WildcardFieldMapper.java
Outdated
Show resolved
Hide resolved
…nning contained verification query clauses across whole index at great expense. The new ApproximationAndVerificationQuery provides a replacement wrapper that plays better with caching logic Closes elastic#75848
…Query which contains both the approximation (ngram index) query for acceleration and the automaton DV query.
// Bug if we have an indexed value but no doc value. | ||
assert false; | ||
// Bug if we have an indexed value (i.e an approxQuery) but no doc value. | ||
assert approxQuery instanceof MatchAllDocsQuery == false; |
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.
Can you explain why this assertion changed? The original version seemed correct to me.
…ld (elastic#76035) Remove use of BooleanQuery to prevent query caching framework from running contained verification query clauses across whole index at great expense. The new BinaryDVConfirmedAutomatonQuery provides a replacement wrapper that plays better with caching logic Closes elastic#75848
…ld (#76035) (#76182) Backport to remove use of BooleanQuery to prevent query caching framework from running contained verification query clauses across whole index at great expense. The new BinaryDVConfirmedAutomatonQuery provides a replacement wrapper that plays better with caching logic Closes #75848
Remove use of BooleanQuery in WildcardField regex/wildcard/fuzzy/prefix searches to prevent query caching framework from running the contained verification query clauses across whole index at great expense.
The new BinaryDvConfirmedAutomatonQuery provides a replacement wrapper for the approximation and verification clauses that plays better with caching logic
Closes #75848