Hi, I would like to automatically create a url and pass to my users so they could see the results of the query from Kibana.
The query needs to contains something similar to this:
{
"query": {
"match": {
"kubernetes.pod_name.keyword": {
"query": "my_pod_name",
"type": "phrase"
}
}
}
}
"my_pod_name" is dynamically created.
I've tried to create a filter but the url looks nothing like the query and contains guids and auto generated values which I do not understand how I can get them.
Is it a simple get command or should it be a post command?
Unfortunately, there isn't a great to accomplish this now as our URL's are RISON encoded, which is not friendly. There is work being done that will improve this in the future, though.
You're best bet is to create a filter on Discover which includes the Pod Name, and replace that value with your dynamic one.
For example: http://localhost:5601/app/kibana#/discover?_g=(refreshInterval:(pause:!t,value:0),time:(from:now-7d,mode:quick,to:now))&_a=(columns:!(_source),filters:!(('$state':(store:appState),meta:(alias:!n,disabled:!f,index:d3d7af60-4c81-11e8-b3d7-01146121b73d,key:Carrier,negate:!f,params:(query:JetBeats,type:phrase),type:phrase,value:JetBeats),query:(match:(Carrier:(query:JetBeats,type:phrase))))),index:d3d7af60-4c81-11e8-b3d7-01146121b73d,interval:auto,query:(language:lucene,query:''),sort:!(timestamp,desc))
This is a filter on Carrier: JetBeats. If I want to create a URL to show me results of a specific carrier, I would just need to make that value dynamic.
I've created such filter, shared it. Copied the link from the saved dashboard then changed the name of the pod to a different one (3 places).
Copied the link and paste it to a browser.
What I got is a kibana page with the two different pods as a filter... which is not what I wanted...
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.