I asked same question to elasticsearch community, but there is no reply.
This topic is related to both Kibana and Elasticsearch
So I'm asking same question here.
I had created visualization by using elasticsearch REST API.
In elk 2.x version, this method worked fine.
However, after I updated my elk to 6.2.1, there are some problems.
I created visualization using REST API like this.
curl -X PUT --data @[visualization_id].json 'http://localhost:9200/.kibana/visualization/[visualization_id]'
Everytthing was fine.. life was so happy.
However, in Version 6.x
If u try same method, u will get error message. It's about type, elasticsearch has only one type, doc.
Previously u created visualization with type 'visualization'
So, I changed url little bit..
curl -X PUT --data @[visualization_id].json 'http://localhost:9200/.kibana/doc/[visualization_id]' -H 'Content-Type: application/json'
I successfully created visualization, and also check created visualization list in kibana.
However.., when i click the visualization I created using REST API
Kibana says "Could not locate that visualization (id: ...)"
When u use GUI to create visualization, Kibana makes id like 'visualization:xxxx-xxxx-xxxx-xxxx'.
Does anyone know how to solve this problem?
Thanks in advance.