grafana / explore-logs

Repo for the Loki log exploration app
GNU Affero General Public License v3.0
274 stars 10 forks source link

Sorting columns with different units #563

Open zizzpudding opened 1 month ago

zizzpudding commented 1 month ago

I know this is a known issue, but column sorting is not working correctly when there is a mix of units. In this case seconds and milliseconds.

image

gtk-grafana commented 1 month ago

Yeah this is a known problem, unfortunately it doesn't have an easy fix unless we disable the ability to filter by these values, as these are the actual values in loki.

I tried fixing this by changing the display function of the duration field, but the table doesn't currently support rendering/sorting a display value that is different then the actual value.

Unless there's something we can do on the loki side to have it always return a numeric value in the same format (i.e. duration_ms) @cyriltovena?