-
Notifications
You must be signed in to change notification settings - Fork 24.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix parsing of file based template loading
We support three different settings in templates * "settings" : { "index" : { "number_of_shards" : 12 } } * "settings" : { "index.number_of_shards" : 12 } * "settings" : { "number_of_shards" : 12 } The latter one was not supported by the fix in #4235 This commit fixes this issue and uses randomized testing to test any of the three cases above when running integration tests. Closes #4411
- Loading branch information
Showing
5 changed files
with
28 additions
and
3 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
File renamed without changes.
7 changes: 7 additions & 0 deletions
7
src/test/java/org/elasticsearch/indices/template/template1.json
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"template" : "foo*", | ||
"settings" : { | ||
"number_of_shards": 10, | ||
"number_of_replicas": 0 | ||
} | ||
} |
9 changes: 9 additions & 0 deletions
9
src/test/java/org/elasticsearch/indices/template/template2.json
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"template" : "foo*", | ||
"settings" : { | ||
"index" : { | ||
"number_of_shards": 10, | ||
"number_of_replicas": 0 | ||
} | ||
} | ||
} |