How to Map Colors Automatically in State Timeline - Discrete Deprecation

Hello:

I will keep the template, I think it is more concise that way, I did not find a subcategory for the State timeline panel.

  • What Grafana version and what operating system are you using?
    *V10.4.8

  • What are you trying to achieve?
    As there is no longer angular support in older grafana, we need to stop using the Discrete plugin. We use this plugin extensively in our visualizations.

Several sources say that the Discrete plugin should be replaced with the state timeline panel.

I need to be able to map automatically the colors for the different states, We use the panel to show the program that is being executed by some of our machines and the tools that are being used, with hundreds of possibilities. The Discrete plugin maps the color automatically but the state timeline does not do this and then we get a single color when we should get more:

This is how it looks with Discrete

This is how it looks with State Timeline

I have not found a resource that tells me how I can map the colors with state timeline, for us it not possible to declare them in the configuration because we have too many possibilities.

Is there a way to do this?

can you please drop a csv export of your data?

Hello, thanks for reaching out. To share data I need to go over an approval process. Could you tell me how sharing the data would help? I am aware that you are trying to assist but I cannot violate the company procedures.

post obfuscated data then, I mean you have already shared the data albeit in image format

I don’t have access to your grafana, so sharing the data makes it possible for me to replicate your panel…

as yosiasz said, it doesn’t have to be exact data…

1 Like

I’ve encountered the same problem. Right now, when the data is almost random and there’s no way of knowing what it might be, assigning colors randomly in a state timeline isn’t possible. Instead, I assign colors using value mappings and regex. I assign different colors to the data, starting with each alphabet letter