Stat / Status timeline: value mapping for null seems not working

  • What Grafana version and what operating system are you using?
    Grafana 10.1.5

  • What are you trying to achieve?
    I’ve a service which every 15 seconds sends metric (let say “alive”) to InfluxDB - it is a raw metric from telegraf, not agregated. I can read this metric and display it on “Stat”, “Stats Timeline” or “Status History” panel, all is ok. but… Based on that metric I’d like to show availability of my service. So… I’m using value mapping and it works as long as I’m using “fill(0)” in group by section…
    value mapping 0 → Down works fine… but when I’m trying to change to “fill(null)” and use value mapping special (null) → Down… it doesn’t work.
    Why I’m trying to use fill(null)? because I plan to use another feature of Stats timeline: Connect null values with specified threshold.

  • How are you trying to achieve it?

  • What happened?
    When I’m using group by: fill(0) value mapping: 0 → “Down” works.
    When I’m using group by: fill(null) value mapping: special(null) → “Down” doesn’t work.

  • What did you expect to happen?
    Be able to use value mapping special (null) with fill(null) for group by.

Or… maybe I’m wrong. Maybe it is better option to achieve that. (Display availability status from raw metric (heartbeat) with 15 - 20 seconds interval but without false negatives at the end of observed time period.

  • Can you copy/paste the configuration(s) that you are having problems with?

  • Did you receive any errors in the Grafana UI or in related logs? If so, please tell us exactly what they were.

  • Did you follow any online instructions? If so, what is the URL?

welcome to forum @Marcin

per

fill() replaces all null values in input tables with a non-null value.

what if you just avoid using it totally and see what special - null value mapping looks like.

Hi @yosiasz
Thanks for suggestion, but… Unfortunally it doesn’t work for me… Doesn’t matter if I have fill(null) or I just avoid it I’ve “holes” in the state timeline… but if I use fill(0) there is no holes and value mapping works (I’ve two mappings there for test one for replace “0” and second for replace “null values”)…
… I’m afraid I cannot do any printscreen now to show you my setup and how it looks like.