Implement Hotspot Root Cause Analysis experiment

What does this MR do and why?

This MR implements the Root Cause Analysis Hotspot experiment. Key changes include:

  1. Created a new component: root_cause_analysis_hotspot_experiment.vue
  2. Wraps RootCauseAnalysisButton with RootCauseAnalysisHotspotExperiment
  3. Replaces RootCauseAnalysisButton with RootCauseAnalysisHotspotExperiment in:
    • app/assets/javascripts/ci/job_details/job_app.vue
    • app/assets/javascripts/ci/pipelines_page/components/failure_widget/failed_job_details.vue
  4. Added the feature flag configuration: config/feature_flags/experiment/root_cause_analysis_hotspot.yml
  5. Added the hotspot gif and initial tracking along with associated specs

This MR does not include:

  • Persisted callout logic for User on popover dismissal (to be handled in follow-on MR)
  • Full tracking for hotspot persisted / dismissed - and render_hotspot abiding by that logic to be handled in follow-on MR

References

Please include cross links to any resources that are relevant to this MR. This will give reviewers and future readers helpful context to give an efficient review of the changes introduced.

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.

Before (Control) After (Candidate)

Screenshot 2025-03-21 at 5.59.19 PM.png

Screenshot 2025-03-21 at 6.00.07 PM.png

Screenshot 2025-03-21 at 12.06.04 AM.png

Screenshot 2025-03-21 at 12.05.54 AM.png

Tracking:

rca-experiment-first-half-tracking rca-experiment-second-half-tracking

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

## Steps

  1. Have Duo setup (see https://docs.gitlab.com/ee/development/ai_features/index.html)

Or apply this patch 507261.patch

  1. Ensure GitLab SAAS is setup with GITLAB_SIMULATE_SAAS=1
  2. Enable the feature flag `root_cause_analysis_hotspot`
  3. Visit a job details page with a failed job and verify the hotspot or control button appears in place of the standard Root Cause Analysis button
  4. Click the hotspot and confirm it opens the Duo chat interface with the correct job context
  5. Visit the pipelines page with a failed job and confirm the hotspot appears in the failed job details section
  6. Click the hotspot from the pipelines page and verify it correctly opens Duo chat with the appropriate job information
  7. Verify tracking events are captured with Snowplow inspector when interacting with the hotspot and experiment

Related to #521443

Edited by Buck O'Leary

Merge request reports

Loading