Skip to content

Add `filter_project_topics` setting to Dora Performers Score chart

Alex Pennells requested to merge 426516-add-topics-filters into master

What does this MR do and why?

Start accepting a new filter_project_topics Value Streams Dashboards config value. The projects rendered in the Dora Performers score chart will be filtered using the topics provided.

Screenshots or screen recordings

Before After
Screenshot_2023-11-09_at_1.36.03_PM Screenshot_2023-11-09_at_1.34.59_PM

How to set up and validate locally

Enable feature

  1. Please make sure that you have a GitLab Ultimate license
  2. Feature.enable(:dora_performers_score_panel, <group-id>)

Setup group and projects

  1. Select a group with projects or seed a new group/project: SEED_DORA=1 FILTER=dora_metrics bundle exec rake db:seed_fu
  2. Add a topic to your project (from the project page, Settings > General > Topics)
  3. Seed DoraPerformanceScoreCounts data for your project
  4. Create a project with no topics under your chosen group. You can choose to seed data or not, up to you
  5. Visit the Value streams dashboard for your chosen group (http://{YOUR_INSTANCE}/groups/{GROUP_PATH}/-/analytics/dashboards/value_streams_dashboard) and verify that both of your projects are referenced on the Dora Performers score panel (If both have data, they'll both be rendered. If one is lacking data, a tooltip will be rendered to mention it's exclusion from the panel)

Apply filters

  1. Setup a YAML configuration for your group
  2. Add filter_project_topics config with the topic you used previously
  3. Verify that the project without the topic has been filtered out of the panel (either via the tooltip or charted data)

Seed Data

rails c
project = Project.find(<project-id>)
Dora::PerformanceScore.create(project: project, date: Time.current.last_month.beginning_of_month, deployment_frequency: 'high', lead_time_for_changes: 'high', time_to_restore_service: 'medium', change_failure_rate: 'high')

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #426516 (closed)

Edited by Alex Pennells

Merge request reports