Grafana legend value (count points)

How can I show how many points there are in a series as a legend value?

Thanks.

Hi,

It depends on what data source you’re using?

Marcus

Hi Marcus,

We are using a data source plugin own. Can we introduce any legend value through the data source plugin?

Best regards!

César Huegel
Tel: +55 51 9562-3330 | huegelcesar@gmail.com

Hi,

So then I guess you could create a metric in your data source that will sum points from another metric and plot this value on a graph with a label. Otherwise define a template variable that hold the nr of points value and use this in labels/alias fields to show the count in a label.

Marcus

Hi,

Thanks for the answer, but I think this is not so clear to me. I want to put a new column in the legend table. Look at the figure below.

Inline image 2

César Huegel
Tel: +55 51 9562-3330 | huegelcesar@gmail.com

Hi,

That’s not supported. I thought you wanted the count of all points for a metric written to time-series database.

If you just want a count of the nr of points plotted on graph I suggest you to have a look at Grafana github repository and search in open and closed issue for your requirement. If you don’t find any similar I suggest you to create a new feature request issue there.

Marcus

Hi,

Thank you very much.

[]s

César Huegel
Tel: +55 51 9562-3330 | huegelcesar@gmail.com