Skip to content

Conversation

@javanna
Copy link
Member

@javanna javanna commented Oct 20, 2020

MappingLookup currently holds and exposes a FieldNameAnalyzer. Given that it is built based on the field types and their configured field analyzers, it makes more sense to have as part of FieldTypeLookup.

As a follow-up, I plan to make FieldTypeLookup public and expose it directly to QueryShardContext, hence this change helps so that PercolateQueryBuilder no longer needs to go through MappingLookup to retrieve the index analyzer. Also I plan to remove the indexAnalyzer method from MappingLookup.

MappingLookup currently holds and exposes a FieldNameAnalyzer. Given that it is built based on the field types and their configured field analyzers, it makes more sense to have as part of FieldTypeLookup.

As a follow-up, I plan to make FieldTypeLookup public and expose it directly to QueryShardContext, hence this change helps so that PercolateQueryBuilder no longer needs to go through MappingLookup to retrieve the index analyzer. Also I plan to remove the indexAnalyzer method from MappingLookup.
@javanna javanna added :Search Foundations/Mapping Index mappings, including merging and defining field types >refactoring v8.0.0 v7.11.0 labels Oct 20, 2020
@javanna javanna requested a review from romseygeek October 20, 2020 12:25
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-search (:Search/Mapping)

@elasticmachine elasticmachine added the Team:Search Meta label for search team label Oct 20, 2020
@romseygeek
Copy link
Contributor

I think this will be made unnecessary by #63937 which removes the default index analyzer entirely

@javanna
Copy link
Member Author

javanna commented Oct 20, 2020

True, if we move index analyzer to the mappers, they no longer fit into FieldTypeLookup which is about field types.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

>refactoring :Search Foundations/Mapping Index mappings, including merging and defining field types Team:Search Meta label for search team v7.11.0 v8.0.0-alpha1

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants