Add DORA projects comparison panel analytics dashboard visualization
What does this MR do and why?
Adds a new analytics dashboard visualization to compare DORA metrics for projects within a group. The new DoraProjectsComparison will not be visible on any dashboards at this point, but can be viewed by adding the visualization to a custom Value streams dashboard.
MR acceptance checklist
Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
Screenshots or screen recordings
Screenshots are required for UI changes, and strongly recommended for all other merge requests.
| No data | With data |
|---|---|
![]() |
![]() |
Video recorded with panel.height = 2
How to set up and validate locally
- Ensure you are using GitLab Ultimate
- Create a custom Value streams dashboard for any group of your choosing, using the sample config:
version: '2'
title: 'Custom VSD'
panels:
- title: 'Projects by DORA categories (Last full calendar month)'
visualization: dora_projects_comparison
gridAttributes:
yPos: 0
xPos: 0
height: 4
width: 12
- Access the custom VSD from the analytics dashboards list (ex. http://gdk.test:3000/groups/flightjs/-/analytics/dashboards)
- By default you should see the
No data availablemessage - Create mock DORA data for two or more projects within the group ()
project = Group.find(GROUP_ID).projects.first
# generate mock DORA metrics for the last 2 months
# project must have a default environment set first, or this will error
[
[1.month.ago, 12, 10, 2, 5],
[2.month.ago, 16, 7, 1, 9]
].each do |date, deploys, lead_time_for_changes, time_to_restore_service, incidents_count|
Dora::DailyMetrics.create!(
deployment_frequency: deploys,
lead_time_for_changes_in_seconds: lead_time_for_changes * 1.day.to_i,
time_to_restore_service_in_seconds: time_to_restore_service * 1.day.to_i,
incidents_count: incidents_count,
environment: project.default_environment,
date: date
)
end
- Verify that data loads and can be sorted as expected
Related to #408516 (closed)
Edited by Alex Pennells

