Merge "Update sharding based on data-nodes"

This commit is contained in:
Zuul 2018-07-24 02:51:36 +00:00 committed by Gerrit Code Review
commit 82182589f0

View File

@ -1,4 +1,4 @@
{% set shards = ((groups["elastic-logstash"] | length) * 3) | int %}
{% set shards = ((data_nodes | length) * 3) | int %}
# Elasticsearch template settings
setup.template.settings:
@ -10,9 +10,9 @@ setup.template.settings:
number_of_shards: {{ shards }}
codec: best_compression
# This provides for an index split of up to 2 times the number of available shards
number_of_routing_shards: {{ (shards | int) * 2 * (groups["elastic-logstash"] | length) }}
number_of_routing_shards: {{ (shards | int) * 2 }}
# A dictionary of settings for the _source field. For more details, please check
# https://www.elastic.co/guide/en/elasticsearch/reference/current/mapping-source-field.html
#_source:
#enabled: false
_source:
enabled: true