I am using krakend-ce 1.4 and influx 1.X I have configured grafana dashboard and hoping to see dashboard panels for all the layers. There are 4 layers as per dashboard.
I see router panels data is getting charted as expected. But for other panels I see empty charts. "No Data to show"
my configuration for krakend-metrics and influx modules is as follows:
"github_com/devopsfaith/krakend-metrics": {
"collection_time": "30s",
"proxy_disabled": false,
"router_disabled": false,
"backend_disabled": false,
"endpoint_disabled": false,
"listen_address": "127.0.0.1:8090"
},
"github_com/letgoapp/krakend-influx":{
"address":"http://influxdb-service:80",
"ttl":"25s",
"buffer_size":0,
"db": "krakend",
"username": "admin",
"password": "adminadmin"
}
I also added opencensus as follows:
"github_com/devopsfaith/krakend-opencensus": {
"sample_rate": 100,
"reporting_period": 1,
"enabled_layers": {
"backend": true,
"router": true,
"pipe": true
},
"influxdb": {
"address": "http://influxdb-service:80",
"db": "krakend",
"timeout": "1s",
"username": "admin",
"password": "adminadmin"
}
}
I thought may be my data is not ending up in influxDB, so I went in and checked what does it have. show measurements
give me following output, and all measurements does have some data.
I am using grafana dashboard ID 5722. which is specified in docs.
how can I change my setup so that panels for proxy, backend and system shows charts?
__________________________
UPDATE
15029
per krakend 2.1.2 documentation.I still do not see other layer charts getting populated.
PS: I have checked what metrics are getting exposed on http://krakend-host:8090/__stats
I see layer.backend and layer.pipe metrics.
__________________________
UPDATE 2
I was also checking for other available dashboards which can work. I stumbled upon this one https://github.com/letgoapp/krakend-influx/blob/master/examples/grafana-dashboard.json
I see 2 more panels showing up. but not all of them.
After hours of debugging, I finally found the solution. Key here to note is If your configurations are correct, you should see data showing up in influxDB. First, make sure that you see data in influxDB. In my case, this was correct.
Like I mentioned in the second update to the question, I see some more panels getting populated when I used the dashboard from https://github.com/letgoapp/krakend-influx/blob/master/examples/grafana-dashboard.json
This was a huge lead. Later I went on to compare the specific JSON blocks within the working dashboard and the one which was missing some charts. I realized all of those panels had "datasource": null
. And the ones which were working had the "datasource": "InfluxDB",
I updated the JSON definition of dashboard and viola !! All the panels started showing the charts.
PS: If you see any datasource as null, or which does not correspond to your influx DB datasource, you should update it to use influx db data source which is defined in the datasources
section on the admin panel.