简体   繁体   中英

Grafana connection with elasticsearch

I have successfully create a connection between Grafana and Elasticsearch. I have already indexed data into Elasticsearch , but Grafana doesn't want to show it as a "Singlestat".

Elasticsearch Data Picture

Grafana Settings Picture

So the value is "104". But why Grafana does not show this?

If you would like to show the current value in SigleStat panel you should do it in the following way:

  1. In Elastic end - Save it as int, as in SigleStat panel you can show only integers fields.

  2. In Grafana end - a. Add "ecommerce" index as data source (located in top left menu - data sources).

    b. In SigleStat panel - "Metrics" tab - choose "ecommerce" data source.

    c. In the query line: write the following "_type:supporttickets".

    d. In Metric field - choose "Max" and "value" (if value is not int you will not see it in dropdown).

    e. In SigleStat panel - "Options" tab - in "Stat" dropdown choose "current". More options like colors by thresholds and stuff - http://docs.grafana.org/features/panels/singlestat/

Metric -> sum -> is looking for Numeric value but it is getting a string("104").

  • Insert the values of "@value" column as Integer in Elasticsearch

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM