forked from elastic/elasticsearch
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Disallow duplicate
dynamic_templates
names
Currently the same `dynamic_templates` name can be used more than once in the same mappings file. This most certainly is unintentional and can create issues like those reported in elastic#28988. Furthermore, when templates are matched later in `RootObjectMapper#findTemplate`, it looks like we simply pick the first matching one we see in the input array, so using the same template name twice sounds like an error prone idea anyway. This change checks for duplicate names on parsing and throws an error if we encounter the same name twice. Closes elastic#28988
- Loading branch information
Christoph Büscher
committed
Feb 3, 2020
1 parent
10b7ffa
commit 7b759fa
Showing
2 changed files
with
40 additions
and
0 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