How to separate overlapping time intervals into different rows in Grafana? (original) (raw)
Hi everyone,
I’m working on a dashboard that visualizes event durations using the Marcus Olsson Gantt plugin. The data consists of tasks with a start and end time, and sometimes multiple tasks (with the same label) overlap in time.
Here’s a simplified example of the data:
Element, Start time, End time, Color
Buffer, 2025-06-05 04:00:00, 2025-06-05 04:11:00, blue
Prepare, 2025-06-05 04:20:00, 2025-06-05 04:31:00, green
Buffer, 2025-06-05 04:05:00, 2025-06-05 04:15:00, red
As you can see, the two “Buffer” entries overlap. The issue is that the Gantt plugin renders them on the same row, causing them to visually overlap. I’m looking for a way to automatically detect overlaps and put them on separate rows or lanes—without having to preprocess the data manually.
Constraints:
- The data is generated dynamically and cannot be preprocessed.
- I’m publishing this dashboard to 1,000+ users, so manual lane assignment is not feasible.
- I explored dashboard JSON editing and transformations, but they don’t support logic for overlap detection.
- I’m open to using other panels (like State Timeline or Time Series) if they can solve this.
What I’ve Tried:
- Using the “Group by” field in the Gantt plugin (works only if I manually assign lanes).
- Exploring transformations (no way to detect overlaps).
- Editing dashboard JSON (no scripting or conditional logic possible).
- State Timeline panel, but it assumes continuous states and extends the last state to infinity, which doesn’t work for discrete event durations.
Question:
Has anyone found a way—either through a plugin, transformation, or clever workaround—to automatically separate overlapping time intervals in Grafana?
Or is this something that would require a custom plugin or backend service?
Thanks in advance for any insights or suggestions!
yosiasz June 10, 2025, 11:31pm 2
Super specific requirements will require something not out of the box
Please see these options
One
https://codepen.io/nite/pen/arwozr
You can try JavaScript with the business text plugin from volkov labs and reference plotly
Two
Another option using js but with the business chart plugin from volkov labs
Thanks for the suggestions! I appreciate the Plotly and ECharts options via Volkov Labs, but I’m really looking for a native Grafana solution—something that works out of the box or integrates directly with Grafana’s core panels or data sources.
What I’m imagining and will try to explore next is something like:
- Traces, where overlapping spans are automatically stacked.
- Or using Grafana Tempo to visualize discrete durations as spans, even if they’re not tied to traces in the traditional sense.
Basically, I want to visualize event durations (start → end) with potential overlaps, and have Grafana auto-unstack them into separate rows or lanes—without needing to preprocess the data or manually assign lanes.
Is there any way to achieve this natively in Grafana, or is this something that would require a new core panel or plugin?
yosiasz June 11, 2025, 6:11pm 4
no such stock plugin that I know. Unless you are willing to fork and update the old one to work with most recent grafana version.