forked from opensearch-project/OpenSearch
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
1. Use Lucene's KeywordField instead of custom Field type. 2. Use IndexOrDocValuesQuery for all MultiTermQueries. Signed-off-by: Michael Froh <froh@amazon.com>
- Loading branch information
Showing
5 changed files
with
85 additions
and
28 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
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
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
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
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
abaa86f
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.
@msfroh I had a couple of questions regarding your implementation. While I'm going to ignore the changes made to
FlatObjectField
for now, I see that you're settingdoc_values
to be true always for the keyword field. I see in the docs that it is an optional field that defaults tofalse
. Keyword does support both index and doc right?I understand that you're overriding the various query methods in the mapper, but in the base class I also see other query methods that could be overridden as well -- https://github.com/opensearch-project/OpenSearch/blob/main/server/src/main/java/org/opensearch/index/mapper/MappedFieldType.java#L221-L372
Do you think we'd need to override all of them to use the index vs doc functionality?
abaa86f
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.
Right the current gaps are:
IndexOrDocValues
query as I did in this commit. That's the "You know what, Lucene, you decide (per-segment) how to run this query".MultiTermQuery
.