Commit Graph

61 Commits

Author SHA1 Message Date
Thong Kuah 8c42a0eac0 Add frozen_string_literal to lib part 2
Using the sed script from
https://gitlab.com/gitlab-org/gitlab-ce/issues/59758
2019-08-23 00:15:24 +12:00
Thong Kuah 9e19125f39 Merge branch 'sh-fix-sidekiq-scheduling-latency' into 'master'
Fix Sidekiq scheduling_latency_s

Closes #65748

See merge request gitlab-org/gitlab-ce!31650
2019-08-09 11:59:44 +00:00
Stan Hu a74396dcc5 Add Gitaly and Rugged call timing in Sidekiq logs
This will help identify Sidekiq jobs that invoke excessive number of
filesystem access.

The timing data is stored in `RequestStore`, but this is only active
within the middleware and is not directly accessible to the Sidekiq
logger. However, it is possible for the middleware to modify the job
hash to pass this data along to the logger.
2019-08-09 01:08:32 -07:00
Stan Hu 7ccbb562b1 Fix Sidekiq scheduling_latency_s
This number was reporting a negative number because `current_time` was
a monotonic counter, not an absolute time.

Closes https://gitlab.com/gitlab-org/gitlab-ce/issues/65748
2019-08-08 20:51:40 -07:00
Andrew Newdigate ee828f09bf Adds Sidekiq scheduling latency structured logging field 2019-07-31 12:07:47 +00:00
Andrew Newdigate ff0b2cc61f Re-enable MethodCallWithoutArgsParentheses Cop
Re-enables and autocorrects all instances of the
Style/MethodCallWithoutArgsParentheses rule
2019-01-29 21:05:30 +02:00
Sean McGivern 9d2be75674 Limit Sidekiq args logging to 10 KB of JSON
When logging arguments from Sidekiq to JSON, restrict the size of `args`
to 10 KB (when converted to JSON). This is to avoid blowing up with
excessively large job payloads.
2019-01-22 10:54:12 +00:00
Kamil Trzciński ebb5d9f4db Revert "Prefer to use correlation-id in logs"
This reverts commit 3560b11922.
2018-12-06 21:46:31 +01:00
Kamil Trzciński 3560b11922 Prefer to use correlation-id in logs
This changes `correlation_id` to be `correlation-id` when passed via jobs
2018-12-06 20:49:31 +01:00
Kamil Trzciński 39c1731a53 Log and pass correlation-id between Unicorn, Sidekiq and Gitaly
The Correlation ID is taken or generated from received X-Request-ID.
Then it is being passed to all executed services (sidekiq workers
or gitaly calls).

The Correlation ID is logged in all structured logs as `correlation_id`.
2018-12-06 20:46:14 +01:00
Stan Hu 6415ac9e99 Add support for Sidekiq JSON logging
Closes #20060
2018-04-04 05:04:00 -07:00