-
Notifications
You must be signed in to change notification settings - Fork 25.6k
Description
We have a number of field mappers that allow users to set a null_value, for use when a document
does not contain a value for that particular field. In general, the default for this value is null, meaning
don't do anything, but we do not allow null to be set explicitly as this value.
When we serialize a field mapper, we allow users to ask for the default values to be emitted even if they
have not been set. For null_values, this yields a quandary: if we emit the value null, then the serialized
mapping cannot be used in a subsequent put mapping request, because null is not accepted as a
valid value; but if we don't emit anything, then it looks as though we're missing a field even though the
user has asked for all configuration values. #57666 added tests to check serialization and deserialization,
and stopped null values being emitted, but it's not clear what the right choice is.