Commit 0e95d709 authored by Niko Belokolodov's avatar Niko Belokolodov Committed by Nikolay Belokolodov

Remove deprecated package metrics

parent 7e1f46bc
......@@ -8,7 +8,7 @@ product_stage: package
product_group: group::package
product_category: container registry
value_type: number
status: deprecated
status: removed
time_frame: 28d
data_source: redis_hll
instrumentation_class: RedisHLLMetric
......
......@@ -8,7 +8,7 @@ product_stage: package
product_group: group::package
product_category: package registry
value_type: number
status: deprecated
status: removed
time_frame: 28d
data_source: redis_hll
instrumentation_class: RedisHLLMetric
......
......@@ -8,7 +8,7 @@ product_stage: package
product_group: group::package
product_category: package registry
value_type: number
status: deprecated
status: removed
time_frame: 28d
data_source: redis_hll
instrumentation_class: RedisHLLMetric
......
......@@ -8,7 +8,7 @@ product_stage: package
product_group: group::package
product_category: package registry
value_type: number
status: deprecated
status: removed
time_frame: 28d
data_source: redis_hll
instrumentation_class: RedisHLLMetric
......
......@@ -8,7 +8,7 @@ product_stage: package
product_group: group::package
product_category: container registry
value_type: number
status: deprecated
status: removed
time_frame: 28d
data_source: redis_hll
instrumentation_class: RedisHLLMetric
......
......@@ -8,7 +8,7 @@ product_stage: package
product_group: group::package
product_category: package registry
value_type: number
status: deprecated
status: removed
time_frame: 28d
data_source: redis_hll
instrumentation_class: RedisHLLMetric
......
......@@ -7,7 +7,7 @@ product_stage: package
product_group: group::package
product_category: package registry
value_type: number
status: deprecated
status: removed
time_frame: 28d
data_source: redis_hll
instrumentation_class: RedisHLLMetric
......
......@@ -7,7 +7,7 @@ product_stage: package
product_group: group::package
product_category: package registry
value_type: number
status: deprecated
status: removed
time_frame: 28d
data_source: redis_hll
instrumentation_class: RedisHLLMetric
......
......@@ -8,7 +8,7 @@ product_stage: package
product_group: group::package
product_category: container registry
value_type: number
status: deprecated
status: removed
time_frame: 7d
data_source: redis_hll
instrumentation_class: RedisHLLMetric
......
......@@ -8,7 +8,7 @@ product_stage: package
product_group: group::package
product_category: package registry
value_type: number
status: deprecated
status: removed
time_frame: 7d
data_source: redis_hll
instrumentation_class: RedisHLLMetric
......
......@@ -8,7 +8,7 @@ product_stage: package
product_group: group::package
product_category: package registry
value_type: number
status: deprecated
status: removed
time_frame: 7d
data_source: redis_hll
instrumentation_class: RedisHLLMetric
......
......@@ -8,7 +8,7 @@ product_stage: package
product_group: group::package
product_category: package registry
value_type: number
status: deprecated
status: removed
time_frame: 7d
data_source: redis_hll
instrumentation_class: RedisHLLMetric
......
......@@ -8,7 +8,7 @@ product_stage: package
product_group: group::package
product_category: container registry
value_type: number
status: deprecated
status: removed
time_frame: 7d
data_source: redis_hll
instrumentation_class: RedisHLLMetric
......
......@@ -7,7 +7,7 @@ product_stage: package
product_group: group::package
product_category: package registry
value_type: number
status: deprecated
status: removed
time_frame: 7d
data_source: redis_hll
instrumentation_class: RedisHLLMetric
......
......@@ -7,7 +7,7 @@ product_stage: package
product_group: group::package
product_category: package registry
value_type: number
status: deprecated
status: removed
time_frame: 7d
data_source: redis_hll
instrumentation_class: RedisHLLMetric
......
......@@ -8,7 +8,7 @@ product_stage: package
product_group: group::package
product_category: package registry
value_type: number
status: deprecated
status: removed
time_frame: 7d
data_source: redis_hll
instrumentation_class: RedisHLLMetric
......
......@@ -7,7 +7,7 @@ product_stage: package
product_group: group::package
product_category: package registry
value_type: number
status: deprecated
status: removed
time_frame: all
data_source: redis
distribution:
......
......@@ -7,7 +7,7 @@ product_stage: package
product_group: group::package
product_category: package registry
value_type: number
status: deprecated
status: removed
time_frame: all
data_source: redis
distribution:
......
......@@ -7,7 +7,7 @@ product_stage: package
product_group: group::package
product_category: package registry
value_type: number
status: deprecated
status: removed
time_frame: all
data_source: redis
distribution:
......
......@@ -12,10 +12,6 @@ RSpec.describe 'Every metric definition' do
license_add_ons
testing_total_unique_counts
user_auth_by_provider
package_events_i_package_container_push_package
package_events_i_package_container_pull_package
package_events_i_package_debian_push_package
package_events_i_package_container_delete_package
).freeze
end
......
......@@ -83,7 +83,6 @@ module API
::Packages::Debian::ProcessChangesWorker.perform_async(package_file.id, current_user.id) # rubocop:disable CodeReuse/Worker
end
track_package_event('push_package', :debian, user: current_user, project: authorized_user_project, namespace: authorized_user_project.namespace)
created!
rescue ObjectStorage::RemoteStoreError => e
Gitlab::ErrorTracking.track_exception(e, extra: { file_name: params[:file_name], project_id: authorized_user_project.id })
......
......@@ -5,12 +5,8 @@
- i_package_conan_delete_package
- i_package_conan_pull_package
- i_package_conan_push_package
- i_package_container_delete_package
- i_package_container_pull_package
- i_package_container_push_package
- i_package_debian_delete_package
- i_package_debian_pull_package
- i_package_debian_push_package
- i_package_delete_package
- i_package_delete_package_by_deploy_token
- i_package_delete_package_by_guest
......@@ -56,9 +52,6 @@
- i_package_rubygems_delete_package
- i_package_rubygems_pull_package
- i_package_rubygems_push_package
- i_package_tag_delete_package
- i_package_tag_pull_package
- i_package_tag_push_package
- i_package_terraform_module_delete_package
- i_package_terraform_module_pull_package
- i_package_terraform_module_push_package
......@@ -15,22 +15,6 @@
category: user_packages
aggregation: weekly
redis_slot: package
- name: i_package_container_deploy_token
category: deploy_token_packages
aggregation: weekly
redis_slot: package
- name: i_package_container_user
category: user_packages
aggregation: weekly
redis_slot: package
- name: i_package_debian_deploy_token
category: deploy_token_packages
aggregation: weekly
redis_slot: package
- name: i_package_debian_user
category: user_packages
aggregation: weekly
redis_slot: package
- name: i_package_generic_deploy_token
category: deploy_token_packages
aggregation: weekly
......@@ -39,14 +23,6 @@
category: user_packages
aggregation: weekly
redis_slot: package
- name: i_package_golang_deploy_token
category: deploy_token_packages
aggregation: weekly
redis_slot: package
- name: i_package_golang_user
category: user_packages
aggregation: weekly
redis_slot: package
- name: i_package_helm_deploy_token
category: deploy_token_packages
aggregation: weekly
......@@ -95,14 +71,6 @@
category: user_packages
aggregation: weekly
redis_slot: package
- name: i_package_tag_deploy_token
category: deploy_token_packages
aggregation: weekly
redis_slot: package
- name: i_package_tag_user
category: user_packages
aggregation: weekly
redis_slot: package
- name: i_package_terraform_module_deploy_token
category: deploy_token_packages
aggregation: weekly
......
......@@ -13,10 +13,6 @@ RSpec.describe Gitlab::UsageDataCounters::PackageEventCounter, :clean_gitlab_red
end
end
it 'includes the right events' do
expect(described_class::KNOWN_EVENTS.size).to eq 63
end
described_class::KNOWN_EVENTS.each do |event|
it_behaves_like 'usage counter with totals', event
end
......@@ -24,8 +20,8 @@ RSpec.describe Gitlab::UsageDataCounters::PackageEventCounter, :clean_gitlab_red
describe '.fetch_supported_event' do
subject { described_class.fetch_supported_event(event_name) }
let(:event_name) { 'package_events_i_package_composer_push_package' }
let(:event_name) { 'package_events_i_package_conan_push_package' }
it { is_expected.to eq 'i_package_composer_push_package' }
it { is_expected.to eq 'i_package_conan_push_package' }
end
end
......@@ -2,7 +2,7 @@
require 'spec_helper'
RSpec.describe Packages::CreateEventService do
let(:scope) { 'container' }
let(:scope) { 'generic' }
let(:event_name) { 'push_package' }
let(:params) do
......@@ -75,24 +75,24 @@ RSpec.describe Packages::CreateEventService do
context 'with a user' do
let(:user) { create(:user) }
it_behaves_like 'db package event creation', 'user', 'container'
it_behaves_like 'redis package unique event creation', 'user', 'container'
it_behaves_like 'redis package count event creation', 'user', 'container'
it_behaves_like 'db package event creation', 'user', 'generic'
it_behaves_like 'redis package unique event creation', 'user', 'generic'
it_behaves_like 'redis package count event creation', 'user', 'generic'
end
context 'with a deploy token' do
let(:user) { create(:deploy_token) }
it_behaves_like 'db package event creation', 'deploy_token', 'container'
it_behaves_like 'redis package unique event creation', 'deploy_token', 'container'
it_behaves_like 'redis package count event creation', 'deploy_token', 'container'
it_behaves_like 'db package event creation', 'deploy_token', 'generic'
it_behaves_like 'redis package unique event creation', 'deploy_token', 'generic'
it_behaves_like 'redis package count event creation', 'deploy_token', 'generic'
end
context 'with no user' do
let(:user) { nil }
it_behaves_like 'db package event creation', 'guest', 'container'
it_behaves_like 'redis package count event creation', 'guest', 'container'
it_behaves_like 'db package event creation', 'guest', 'generic'
it_behaves_like 'redis package count event creation', 'guest', 'generic'
end
context 'with a package as scope' do
......
......@@ -40,7 +40,6 @@ RSpec.shared_examples 'Debian packages upload request' do |status, body = nil|
expect(response.body).to match(body)
end
end
it_behaves_like 'a package tracking event', described_class.name, 'push_package'
else
it "returns #{status}#{and_body}", :aggregate_failures do
subject
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment