Commit 9d3299f6 authored by Giorgenes Gelatti's avatar Giorgenes Gelatti

Adds package count to usage data

parent 787ad7eb
---
title: Adds package count to usage data
merge_request: 40039
author:
type: added
...@@ -130,6 +130,7 @@ module Gitlab ...@@ -130,6 +130,7 @@ module Gitlab
milestone_lists: count(List.milestone), milestone_lists: count(List.milestone),
milestones: count(Milestone), milestones: count(Milestone),
projects_with_packages: distinct_count(::Packages::Package, :project_id), projects_with_packages: distinct_count(::Packages::Package, :project_id),
packages: count(::Packages::Package),
pages_domains: count(PagesDomain), pages_domains: count(PagesDomain),
pool_repositories: count(PoolRepository), pool_repositories: count(PoolRepository),
projects: count(Project), projects: count(Project),
......
...@@ -417,6 +417,7 @@ RSpec.describe Gitlab::UsageData, :aggregate_failures do ...@@ -417,6 +417,7 @@ RSpec.describe Gitlab::UsageData, :aggregate_failures do
expect(count_data[:project_snippets]).to eq(4) expect(count_data[:project_snippets]).to eq(4)
expect(count_data[:projects_with_packages]).to eq(2) expect(count_data[:projects_with_packages]).to eq(2)
expect(count_data[:packages]).to eq(3)
end end
it 'gathers object store usage correctly' do it 'gathers object store usage correctly' do
......
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