opentelemetry-instrumentation-sidekiq 0.21.0 → 0.21.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +5 -0
- data/lib/opentelemetry/instrumentation/sidekiq/middlewares/client/tracer_middleware.rb +3 -3
- data/lib/opentelemetry/instrumentation/sidekiq/middlewares/server/tracer_middleware.rb +5 -5
- data/lib/opentelemetry/instrumentation/sidekiq/patches/launcher.rb +3 -3
- data/lib/opentelemetry/instrumentation/sidekiq/patches/poller.rb +4 -4
- data/lib/opentelemetry/instrumentation/sidekiq/patches/processor.rb +3 -3
- data/lib/opentelemetry/instrumentation/sidekiq/version.rb +1 -1
- metadata +37 -9
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1cc83ff362f5090ca035b572e3676cf85e592a8c90a91cde8d9a61aa02d0f408
|
4
|
+
data.tar.gz: 6c7a097d13e35658a95554455e479b12ae8089ab32569739c6a68d1eed773a19
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1c8fa0bd57e19628d70e5b0e818e37aa6f1368900cbad30407506e02e0674ca20164a65e0e393e39f583a5085691b0716c25678253b9ebeba3673acb7762aa61
|
7
|
+
data.tar.gz: 88de2296bf1c878158456f56e0e22f8e68c186c31128ba35e9a867d9b2237e67ed6561f2ba8a3f166f2367477f48ebca5908000bb58c0659d2277b029ff2af21
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,10 @@
|
|
1
1
|
# Release History: opentelemetry-instrumentation-sidekiq
|
2
2
|
|
3
|
+
### v0.21.1 / 2022-06-09
|
4
|
+
|
5
|
+
* FIXED: Broken test file requirements
|
6
|
+
* FIXED: Make sidekiq instrumentation compatible with sidekiq 6.5.0
|
7
|
+
|
3
8
|
### v0.21.0 / 2022-05-02
|
4
9
|
|
5
10
|
* ADDED: Validate Using Enums
|
@@ -20,9 +20,9 @@ module OpenTelemetry
|
|
20
20
|
'messaging.destination' => job['queue'],
|
21
21
|
'messaging.destination_kind' => 'queue'
|
22
22
|
}
|
23
|
-
attributes['peer.service'] =
|
23
|
+
attributes['peer.service'] = instrumentation_config[:peer_service] if instrumentation_config[:peer_service]
|
24
24
|
|
25
|
-
span_name = case
|
25
|
+
span_name = case instrumentation_config[:span_naming]
|
26
26
|
when :job_class then "#{job['wrapped']&.to_s || job['class']} send"
|
27
27
|
else "#{job['queue']} send"
|
28
28
|
end
|
@@ -36,7 +36,7 @@ module OpenTelemetry
|
|
36
36
|
|
37
37
|
private
|
38
38
|
|
39
|
-
def
|
39
|
+
def instrumentation_config
|
40
40
|
Sidekiq::Instrumentation.instance.config
|
41
41
|
end
|
42
42
|
|
@@ -21,16 +21,16 @@ module OpenTelemetry
|
|
21
21
|
'messaging.destination_kind' => 'queue',
|
22
22
|
'messaging.operation' => 'process'
|
23
23
|
}
|
24
|
-
attributes['peer.service'] =
|
24
|
+
attributes['peer.service'] = instrumentation_config[:peer_service] if instrumentation_config[:peer_service]
|
25
25
|
|
26
|
-
span_name = case
|
26
|
+
span_name = case instrumentation_config[:span_naming]
|
27
27
|
when :job_class then "#{msg['wrapped']&.to_s || msg['class']} process"
|
28
28
|
else "#{msg['queue']} process"
|
29
29
|
end
|
30
30
|
|
31
31
|
extracted_context = OpenTelemetry.propagation.extract(msg)
|
32
32
|
OpenTelemetry::Context.with_current(extracted_context) do
|
33
|
-
if
|
33
|
+
if instrumentation_config[:propagation_style] == :child
|
34
34
|
tracer.in_span(span_name, attributes: attributes, kind: :consumer) do |span|
|
35
35
|
span.add_event('created_at', timestamp: msg['created_at'])
|
36
36
|
span.add_event('enqueued_at', timestamp: msg['enqueued_at'])
|
@@ -39,7 +39,7 @@ module OpenTelemetry
|
|
39
39
|
else
|
40
40
|
links = []
|
41
41
|
span_context = OpenTelemetry::Trace.current_span(extracted_context).context
|
42
|
-
links << OpenTelemetry::Trace::Link.new(span_context) if
|
42
|
+
links << OpenTelemetry::Trace::Link.new(span_context) if instrumentation_config[:propagation_style] == :link && span_context.valid?
|
43
43
|
span = tracer.start_root_span(span_name, attributes: attributes, links: links, kind: :consumer)
|
44
44
|
OpenTelemetry::Trace.with_span(span) do
|
45
45
|
span.add_event('created_at', timestamp: msg['created_at'])
|
@@ -58,7 +58,7 @@ module OpenTelemetry
|
|
58
58
|
|
59
59
|
private
|
60
60
|
|
61
|
-
def
|
61
|
+
def instrumentation_config
|
62
62
|
Sidekiq::Instrumentation.instance.config
|
63
63
|
end
|
64
64
|
|
@@ -13,9 +13,9 @@ module OpenTelemetry
|
|
13
13
|
private
|
14
14
|
|
15
15
|
def ❤ # rubocop:disable Naming/MethodName
|
16
|
-
if
|
16
|
+
if instrumentation_config[:trace_launcher_heartbeat]
|
17
17
|
attributes = {}
|
18
|
-
attributes['peer.service'] =
|
18
|
+
attributes['peer.service'] = instrumentation_config[:peer_service] if instrumentation_config[:peer_service]
|
19
19
|
tracer.in_span('Sidekiq::Launcher#heartbeat', attributes: attributes) { super }
|
20
20
|
else
|
21
21
|
OpenTelemetry::Common::Utilities.untraced { super }
|
@@ -26,7 +26,7 @@ module OpenTelemetry
|
|
26
26
|
Sidekiq::Instrumentation.instance.tracer
|
27
27
|
end
|
28
28
|
|
29
|
-
def
|
29
|
+
def instrumentation_config
|
30
30
|
Sidekiq::Instrumentation.instance.config
|
31
31
|
end
|
32
32
|
end
|
@@ -11,9 +11,9 @@ module OpenTelemetry
|
|
11
11
|
# The Poller module contains instrumentation for the enqueue and wait methods
|
12
12
|
module Poller
|
13
13
|
def enqueue
|
14
|
-
if
|
14
|
+
if instrumentation_config[:trace_poller_enqueue]
|
15
15
|
attributes = {}
|
16
|
-
attributes['peer.service'] =
|
16
|
+
attributes['peer.service'] = instrumentation_config[:peer_service] if instrumentation_config[:peer_service]
|
17
17
|
tracer.in_span('Sidekiq::Scheduled::Poller#enqueue', attributes: attributes) { super }
|
18
18
|
else
|
19
19
|
OpenTelemetry::Common::Utilities.untraced { super }
|
@@ -23,7 +23,7 @@ module OpenTelemetry
|
|
23
23
|
private
|
24
24
|
|
25
25
|
def wait
|
26
|
-
if
|
26
|
+
if instrumentation_config[:trace_poller_wait]
|
27
27
|
tracer.in_span('Sidekiq::Scheduled::Poller#wait') { super }
|
28
28
|
else
|
29
29
|
OpenTelemetry::Common::Utilities.untraced { super }
|
@@ -34,7 +34,7 @@ module OpenTelemetry
|
|
34
34
|
Sidekiq::Instrumentation.instance.tracer
|
35
35
|
end
|
36
36
|
|
37
|
-
def
|
37
|
+
def instrumentation_config
|
38
38
|
Sidekiq::Instrumentation.instance.config
|
39
39
|
end
|
40
40
|
end
|
@@ -13,9 +13,9 @@ module OpenTelemetry
|
|
13
13
|
private
|
14
14
|
|
15
15
|
def process_one
|
16
|
-
if
|
16
|
+
if instrumentation_config[:trace_processor_process_one]
|
17
17
|
attributes = {}
|
18
|
-
attributes['peer.service'] =
|
18
|
+
attributes['peer.service'] = instrumentation_config[:peer_service] if instrumentation_config[:peer_service]
|
19
19
|
tracer.in_span('Sidekiq::Processor#process_one', attributes: attributes) { super }
|
20
20
|
else
|
21
21
|
OpenTelemetry::Common::Utilities.untraced { super }
|
@@ -26,7 +26,7 @@ module OpenTelemetry
|
|
26
26
|
Sidekiq::Instrumentation.instance.tracer
|
27
27
|
end
|
28
28
|
|
29
|
-
def
|
29
|
+
def instrumentation_config
|
30
30
|
Sidekiq::Instrumentation.instance.config
|
31
31
|
end
|
32
32
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: opentelemetry-instrumentation-sidekiq
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.21.
|
4
|
+
version: 0.21.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- OpenTelemetry Authors
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-
|
11
|
+
date: 2022-06-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: opentelemetry-api
|
@@ -44,14 +44,28 @@ dependencies:
|
|
44
44
|
requirements:
|
45
45
|
- - "~>"
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version: 0.
|
47
|
+
version: 0.21.0
|
48
48
|
type: :runtime
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
52
|
- - "~>"
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version: 0.
|
54
|
+
version: 0.21.0
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: activejob
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - ">="
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '5.2'
|
62
|
+
type: :development
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - ">="
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '5.2'
|
55
69
|
- !ruby/object:Gem::Dependency
|
56
70
|
name: appraisal
|
57
71
|
requirement: !ruby/object:Gem::Requirement
|
@@ -100,14 +114,28 @@ dependencies:
|
|
100
114
|
requirements:
|
101
115
|
- - "~>"
|
102
116
|
- !ruby/object:Gem::Version
|
103
|
-
version: '1.
|
117
|
+
version: '1.1'
|
104
118
|
type: :development
|
105
119
|
prerelease: false
|
106
120
|
version_requirements: !ruby/object:Gem::Requirement
|
107
121
|
requirements:
|
108
122
|
- - "~>"
|
109
123
|
- !ruby/object:Gem::Version
|
110
|
-
version: '1.
|
124
|
+
version: '1.1'
|
125
|
+
- !ruby/object:Gem::Dependency
|
126
|
+
name: opentelemetry-test-helpers
|
127
|
+
requirement: !ruby/object:Gem::Requirement
|
128
|
+
requirements:
|
129
|
+
- - ">="
|
130
|
+
- !ruby/object:Gem::Version
|
131
|
+
version: '0'
|
132
|
+
type: :development
|
133
|
+
prerelease: false
|
134
|
+
version_requirements: !ruby/object:Gem::Requirement
|
135
|
+
requirements:
|
136
|
+
- - ">="
|
137
|
+
- !ruby/object:Gem::Version
|
138
|
+
version: '0'
|
111
139
|
- !ruby/object:Gem::Dependency
|
112
140
|
name: rspec-mocks
|
113
141
|
requirement: !ruby/object:Gem::Requirement
|
@@ -217,10 +245,10 @@ homepage: https://github.com/open-telemetry/opentelemetry-ruby
|
|
217
245
|
licenses:
|
218
246
|
- Apache-2.0
|
219
247
|
metadata:
|
220
|
-
changelog_uri: https://open-telemetry.github.io/opentelemetry-ruby/opentelemetry-instrumentation-sidekiq/v0.21.
|
248
|
+
changelog_uri: https://open-telemetry.github.io/opentelemetry-ruby/opentelemetry-instrumentation-sidekiq/v0.21.1/file.CHANGELOG.html
|
221
249
|
source_code_uri: https://github.com/open-telemetry/opentelemetry-ruby/tree/main/instrumentation/sidekiq
|
222
250
|
bug_tracker_uri: https://github.com/open-telemetry/opentelemetry-ruby/issues
|
223
|
-
documentation_uri: https://open-telemetry.github.io/opentelemetry-ruby/opentelemetry-instrumentation-sidekiq/v0.21.
|
251
|
+
documentation_uri: https://open-telemetry.github.io/opentelemetry-ruby/opentelemetry-instrumentation-sidekiq/v0.21.1
|
224
252
|
post_install_message:
|
225
253
|
rdoc_options: []
|
226
254
|
require_paths:
|
@@ -229,7 +257,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
229
257
|
requirements:
|
230
258
|
- - ">="
|
231
259
|
- !ruby/object:Gem::Version
|
232
|
-
version: 2.
|
260
|
+
version: 2.6.0
|
233
261
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
234
262
|
requirements:
|
235
263
|
- - ">="
|