opentelemetry-instrumentation-faraday 0.24.0 → 0.24.1
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 15923320510f923bdbefc0418d6e6de804a99280bb636cbb9b7877c4f43e93cb
|
4
|
+
data.tar.gz: b743cbca0b24b41a9570b1c0004308f3b4a6468ef3df914520605d1562794e82
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d6f105c1c18aa9d054e954d5de52eb9f52c350165ea1da5140cfb95d1ecc8f4524f4b0b1547994699416744a9fabdb65ee2d923d8011ad14be0ea4803a2a5320
|
7
|
+
data.tar.gz: 4b8902dfbc24d5c8c61839f13ffe129ea0b6a286377a5c603fcc8a94ac9fc2adcba58e69ed4277661b89c92c4ab0ce3dda3c775d42a0d96467352c2e5256607e
|
data/CHANGELOG.md
CHANGED
@@ -35,7 +35,11 @@ module OpenTelemetry
|
|
35
35
|
) do |span|
|
36
36
|
OpenTelemetry.propagation.inject(env.request_headers)
|
37
37
|
|
38
|
-
app.call(env).on_complete { |resp| trace_response(span, resp) }
|
38
|
+
app.call(env).on_complete { |resp| trace_response(span, resp.status) }
|
39
|
+
rescue ::Faraday::Error => e
|
40
|
+
trace_response(span, e.response[:status]) if e.response
|
41
|
+
|
42
|
+
raise
|
39
43
|
end
|
40
44
|
end
|
41
45
|
|
@@ -62,9 +66,9 @@ module OpenTelemetry
|
|
62
66
|
Faraday::Instrumentation.instance.tracer
|
63
67
|
end
|
64
68
|
|
65
|
-
def trace_response(span,
|
66
|
-
span.set_attribute('http.status_code',
|
67
|
-
span.status = OpenTelemetry::Trace::Status.error unless (100..399).cover?(
|
69
|
+
def trace_response(span, status)
|
70
|
+
span.set_attribute('http.status_code', status)
|
71
|
+
span.status = OpenTelemetry::Trace::Status.error unless (100..399).cover?(status.to_i)
|
68
72
|
end
|
69
73
|
end
|
70
74
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: opentelemetry-instrumentation-faraday
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.24.
|
4
|
+
version: 0.24.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: 2024-
|
11
|
+
date: 2024-03-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: opentelemetry-api
|
@@ -228,10 +228,10 @@ homepage: https://github.com/open-telemetry/opentelemetry-ruby-contrib
|
|
228
228
|
licenses:
|
229
229
|
- Apache-2.0
|
230
230
|
metadata:
|
231
|
-
changelog_uri: https://rubydoc.info/gems/opentelemetry-instrumentation-faraday/0.24.
|
231
|
+
changelog_uri: https://rubydoc.info/gems/opentelemetry-instrumentation-faraday/0.24.1/file/CHANGELOG.md
|
232
232
|
source_code_uri: https://github.com/open-telemetry/opentelemetry-ruby-contrib/tree/main/instrumentation/faraday
|
233
233
|
bug_tracker_uri: https://github.com/open-telemetry/opentelemetry-ruby-contrib/issues
|
234
|
-
documentation_uri: https://rubydoc.info/gems/opentelemetry-instrumentation-faraday/0.24.
|
234
|
+
documentation_uri: https://rubydoc.info/gems/opentelemetry-instrumentation-faraday/0.24.1
|
235
235
|
post_install_message:
|
236
236
|
rdoc_options: []
|
237
237
|
require_paths:
|