gitlab-labkit 0.35.0 → 0.36.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 93345552c013b93d13d6f87e2160c737489e75ccdb63ba1638cd22a8c92508a1
4
- data.tar.gz: e55c8ec4d4d17a9d207b3b0ff9af27b92821d6b7210a304a192e120a07c19141
3
+ metadata.gz: 8de30f81c7d686614fa1a01ba73fbfd73ffa3ecaf06bf38cd8698fc6ad98fb43
4
+ data.tar.gz: 4a118dddf92c9affdc04f4ec39f7d2029edada61bf919dd9e9269dfc9b0ab740
5
5
  SHA512:
6
- metadata.gz: 97c4077db5b62456809cb9fea6850d6e4977cbcd0979562d704eb6ef55eb8aca3fce2ecf6a89beb7d496f8c88b94c46e1a00cd9b06b6b5591255cb0158601b8a
7
- data.tar.gz: 9c91a4e8e5c36fbbd9f65587ff00f756a5112adb8b1c8d22cf4a9401dac8b7c8628bf2b294afa19bb03eac247d9f5ccdd3a32bfae23ad7300c3eb78cb6681b15
6
+ metadata.gz: 874641186b4d1de6df98dc69fbd12e3e0be6c4f1b15501cc2dd91341f5b5a843d3c000404067197864aca071328b3fdac13aeb9f6ff38cc561d245c1bcfbcf76
7
+ data.tar.gz: e30bc5213eae9ac3bdf1cd7e9d3ab3cff3455f82e7cd79d9868b077f0fe44ededfdd1f6346db2b3546b5bcb127dbe2fa7d64529e7972c4bcb9880874e835ba21
@@ -21,7 +21,7 @@ Gem::Specification.new do |spec|
21
21
  # Please maintain alphabetical order for dependencies
22
22
  spec.add_runtime_dependency "actionpack", ">= 5.0.0", "< 8.0.0"
23
23
  spec.add_runtime_dependency "activesupport", ">= 5.0.0", "< 8.0.0"
24
- spec.add_runtime_dependency "grpc", ">= 1.37" # Be sure to update the "grpc-tools" dev_dependency too
24
+ spec.add_runtime_dependency "grpc", ">= 1.62" # Be sure to update the "grpc-tools" dev_dependency too
25
25
  spec.add_runtime_dependency "jaeger-client", "~> 1.1.0"
26
26
  spec.add_runtime_dependency "opentracing", "~> 0.4"
27
27
  spec.add_runtime_dependency "pg_query", ">= 4.2.3", "< 6.0"
@@ -32,7 +32,7 @@ Gem::Specification.new do |spec|
32
32
  spec.add_development_dependency "faraday", "~> 1.0"
33
33
  spec.add_development_dependency "gitlab-dangerfiles", "~> 2.11.0"
34
34
  spec.add_development_dependency "gitlab-styles", "~> 6.2.0"
35
- spec.add_development_dependency "grpc-tools", ">= 1.37"
35
+ spec.add_development_dependency "grpc-tools", ">= 1.62"
36
36
  spec.add_development_dependency "httparty", "~> 0.17.3"
37
37
  spec.add_development_dependency "httpclient", "~> 2.8.3"
38
38
  spec.add_development_dependency "pry", "~> 0.12"
@@ -66,10 +66,6 @@ module Labkit
66
66
  "#{LOG_KEY}.#{key}"
67
67
  end
68
68
 
69
- def known_log_keys
70
- @known_log_keys ||= (KNOWN_KEYS.map(&method(:log_key)) + RAW_KEYS).freeze
71
- end
72
-
73
69
  private
74
70
 
75
71
  def contexts
@@ -9,7 +9,15 @@ module Labkit
9
9
  # be reinstantiated by Sidekiq-server when running the job.
10
10
  class Client
11
11
  def call(_worker_class, job, _queue, _redis_pool)
12
- Labkit::Context.with_context do |context|
12
+ attributes = {}
13
+
14
+ # Don't overwrite the correlation_id from the job. A new context
15
+ # will always generate a new correlation_id and we'd rather carry
16
+ # through the correlation_id from the previous job if it is
17
+ # present (eg. for retries).
18
+ attributes[Labkit::Context::CORRELATION_ID_KEY] = job["correlation_id"] if job["correlation_id"]
19
+
20
+ Labkit::Context.with_context(attributes) do |context|
13
21
  job.merge!(context.to_h)
14
22
 
15
23
  yield
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gitlab-labkit
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.35.0
4
+ version: 0.36.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andrew Newdigate
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-01-09 00:00:00.000000000 Z
11
+ date: 2024-04-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: actionpack
@@ -56,14 +56,14 @@ dependencies:
56
56
  requirements:
57
57
  - - ">="
58
58
  - !ruby/object:Gem::Version
59
- version: '1.37'
59
+ version: '1.62'
60
60
  type: :runtime
61
61
  prerelease: false
62
62
  version_requirements: !ruby/object:Gem::Requirement
63
63
  requirements:
64
64
  - - ">="
65
65
  - !ruby/object:Gem::Version
66
- version: '1.37'
66
+ version: '1.62'
67
67
  - !ruby/object:Gem::Dependency
68
68
  name: jaeger-client
69
69
  requirement: !ruby/object:Gem::Requirement
@@ -194,14 +194,14 @@ dependencies:
194
194
  requirements:
195
195
  - - ">="
196
196
  - !ruby/object:Gem::Version
197
- version: '1.37'
197
+ version: '1.62'
198
198
  type: :development
199
199
  prerelease: false
200
200
  version_requirements: !ruby/object:Gem::Requirement
201
201
  requirements:
202
202
  - - ">="
203
203
  - !ruby/object:Gem::Version
204
- version: '1.37'
204
+ version: '1.62'
205
205
  - !ruby/object:Gem::Dependency
206
206
  name: httparty
207
207
  requirement: !ruby/object:Gem::Requirement