Remove usage of `known_events.yml` files
Background
With all metrics having corresponding YAML definitions files that include options.events
information from known_events/
is being duplicated
Goal
Remove duplicated information and provide SSOT in form of metric YAML definitions
Implementation tips
- Unless it is not resolved before this issue (see: #280527 (closed)) consider how to migrate other attributes from
known_events
definitions like:category
,redis_slot
,aggregation
to metric YAML definition - Change implementation of
HllRedisCounter#known_events
to load data from metrics yaml definition filesoptions.events
(eg: https://gitlab.com/gitlab-org/gitlab/-/blob/master/config/metrics/counts_7d/20210216174846_p_analytics_pipelines.yml#L16) - Remove
known_events/
rake task from https://gitlab.com/gitlab-org/gitlab/-/blob/master/lib/tasks/gitlab/usage_data.rake#L37 - Remove
known_events/
directories for CE and EE editions - Remember to adjust test coverage accordingly
- Remember to update documentation https://docs.gitlab.com/ee/development/service_ping/implement.html#redis-hll-counters https://docs.gitlab.com/ee/development/service_ping/implement.html#redis-sourced-aggregated-metrics
Edited by Mikołaj Wawrzyniak