Skip to content

Remove product section and product stage from Metric and event definitions

Problem

Right now metric and event definitions include not only the group responsible for the definition, but also the product stage and section. While product stage and section can be automatically retrieved, they still are two fields that can easily get outdated and hence require maintenance. They create mental overhead to make sure they are correct and to parse already long definition files. While it might not be written down that group names are supposed to be unique it seems to be a generally understood rule, e.g. labels like groupanalytics instrumentation depend on unique names.

Similar cases:

  • Feature flag definitions (example) use only the group label.
  • DB docs use a feature category (example)

Desired Outcome

Only product group remains as field within metric/event definitions

Proposed Solution

Remove the superfluous field from definitions and associated automations/rules etc.

On the database team side, this field has already been removed: https://gitlab.com/gitlab-data/analytics/-/issues/19747

Edited by Michał Wielich