diff options
Diffstat (limited to 'lib/gitlab/instrumentation_helper.rb')
-rw-r--r-- | lib/gitlab/instrumentation_helper.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/gitlab/instrumentation_helper.rb b/lib/gitlab/instrumentation_helper.rb index 3a29d2e7efa..d7228099eaf 100644 --- a/lib/gitlab/instrumentation_helper.rb +++ b/lib/gitlab/instrumentation_helper.rb @@ -21,6 +21,7 @@ module Gitlab instrument_rugged(payload) instrument_redis(payload) instrument_elasticsearch(payload) + instrument_throttle(payload) end def instrument_gitaly(payload) @@ -56,6 +57,11 @@ module Gitlab payload[:elasticsearch_duration_s] = Gitlab::Instrumentation::ElasticsearchTransport.query_time end + def instrument_throttle(payload) + safelist = Gitlab::Instrumentation::Throttle.safelist + payload[:throttle_safelist] = safelist if safelist.present? + end + # Returns the queuing duration for a Sidekiq job in seconds, as a float, if the # `enqueued_at` field or `created_at` field is available. # |