Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'lib/gitlab/ci/artifacts/metrics.rb')
-rw-r--r--lib/gitlab/ci/artifacts/metrics.rb7
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/gitlab/ci/artifacts/metrics.rb b/lib/gitlab/ci/artifacts/metrics.rb
index 03459c4bf36..59930426cd5 100644
--- a/lib/gitlab/ci/artifacts/metrics.rb
+++ b/lib/gitlab/ci/artifacts/metrics.rb
@@ -6,6 +6,13 @@ module Gitlab
class Metrics
include Gitlab::Utils::StrongMemoize
+ def self.build_completed_report_type_counter(report_type)
+ name = "artifact_report_#{report_type}_builds_completed_total".to_sym
+ comment = "Number of completed builds with #{report_type} report artifacts"
+
+ ::Gitlab::Metrics.counter(name, comment)
+ end
+
def increment_destroyed_artifacts_count(size)
destroyed_artifacts_counter.increment({}, size.to_i)
end