Visualize Prometheus Metrics From Metricbeats

Hi,

We are evaluating migrating from Grafana to Kibana, we have metricbeats sending prometheus data to be Elastic to be indexed. I am having trouble creating a visualization on a pre-aggregated count field. Below is a data example:

timestamp       count  state
15:47:38.503	###	    A
15:47:38.503	###	    B
15:47:38.503	###	    C
15:47:28.503	###	    A
15:47:28.503	###	    B
15:47:28.503	###	    C

So the count field is the number of records in that state. Data is reported every 10 seconds. So I am trying to create a Line graph for each state over time. I am not able to create buckets such that the Y axis is using the field value instead of the number of documents over the 30 seconds Timestamp histogram.

You can use a sum aggregation that in your use case will just use count value if you use a date histogram with a 10 seconds interval, or it will sum up all the counts correctly (supposing that the count isn't an incremental counter)

Marco,

Thanks for response, but I guess I am still doing something wrong. See the chart generated:

For reference, I am expecting 1.5K delayed, and looking for one instance of each state

You probably don't need to split your series again on the prometheus.metrics.task_count, just remove that bucket from the Buckets list and you should be fine.
Metrics are your Y axis values, where Buckets are your X axis values, here you just need to split your series by the state value and by time you are done.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.