2021-06-08 01:23:25 +05:30
|
|
|
# frozen_string_literal: true
|
|
|
|
|
|
|
|
module Gitlab
|
|
|
|
module Usage
|
|
|
|
module Metrics
|
|
|
|
module Instrumentations
|
|
|
|
class CountIssuesMetric < DatabaseMetric
|
|
|
|
operation :count
|
|
|
|
|
|
|
|
start { Issue.minimum(:id) }
|
|
|
|
finish { Issue.maximum(:id) }
|
|
|
|
|
|
|
|
relation { Issue }
|
2022-07-23 23:45:48 +05:30
|
|
|
|
|
|
|
cache_start_and_finish_as :issue
|
2021-06-08 01:23:25 +05:30
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|