diff --git a/doc/development/telemetry/usage_ping.md b/doc/development/telemetry/usage_ping.md index 2427b82b8a87f950cb1634b326f9e12472d27235..cd6d003155f74a4c543152dc9e68845c537862ca 100644 --- a/doc/development/telemetry/usage_ping.md +++ b/doc/development/telemetry/usage_ping.md @@ -513,8 +513,6 @@ appear to be associated to any of the services running, since they all appear to | `projects_unify_circuit_active` | `counts` | | | | | | `projects_webex_teams_active` | `counts` | | | | | | `projects_youtrack_active` | `counts` | | | | | -| `projects_slack_notifications_active` | `counts` | | | | | -| `projects_slack_slash_active` | `counts` | | | | | | `projects_jira_server_active` | `counts` | | | | | | `projects_jira_cloud_active` | `counts` | | | | | | `projects_jira_dvcs_cloud_active` | `counts` | | | | | diff --git a/lib/gitlab/usage_data.rb b/lib/gitlab/usage_data.rb index 38ca70e755c8e7124cb0f4fd2d757a9ef66554d6..71c15f7ca276f59717531ad8b36cbec93327d6e1 100644 --- a/lib/gitlab/usage_data.rb +++ b/lib/gitlab/usage_data.rb @@ -347,15 +347,9 @@ def container_expiration_policies_usage # rubocop: disable CodeReuse/ActiveRecord def services_usage - results = Service.available_services_names.without('jira').each_with_object({}) do |service_name, response| + Service.available_services_names.without('jira').each_with_object({}) do |service_name, response| response["projects_#{service_name}_active".to_sym] = count(Service.active.where(template: false, type: "#{service_name}_service".camelize)) - end - - # Keep old Slack keys for backward compatibility, https://gitlab.com/gitlab-data/analytics/issues/3241 - results[:projects_slack_notifications_active] = results[:projects_slack_active] - results[:projects_slack_slash_active] = results[:projects_slack_slash_commands_active] - - results.merge(jira_usage).merge(jira_import_usage) + end.merge(jira_usage).merge(jira_import_usage) end def jira_usage diff --git a/spec/lib/gitlab/usage_data_spec.rb b/spec/lib/gitlab/usage_data_spec.rb index dd32311e79e13d020f9a2274804b38823b0bc20e..bc4a4fd53e835438099f611d4b786306ec2968a2 100644 --- a/spec/lib/gitlab/usage_data_spec.rb +++ b/spec/lib/gitlab/usage_data_spec.rb @@ -126,8 +126,6 @@ expect(count_data[:jira_imports_projects_count]).to eq(2) expect(count_data[:jira_imports_total_imported_count]).to eq(3) expect(count_data[:jira_imports_total_imported_issues_count]).to eq(13) - expect(count_data[:projects_slack_notifications_active]).to eq(2) - expect(count_data[:projects_slack_slash_active]).to eq(1) expect(count_data[:projects_slack_active]).to eq(2) expect(count_data[:projects_slack_slash_commands_active]).to eq(1) expect(count_data[:projects_custom_issue_tracker_active]).to eq(1) diff --git a/spec/support/helpers/usage_data_helpers.rb b/spec/support/helpers/usage_data_helpers.rb index 7ea03f3cc7ad35928af6ebb3640a9228c896440b..40bb0f396fc21502d0e8d5fdc12a8549529ba237 100644 --- a/spec/support/helpers/usage_data_helpers.rb +++ b/spec/support/helpers/usage_data_helpers.rb @@ -89,8 +89,6 @@ module UsageDataHelpers projects_jira_active projects_jira_server_active projects_jira_cloud_active - projects_slack_notifications_active - projects_slack_slash_active projects_slack_active projects_slack_slash_commands_active projects_custom_issue_tracker_active