elasticsearch/x-pack/plugin/ccr
Alan Woodward 385b97f92b
Choose postings format from FieldMapper instead of MappedFieldType (#77234)
Currently we configure per-field postings formats by asking the MapperService
for the MappedFieldType of the field in question, and then checking to see if it
is a completion field. If no MappedFieldType is available, we emit a warning.
However, MappedFieldTypes are for search fields only, and so we end up emitting
warnings for hidden sub-fields that have no corresponding field type, such as
prefix or phrase accelerator fields on text mappers.

This commit reworks things so that the MappingLookup is responsible for defining
per-field postings formats, and will detect CompletionFieldMappers at build time.
All fields that are not mapped to a completion field will just get the default postings
format. This also means that we no longer need a logger instance on CodecService.

Fixes #77183
2021-09-03 14:54:43 +01:00
..
qa Introduce simple public yaml-rest-test plugin (#76554) 2021-08-31 08:45:52 +02:00
src Choose postings format from FieldMapper instead of MappedFieldType (#77234) 2021-09-03 14:54:43 +01:00
build.gradle Add precommit task for detecting split packages (#73784) 2021-06-08 15:04:23 -07:00