opentelemetry-instrumentation-excon 0.13.0 → 0.18.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +33 -8
- data/README.md +2 -2
- data/lib/opentelemetry/instrumentation/excon.rb +1 -0
- data/lib/opentelemetry/instrumentation/excon/instrumentation.rb +2 -0
- data/lib/opentelemetry/instrumentation/excon/middlewares/tracer_middleware.rb +18 -10
- data/lib/opentelemetry/instrumentation/excon/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: 34dbb6b694ac101b0bd1e7930071cc32d83a5b7a381aa427c28b4d47e3ce6928
|
4
|
+
data.tar.gz: 94428a2dbaef75de4db8e8a02a5d5665a24dadff892d669efe5bd644e957f877
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2f1109aeef1b71f319e4a5a4d3e4fb19822ea059aaeb4d864ee7e33f53c92e84a189f2b472fe897e1ec3153a72f2e732287846bb8f9ddbf4cb4a2421e55e7606
|
7
|
+
data.tar.gz: b2238516cbc2daf5d462183a34d8170b829cced1e3c828f4fc26f4aa38b60cf3156cffa5b9a810f717e9838c9333a6311e3c38cb948334a63b18cc8e4ffcf3ee
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,30 @@
|
|
1
1
|
# Release History: opentelemetry-instrumentation-excon
|
2
2
|
|
3
|
+
### v0.18.0 / 2021-05-21
|
4
|
+
|
5
|
+
* ADDED: Updated API depedency for 1.0.0.rc1
|
6
|
+
* FIXED: Removed http.status_text attribute #750
|
7
|
+
|
8
|
+
### v0.17.0 / 2021-04-22
|
9
|
+
|
10
|
+
* ADDED: Excon instrumentation accepts peer service config attribute.
|
11
|
+
* FIXED: Refactor propagators to add #fields
|
12
|
+
|
13
|
+
### v0.16.0 / 2021-03-17
|
14
|
+
|
15
|
+
* FIXED: Example scripts now reference local common lib
|
16
|
+
* DOCS: Replace Gitter with GitHub Discussions
|
17
|
+
|
18
|
+
### v0.15.0 / 2021-02-18
|
19
|
+
|
20
|
+
* (No significant changes)
|
21
|
+
|
22
|
+
### v0.14.0 / 2021-02-03
|
23
|
+
|
24
|
+
* BREAKING CHANGE: Replace getter and setter callables and remove rack specific propagators
|
25
|
+
|
26
|
+
* ADDED: Replace getter and setter callables and remove rack specific propagators
|
27
|
+
|
3
28
|
### v0.13.0 / 2021-01-29
|
4
29
|
|
5
30
|
* (No significant changes)
|
@@ -10,7 +35,7 @@
|
|
10
35
|
|
11
36
|
### v0.11.0 / 2020-12-11
|
12
37
|
|
13
|
-
* FIXED: Copyright comments to not reference year
|
38
|
+
* FIXED: Copyright comments to not reference year
|
14
39
|
|
15
40
|
### v0.10.0 / 2020-12-03
|
16
41
|
|
@@ -18,21 +43,21 @@
|
|
18
43
|
|
19
44
|
### v0.9.0 / 2020-11-27
|
20
45
|
|
21
|
-
* BREAKING CHANGE: Add timeout for force_flush and shutdown
|
46
|
+
* BREAKING CHANGE: Add timeout for force_flush and shutdown
|
22
47
|
|
23
|
-
* ADDED: Add timeout for force_flush and shutdown
|
48
|
+
* ADDED: Add timeout for force_flush and shutdown
|
24
49
|
|
25
50
|
### v0.8.0 / 2020-10-27
|
26
51
|
|
27
|
-
* BREAKING CHANGE: Move context/span methods to Trace module
|
28
|
-
* BREAKING CHANGE: Remove 'canonical' from status codes
|
52
|
+
* BREAKING CHANGE: Move context/span methods to Trace module
|
53
|
+
* BREAKING CHANGE: Remove 'canonical' from status codes
|
29
54
|
|
30
|
-
* FIXED: Move context/span methods to Trace module
|
31
|
-
* FIXED: Remove 'canonical' from status codes
|
55
|
+
* FIXED: Move context/span methods to Trace module
|
56
|
+
* FIXED: Remove 'canonical' from status codes
|
32
57
|
|
33
58
|
### v0.7.0 / 2020-10-07
|
34
59
|
|
35
|
-
* DOCS: Standardize toplevel docs structure and readme
|
60
|
+
* DOCS: Standardize toplevel docs structure and readme
|
36
61
|
|
37
62
|
### v0.6.0 / 2020-09-10
|
38
63
|
|
data/README.md
CHANGED
@@ -35,7 +35,7 @@ end
|
|
35
35
|
|
36
36
|
The `opentelemetry-instrumentation-excon` gem source is [on github][repo-github], along with related gems including `opentelemetry-api` and `opentelemetry-sdk`.
|
37
37
|
|
38
|
-
The OpenTelemetry Ruby gems are maintained by the OpenTelemetry-Ruby special interest group (SIG). You can get involved by joining us
|
38
|
+
The OpenTelemetry Ruby gems are maintained by the OpenTelemetry-Ruby special interest group (SIG). You can get involved by joining us in [GitHub Discussions][discussions-url] or attending our weekly meeting. See the [meeting calendar][community-meetings] for dates and times. For more information on this and other language SIGs, see the OpenTelemetry [community page][ruby-sig].
|
39
39
|
|
40
40
|
## License
|
41
41
|
|
@@ -47,4 +47,4 @@ The `opentelemetry-instrumentation-all` gem is distributed under the Apache 2.0
|
|
47
47
|
[license-github]: https://github.com/open-telemetry/opentelemetry-ruby/blob/main/LICENSE
|
48
48
|
[ruby-sig]: https://github.com/open-telemetry/community#ruby-sig
|
49
49
|
[community-meetings]: https://github.com/open-telemetry/community#community-meetings
|
50
|
-
[
|
50
|
+
[discussions-url]: https://github.com/open-telemetry/opentelemetry-ruby/discussions
|
@@ -22,24 +22,19 @@ module OpenTelemetry
|
|
22
22
|
trace: 'TRACE'
|
23
23
|
}.freeze
|
24
24
|
|
25
|
-
def request_call(datum)
|
25
|
+
def request_call(datum)
|
26
26
|
begin
|
27
27
|
unless datum.key?(:otel_span)
|
28
28
|
http_method = HTTP_METHODS_SYMBOL_TO_STRING[datum[:method]]
|
29
|
-
|
29
|
+
attributes = span_creation_attributes(datum, http_method)
|
30
30
|
tracer.start_span(
|
31
31
|
"HTTP #{http_method}",
|
32
|
-
attributes:
|
33
|
-
'http.host' => datum[:host],
|
34
|
-
'http.method' => http_method,
|
35
|
-
'http.scheme' => datum[:scheme],
|
36
|
-
'http.target' => datum[:path]
|
37
|
-
},
|
32
|
+
attributes: attributes,
|
38
33
|
kind: :client
|
39
34
|
).tap do |span|
|
40
35
|
datum[:otel_span] = span
|
41
36
|
OpenTelemetry::Trace.with_span(span) do
|
42
|
-
OpenTelemetry.propagation.
|
37
|
+
OpenTelemetry.propagation.inject(datum[:headers])
|
43
38
|
end
|
44
39
|
end
|
45
40
|
end
|
@@ -84,7 +79,6 @@ module OpenTelemetry
|
|
84
79
|
if datum.key?(:response)
|
85
80
|
response = datum[:response]
|
86
81
|
span.set_attribute('http.status_code', response[:status])
|
87
|
-
span.set_attribute('http.status_text', response[:reason_phrase])
|
88
82
|
span.status = OpenTelemetry::Trace::Status.http_to_status(
|
89
83
|
response[:status]
|
90
84
|
)
|
@@ -105,6 +99,20 @@ module OpenTelemetry
|
|
105
99
|
OpenTelemetry.logger.debug(e.message)
|
106
100
|
end
|
107
101
|
|
102
|
+
def span_creation_attributes(datum, http_method)
|
103
|
+
instrumentation_attrs = {
|
104
|
+
'http.host' => datum[:host],
|
105
|
+
'http.method' => http_method,
|
106
|
+
'http.scheme' => datum[:scheme],
|
107
|
+
'http.target' => datum[:path]
|
108
|
+
}
|
109
|
+
config = Excon::Instrumentation.instance.config
|
110
|
+
instrumentation_attrs['peer.service'] = config[:peer_service] if config[:peer_service]
|
111
|
+
instrumentation_attrs.merge(
|
112
|
+
OpenTelemetry::Common::HTTP::ClientContext.attributes
|
113
|
+
)
|
114
|
+
end
|
115
|
+
|
108
116
|
def tracer
|
109
117
|
Excon::Instrumentation.instance.tracer
|
110
118
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: opentelemetry-instrumentation-excon
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.18.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- OpenTelemetry Authors
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-05-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: opentelemetry-api
|
@@ -16,14 +16,42 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 0.
|
19
|
+
version: 1.0.0.rc1
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: 0.
|
26
|
+
version: 1.0.0.rc1
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: opentelemetry-common
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: 0.18.0
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: 0.18.0
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: opentelemetry-instrumentation-base
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - "~>"
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: 0.18.0
|
48
|
+
type: :runtime
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - "~>"
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: 0.18.0
|
27
55
|
- !ruby/object:Gem::Dependency
|
28
56
|
name: appraisal
|
29
57
|
requirement: !ruby/object:Gem::Requirement
|
@@ -86,14 +114,14 @@ dependencies:
|
|
86
114
|
requirements:
|
87
115
|
- - "~>"
|
88
116
|
- !ruby/object:Gem::Version
|
89
|
-
version:
|
117
|
+
version: 1.0.0.rc1
|
90
118
|
type: :development
|
91
119
|
prerelease: false
|
92
120
|
version_requirements: !ruby/object:Gem::Requirement
|
93
121
|
requirements:
|
94
122
|
- - "~>"
|
95
123
|
- !ruby/object:Gem::Version
|
96
|
-
version:
|
124
|
+
version: 1.0.0.rc1
|
97
125
|
- !ruby/object:Gem::Dependency
|
98
126
|
name: rubocop
|
99
127
|
requirement: !ruby/object:Gem::Requirement
|
@@ -185,10 +213,10 @@ homepage: https://github.com/open-telemetry/opentelemetry-ruby
|
|
185
213
|
licenses:
|
186
214
|
- Apache-2.0
|
187
215
|
metadata:
|
188
|
-
changelog_uri: https://open-telemetry.github.io/opentelemetry-ruby/opentelemetry-instrumentation-excon/v0.
|
216
|
+
changelog_uri: https://open-telemetry.github.io/opentelemetry-ruby/opentelemetry-instrumentation-excon/v0.18.0/file.CHANGELOG.html
|
189
217
|
source_code_uri: https://github.com/open-telemetry/opentelemetry-ruby/tree/main/instrumentation/excon
|
190
218
|
bug_tracker_uri: https://github.com/open-telemetry/opentelemetry-ruby/issues
|
191
|
-
documentation_uri: https://open-telemetry.github.io/opentelemetry-ruby/opentelemetry-instrumentation-excon/v0.
|
219
|
+
documentation_uri: https://open-telemetry.github.io/opentelemetry-ruby/opentelemetry-instrumentation-excon/v0.18.0
|
192
220
|
post_install_message:
|
193
221
|
rdoc_options: []
|
194
222
|
require_paths:
|
@@ -204,7 +232,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
204
232
|
- !ruby/object:Gem::Version
|
205
233
|
version: '0'
|
206
234
|
requirements: []
|
207
|
-
rubygems_version: 3.1.
|
235
|
+
rubygems_version: 3.1.6
|
208
236
|
signing_key:
|
209
237
|
specification_version: 4
|
210
238
|
summary: Excon instrumentation for the OpenTelemetry framework
|