Skip to content

Add Usage Ping to measure # of unique users pushing MRs for .gitlab-ci.yml (GMAU for self managed)

Pipeline authoring GMAU is defined as the number of users that are pushing MRs to .gitlab-ci.yml files. Since we'd like to count the on-going usage of our users with pipelines.

Objective

Add Usage Ping instrumentation to measure the number of times an MR was created for .gitlab-ci.yml file for our self-managed customers.

If it's impossible to track to the user level, we can measure at the instance level. Consider measuring the average number for all projects, or pick the top X active projects to track for a given instance. Please be explicit on the metric being tracked in the issue and/or MR.

Technical Proposal

From #287682 (comment 507925061)

Since we try to measure the number of unique users, I think we can add use HLL Redis counter.

Technical; we can add a new metric as the example below:

  • MergeRequests::CreateService -> NewMergeRequestWorker -> MergeRequests::AfterCreateService
  • -> merge_request_activity_counter.track_create_mr_action(user: current_user)
Edited by Cheryl Li