Hi,
I am still struggeling.
I have a new index for each type but I get the following error:
14:20:21.483 [Ruby-0-Thread-40@[main]>worker0: /usr/share/logstash/logstash-core/lib/logstash/pipeline.rb:392] WARN logstash.outputs.elasticsearch - Could not index event to Elasticsearch. {:status=>400, :action=>["index", {:_id=>nil, :_index=>"events-state-2017.12.19", :_type=>"doc", :_routing=>nil}, #LogStash::Event:0x7b701c76], :response=>{"index"=>{"_index"=>"events-state-2017.12.19", "_type"=>"doc", "_id"=>"8mclb2ABzTth-5wZkhFh", "status"=>400, "error"=>{"type"=>"illegal_argument_exception", "reason"=>"Rejecting mapping update to [events-state-2017.12.19] as the final mapping would have more than 1 type: [doc, state]"}}}}
Then I found this:
https://discuss.elastic.co/t/rejecting-mapping-update-for-new-index/109576
Does it mean that I should not use templates at all in ES6?
(I though templates are required to get correct types)
I have the following template for state.
{ "template": "events-state-*", "id": "events-state-*", "type": "index-pattern", "version": 1, "mappings": { "state": { "dynamic_templates": [
.
.
.
Can you explain how the template should be written?
Kind regards
Mathias