Skip to content

Remove measure_service_ping_metric_collection ff

What does this MR do and why?

It removes measure_service_ping_metric_collection ff Feature was default enabled in 15.0 !86147 (diffs), no issues were reported. It is time to remove feature flag and release feature.

Closes #358128 (closed)

Screenshots or screen recordings

During last 7 days ~70 K of metric reports were submitted

Screenshot_2022-07-12_at_13.35.44

How to set up and validate locally

  1. Spin up local VersionApp server. If you do not have VersionApp set up locally follow this instruction

  2. Change ServicePing:SubmitService to point to your local development VersionApp instance

diff --git a/app/services/service_ping/submit_service.rb b/app/services/service_ping/submit_service.rb
index 64793f5072c..e8236f9142d 100644
--- a/app/services/service_ping/submit_service.rb
+++ b/app/services/service_ping/submit_service.rb
@@ -102,6 +102,7 @@ def save_raw_usage_data(usage_data)
     # See https://gitlab.com/gitlab-org/gitlab/-/issues/233615 for details
     def base_url
       Rails.env.production? ? PRODUCTION_BASE_URL : STAGING_BASE_URL
+      'http://localhost:3000'
     end
   end
 end
  1. In rails console $ bin/rails c trigger ServicePing report
[1] pry(main)> ServicePing::SubmitService.new.execute
  1. Look for incoming request to /usage_ping_metadata output in VersionApp
Started POST "/usage_ping_metadata" for ::1 at 2022-04-07 13:30:44 +0200
Processing by UsagePingMetadataController#create as HTML
  Parameters: {"metadata"=>{"metrics"=>[{"name"=>"version", "time_elapsed"=>3.00002284348011e-06}, {"name"=>"installation_type", "time_elapsed"=>8.999952115118504e-06}, {"name"=>"settings.ldap_encrypted_secrets_enabled", "time_elapsed"=>0.0013879999751225114}, {"name"=>"settings.smtp_encrypted_secrets_enabled", "time_elapsed"=>0.0005740000633522868}, {"name"=>"settings.operating_system", "time_elapsed"=>0.6089230000507087}, {"name"=>"settings.gitaly_apdex", "time_elapsed"=>0.012181999976746738}, {"name"=>"counts.assignee_lists", "time_elapsed"=>0.027057999977841973}, {"name"=>"counts.ci_builds", "time_elapsed"=>0.03883099998347461}, {"name"=>"counts.ci_internal_pipelines", "time_elapsed"=>0.029631000012159348},
....
{"name"=>"counts.assignee_lists", "time_elapsed"=>0.027057999977841973}, {"name"=>"counts.ci_builds", "time_elapsed"=>0.03883099998347461}, {"name"=>"counts.ci_internal_pipelines", "time_elapsed"=>0.029631000012159348}, {"name"=>"counts.ci_external_pipelines", "time_elapsed"=>0.014370999997481704}]
Completed 201 Created in 21ms (ActiveRecord: 0.0ms | Allocations: 37391)

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 Mikołaj Wawrzyniak

Merge request reports

Loading