Skip to content

Skip migrated redis hll categories in counter

What does this MR do and why?

Gitlab::UsageDataCounters::HLLRedisCounter.unique_events_data was used to collect all Redis HLL metrics data and add it to Service Ping payload. With new instrumentation classes framework there is new unified approach into adding metrics into Service Ping payload. This commits removes Redis HLL metrics categories from .unique_events_data and allows new framework automation to fill them in.

#338463 (closed)

Screenshots or screen recordings

These are strongly recommended to assist reviewers and reduce the time to merge your change.

How to set up and validate locally

pry(main)> ::Feature.enable(:use_redis_hll_instrumentation_classes)

pry(main)> Gitlab::UsageDataCounters::HLLRedisCounter.unique_events_data['error_tracking']
=> nil

pry(main)> ServicePing::BuildPayload.new.execute[:redis_hll_counters]['error_tracking']
=> {"error_tracking_view_list_weekly"=>0, "error_tracking_view_details_weekly"=>0, "error_tracking_total_unique_counts_weekly"=>0, "error_tracking_view_details_monthly"=>0, "error_tracking_view_list_monthly"=>0, "error_tracking_total_unique_counts_monthly"=>0}

pry(main)> ::Feature.disable(:use_redis_hll_instrumentation_classes)

pry(main)> Gitlab::UsageDataCounters::HLLRedisCounter.unique_events_data['error_tracking']
=> {"error_tracking_view_details_weekly"=>0, "error_tracking_view_details_monthly"=>0, "error_tracking_view_list_weekly"=>0, "error_tracking_view_list_monthly"=>0, "error_tracking_total_unique_counts_weekly"=>0, "error_tracking_total_unique_counts_monthly"=>0}

pry(main)> ServicePing::BuildPayload.new.execute[:redis_hll_counters]['error_tracking']
=> {"error_tracking_view_details_weekly"=>0, "error_tracking_view_details_monthly"=>0, "error_tracking_view_list_weekly"=>0, "error_tracking_view_list_monthly"=>0, "error_tracking_total_unique_counts_weekly"=>0, "error_tracking_total_unique_counts_monthly"=>0}

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Markus Koller

Merge request reports