Pie Chart not showing Bytes

Hello,
Is this a bug?

I have a field with the values as bytes:


But I want to display the data on the pie chart as bytes but I only get two options:

what version?

Also can you show exactly how you are getting used and free ... i.e. the rest of the configuration?

  • What is the metric and what is the slice by? (I suspect you need to put bytes on the slice by as well)
  • What is the data coming from?
  • What fields are you using?

Lens Latest...

Hello @stephenb ,

I am on v9.0.3
The metric is numerical field from prometheus collector integration. The field contains the number but typically can be converted to bytes in Lens.

I changed the visualization to a table:

If you noticed the number is now formatted as bytes in table visualization (as expected).
The issue is I wanted to show in the pie chart the breakdown by bytes (formatted as bytes)

Hi @erikg I think I have helped you a few times...

I tend to ask very specific questions without explaining why :slight_smile: I am trying to get the the issue as fast as possible.

So I asked if you could show me the entire config for the Pie Viz.

What you gave me was ... See it works in the table... and a the tiniest smidget of detail and a redacted field name :slight_smile: .... pardon the chuckles but not much help :slight_smile:

Which is precisely why I asked you to show me the entire configuration including the field name which you redacted ... looks like some prometheus field ... what is the mapping ... which can have an affect. I asked what the slice by etc... did you set the bytes in the slice by?

I will add what data view is this coming from?

Where are you getting used and free from?

There are a few places this could be (like the data view) or in the sliceby... or the data type..... So provide what you can ... I will see if I can help...

my suspicion (not fact)... not a bug but a setting somewhere but don't have enough to operate on...

Hello @stephenb,
Yes you have and I understand what you mean. I am trying to avoid sharing too much uneccessary info.

Continuing on, I think I figured out the issue:

Heres' a better example using common ecs fields:


The issue appears when I try to add two metrics to compare against:


Hopefully this makes more sense:

:slight_smile: .... the balance ... but no detail no answer.

I can reproduce now, I was missing setting layer setting use multiple metrics.

I will ask and see if we can get an answer

Perhaps @Marco_Liberati Might have an idea

Hiya Marco
Use Lens Latest S
Pie Chart
Layer Setting multiple metrics
Use 2 byte metrics
I set the format in each to Bytes
I also set in the data view to Bytes
But the number in the pie chart is just a long not friendly Bytes... if I only have 1 metrics I get bytes


I can reproduce the issue.
I've opened an issue you can track here about it: [Lens] Pie chart in multiple metrics mode doesn't apply correct format to values · Issue #229644 · elastic/kibana · GitHub

2 Likes