Quarantine broken security_products_usage metrics
What does this MR do and why?
Describe in detail what your merge request does and why.
index_security_ci_builds_on_name_and_id_parser_features
index is marked as broken on gitlab.com database. This index supports security_products_usage
metrics that are included in weekly Service Ping reporting. With broken index reporting process performance has decreased dramatically from ~8 hours to over 24 hours right now (while still processing) and with estimation of 110 days to finish.
This performance degradation prevents all other metrics from reporting data, so in order to preserve as much data as possible until index is fixed affected metrics will be put into quarantine and return fallback value of -1
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
In rails console:
::ApplicationSetting.current.update_attribute(:usage_ping_enabled, true) # enable Service Ping collection
Feature.enable(:quarantine_security_products_usage_metrics) # toggle quarantine_security_products_usage_metrics feature flag
service_ping_payload = ServicePing::BuildPayloadService.new.execute # collect service ping payload
service_ping_payload.dig(:counts, :sast_jobs) # check different key_paths from updated metrics definitions files
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Related to https://gitlab.com/gitlab-org/product-intelligence/-/issues/471