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
path: root/config
diff options
context:
space:
mode:
authorStan Hu <stanhu@gmail.com>2019-02-11 03:43:44 +0300
committerStan Hu <stanhu@gmail.com>2019-02-12 17:58:55 +0300
commit51ca79228bc2d22b12d47ba177610d228793dc94 (patch)
treebe4b156aa088aeb78eca6c198dd78810a1db5fc8 /config
parentd29e81b2aa7fc26736eb09309bbbf2ab5a5d5050 (diff)
Log queue duration in production_json.log
`queue_duration` is a useful metric that is currently in api_json.log but not in production_json.log. We should add it because it tells us how long the request sat in Workhorse before Unicorn processed it. Having this field enables the support team to better troubleshoot when delays began to happen.
Diffstat (limited to 'config')
-rw-r--r--config/initializers/lograge.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/config/initializers/lograge.rb b/config/initializers/lograge.rb
index c897bc30e76..164954d1293 100644
--- a/config/initializers/lograge.rb
+++ b/config/initializers/lograge.rb
@@ -23,7 +23,8 @@ unless Sidekiq.server?
remote_ip: event.payload[:remote_ip],
user_id: event.payload[:user_id],
username: event.payload[:username],
- ua: event.payload[:ua]
+ ua: event.payload[:ua],
+ queue_duration: event.payload[:queue_duration]
}
gitaly_calls = Gitlab::GitalyClient.get_request_count