Search code examples
elasticsearchkibanakibana-4

Kibana 4 Metric visualization show latest value


I'm new to Kibana and Elastic Search and i have run into this problem:

My ES contains (among other stuff) also data containing the current value of one custom performance counter and i would like my dashboard to show this value, e.g., as a big number - therefore i tried to use the Metric visualization, but i have no idea on how to show only the last value. Any help would be highly appreciated. Thanks.


Solution

  • We had a similar issue for our use case. We found two ways to handle it:

    1. If the data is periodically generated then you can use the Kibana feature of showing data of recent n days to see the latest data.
    2. In our case, the above option was not possible so we went with a hack where we have a property in our documents called "IsLatest" so we apply a filter "IsLatest":true in all our charts where we need latest info. We have written our code which feeds data to ElasticSearch in such a way that it updates the older data and sets it's "IsLatest" to false.

    Hope it helps