Skip to content

Rename full report tracking option

Lorenz van Herwaarden requested to merge rename-full-report-telemetry-track into master

What does this MR do and why?

The option in an action button in the merge request extension (both in base as in widget version) to log "full report" button clicks with telemetry events is simply called fullReport. This name is not super clear. I've renamed fullReport to trackFullReportClicked as it better covers what this option tracks. I choose this name in accordance with the emitted event name full_report_clicked.

I've done this change in both the extension structure as in the widget structure (proposed in &8353 (closed)) so they're aligned.

Screenshots or screen recordings

component screenshot
.../extensions/security_reports/mr_widget_security_reports.vue security-scanning
.../extensions/test_report/index.js test-summary
.../extensions/terraform/index.js terraform

FYI app/assets/javascripts/vue_merge_request_widget/extensions/issues.js is purely an example component.

How to set up and validate locally

Should work as before, to make sure clicking the full report button actually triggers the telemetry, you can validate as follows:

you should have runners enabled on local

terraform

  1. import basic terraform example in your local and create a simple MR (e.g. update README.md)
  2. make sure pipeline is run in the MR and expand the terraform widget
  3. click "Full log" and verify that it still emits 2 events and hence call 2 APIs (see screenshot of example API calls below)

test report

  1. go to open MR in gitlab test project on local (/gitlab-org/gitlab-test/-/merge_requests/1)
  2. click "Full report" in test summary widget and verify it calls 2 APIs for telemetry (see screenshot of example API calls below)

security report make sure you have an EE license

  1. import security-reports project in your local
  2. enable refactor_security_extension feature: echo "Feature.enable(:refactor_security_extension)" | rails c
  3. create a simple MR (e.g. update README.md)
  4. click "Full report" in security scanning widget and verify it calls 2 APIs for telemetry (see screenshot of example API calls below)

example telemetry API calls for security report:

  • increment_unique_users
  • increment_counter

Screenshot_2023-02-15_at_16.22.20

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 #389897 (closed)

Edited by Lorenz van Herwaarden

Merge request reports