In order to properly scale history data in elasticsearch, we should use multiple indices per type, and the common way to split them is by date.
With only one index, we can't dynamically add shards as index grows (a reindex is needed otherwise), we can't store fresh data in hot nodes and move old ones to cold nodes, etc..
IMO there are two ways to achieve date based indices setup :
- let zabbix server put data directly in the good index (automatically created through adequate template, by ES)
Example (with by-day splitting) :
Frontend would have to search in every indices
- Let Elasticsearch put data in appropriate index, using "Date Index Name Processor Pipeline" (https://www.elastic.co/guide/en/elasticsearch/reference/6.1/date-index-name-processor.html) :
No changes needed in Frontend