marcusolsson / grafana-gantt-panel

A panel plugin for Grafana to visualize Gantt charts.
Apache License 2.0
26 stars 12 forks source link

Timeline Scaling Option #16

Closed vaughanbrittonsage closed 3 years ago

vaughanbrittonsage commented 3 years ago

Hi, I was wondering if it would be possible to request an option to have the gantt timeline scale based on the earliest start datetime and latest end datetime within the panel data?

My use case is my items are in milliseconds coming from log trace items, and my dashboard timeline is set to a wider time range to pick up specific traces within that period. But this makes the items on the gantt panel so small they all look the same size of a 1px line occurring at the same time unless I manually change the time range of the whole dashboard to 1 second to zoom in around the specific trace and even then they are quite small. But this is difficult to do and messes with the rest of the dashboard panels.

Thanks for the brilliant plugin and work so far.

marcusolsson commented 3 years ago

If I understand you correctly, you can use Group by to accomplish this, but I assume that you'd like to be able to "fit to view" without having to group the data.

I think I got the wrong abstraction here intially. My first idea was to separate absolute time and relative time, where relative time would be used for comparing recurring sets of tasks, e.g. nightly cron jobs, or traces.

I'm thinking about separating these into their own options, for example:

Fit tasks to: Dashboard interval, Extents X-axis: Absolute (time), Relative (duration from the first task)

vaughanbrittonsage commented 3 years ago

yes ideally I would like to be able to "Fit to View" without having to group the data.

In the meantime I will try using Group on my CorrelationTraceId within my data and see if that helps.

I'd be happy to test any options you could add.

Thanks

marcusolsson commented 3 years ago

I've published v0.6.0 where I've added an Experiments category for useful features that I've yet to figure out how to integrate :)

Feel free to play around with it and let me know what you think!

vaughanbrittonsage commented 3 years ago

That works brilliantly. Exactly what I needed. Thanks a lot!