Upgrading mappings which uses index_name
and path
#11079
Labels
discuss
>enhancement
:Search Foundations/Mapping
Index mappings, including merging and defining field types
Team:Search Foundations
Meta label for the Search Foundations team in Elasticsearch
In 2.0, I think we can upgrade the mapping in a way that is not perfect, but will cover most use cases and help users to upgrade without reindexing.
index_name
andpath
are used for two main purposes:copy_to
tag
points totags
We can't distinguish between these two use cases automatically, but we can handle the first use case gracefully, and the second use case is an easy change to make application side (ie just change all use of
tags
totag
in searches)A mapping that looks like this (with
path
set tojust_name
):could be rewritten to:
The mapping for the new
fullname
field can just be the same as the mapping of the first field which usesindex_name
(without theindex_name
) setting. The original field will not be indexed (or searchable).In the case where
path
is set tofull
, the same rules apply, but the new field uses the full path name, ie this:could be rewritten as:
The text was updated successfully, but these errors were encountered: