Add options arguments to Redis HLL Metric YAML definition

What does this MR do?

Add options arguments to Redis HLL Metric YAML definition for filtering data in instrumentation class

  • Rename extra attribute to options
  • Add required options[:events] to RedisHLLMetrics

This makes instrumentation for data from Redis HLL easier using only metric definition YAML file so we don't need a class for each event tracked using Redis HLL.

Example of usage

---
key_path: redis_hll_counters.quickactions.i_quickactions_approve_weekly
description: Count of WAU using the `/approve` quick action
product_section: dev
product_stage: create
product_group: group::code review
product_category: code_review
value_type: number
status: data_available
time_frame: 7d
data_source: redis_hll
instrumentation_class: 'Gitlab::Usage::Metrics::Instrumentations::RedisHLLMetric'
options:
  events:
    - i_quickactions_approve
distribution:
- ce
- ee
tier:
- free
- premium
- ultimate

Screenshots (strongly suggested)

Does this MR meet the acceptance criteria?

Conformity

Availability and Testing

Related to #327736 (closed)

Edited by Alper Akgun

Merge request reports

Loading