Hi
can't write data to elasticsearch vi logstash(http_poller) here is the scenario:
influxdb > logstash(http_poller) > elasticsearch
error that I get:
"status"=>400, "error"=>{"type"=>"illegal_argument_exception", "reason"=>"mapper [results.series.values] cannot be changed from type [date] to [text]"}}}
If that is the format you are trying to index you will have problems. All values in the values array need to have the same mapping. If you are using dynamic mapping the first value envountered will define the mapping type. If you have a mixed array like you do it is possible indexing the document on its own fails due to mapping conflict so that nothing gets inserted.
I believe you will need to restructure the document into something that is actually usable in Elasticsearch.
You may want to map it as keyword instead of text and that will not analyse it. If you are indexing it exactly as shown in the screenshot above I think you will have issues querying it, so I would recommend restructuring the document if that is the case so that it contains key-value pairs with the data instead of separate arrays of keys and values.
You may be able to index that document into Elasticsearch but I do not see how you will be able to use it for anything useful in that format. I would split this large document into multiple documents and transform the data arrays to neat key-value pairs. That would allow you to search and use the data in Kibana, which the current structure will not.
You may also want to assign an ID to reduce the risk of duplicates, but that depends on the data the http poller will be returning.
The event field field contains the original event string, which I think is no longer needed. The series field contains the raw arrays that have been parsed out, so is in my opinion no longer needed either. The host filed might possibly be useful, so keep that if you need it.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.