opentelemetry-instrumentation-graphql 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
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6933e85196eaf2f0f93f7c8d86e7713c0d56fecb2035eded886357c7c2d9579b
|
4
|
+
data.tar.gz: f6d5f32f7c34453c7effc96a97451c75ccefe259b3d1ff2ea89616fd09353902
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6e680d4a2f2e8d8b5c0dc9b011dd38fbb289b4c5c82af79b19ed5a4a415367fd8df8be013cfee0e69cca4d5b53a7066c2aeaa9063ef8b29798d58bb43792cf05
|
7
|
+
data.tar.gz: 925f99580cdf0eeaa21a5f9613df6d7a6722ae774a6284b7b31e93915829da959857741a8104d1573a649691af839e80bc8276bd3352e631830ce7a03007f810
|
data/CHANGELOG.md
CHANGED
@@ -11,6 +11,10 @@ module OpenTelemetry
|
|
11
11
|
module GraphQL
|
12
12
|
# The Instrumentation class contains logic to detect and install the GraphQL instrumentation
|
13
13
|
class Instrumentation < OpenTelemetry::Instrumentation::Base
|
14
|
+
compatible do
|
15
|
+
gem_version < Gem::Version.new('3.0.0')
|
16
|
+
end
|
17
|
+
|
14
18
|
install do |config|
|
15
19
|
require_dependencies
|
16
20
|
install_tracer(config)
|
@@ -41,6 +45,10 @@ module OpenTelemetry
|
|
41
45
|
|
42
46
|
private
|
43
47
|
|
48
|
+
def gem_version
|
49
|
+
Gem::Version.new(::GraphQL::VERSION)
|
50
|
+
end
|
51
|
+
|
44
52
|
def require_dependencies
|
45
53
|
require_relative 'tracers/graphql_tracer'
|
46
54
|
end
|
@@ -24,12 +24,12 @@ module OpenTelemetry
|
|
24
24
|
'execute_multiplex' => 'graphql.execute_multiplex'
|
25
25
|
}
|
26
26
|
|
27
|
-
def platform_trace(platform_key, key, data)
|
27
|
+
def platform_trace(platform_key, key, data) # rubocop:disable Metrics/CyclomaticComplexity
|
28
28
|
return yield if platform_key.nil?
|
29
29
|
|
30
30
|
tracer.in_span(platform_key, attributes: attributes_for(key, data)) do |span|
|
31
31
|
yield.tap do |response|
|
32
|
-
errors = response[:errors]&.compact&.map
|
32
|
+
errors = response[:errors]&.compact&.map(&:to_h)&.to_json if key == 'validate'
|
33
33
|
unless errors.nil?
|
34
34
|
span.add_event(
|
35
35
|
'graphql.validation.error',
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: opentelemetry-instrumentation-graphql
|
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:
|
11
|
+
date: 2023-01-14 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: opentelemetry-api
|
@@ -56,30 +56,36 @@ dependencies:
|
|
56
56
|
name: bundler
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
|
-
- - "
|
59
|
+
- - "~>"
|
60
60
|
- !ruby/object:Gem::Version
|
61
|
-
version: '
|
61
|
+
version: '2.4'
|
62
62
|
type: :development
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
|
-
- - "
|
66
|
+
- - "~>"
|
67
67
|
- !ruby/object:Gem::Version
|
68
|
-
version: '
|
68
|
+
version: '2.4'
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
70
|
name: graphql
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
72
72
|
requirements:
|
73
|
-
- - "
|
73
|
+
- - ">="
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: 1.9.0
|
76
|
+
- - "<"
|
74
77
|
- !ruby/object:Gem::Version
|
75
|
-
version:
|
78
|
+
version: 3.0.0
|
76
79
|
type: :development
|
77
80
|
prerelease: false
|
78
81
|
version_requirements: !ruby/object:Gem::Requirement
|
79
82
|
requirements:
|
80
|
-
- - "
|
83
|
+
- - ">="
|
84
|
+
- !ruby/object:Gem::Version
|
85
|
+
version: 1.9.0
|
86
|
+
- - "<"
|
81
87
|
- !ruby/object:Gem::Version
|
82
|
-
version:
|
88
|
+
version: 3.0.0
|
83
89
|
- !ruby/object:Gem::Dependency
|
84
90
|
name: minitest
|
85
91
|
requirement: !ruby/object:Gem::Requirement
|
@@ -128,28 +134,28 @@ dependencies:
|
|
128
134
|
requirements:
|
129
135
|
- - "~>"
|
130
136
|
- !ruby/object:Gem::Version
|
131
|
-
version:
|
137
|
+
version: '13.0'
|
132
138
|
type: :development
|
133
139
|
prerelease: false
|
134
140
|
version_requirements: !ruby/object:Gem::Requirement
|
135
141
|
requirements:
|
136
142
|
- - "~>"
|
137
143
|
- !ruby/object:Gem::Version
|
138
|
-
version:
|
144
|
+
version: '13.0'
|
139
145
|
- !ruby/object:Gem::Dependency
|
140
146
|
name: rubocop
|
141
147
|
requirement: !ruby/object:Gem::Requirement
|
142
148
|
requirements:
|
143
149
|
- - "~>"
|
144
150
|
- !ruby/object:Gem::Version
|
145
|
-
version:
|
151
|
+
version: 1.41.1
|
146
152
|
type: :development
|
147
153
|
prerelease: false
|
148
154
|
version_requirements: !ruby/object:Gem::Requirement
|
149
155
|
requirements:
|
150
156
|
- - "~>"
|
151
157
|
- !ruby/object:Gem::Version
|
152
|
-
version:
|
158
|
+
version: 1.41.1
|
153
159
|
- !ruby/object:Gem::Dependency
|
154
160
|
name: simplecov
|
155
161
|
requirement: !ruby/object:Gem::Requirement
|
@@ -223,14 +229,14 @@ files:
|
|
223
229
|
- lib/opentelemetry/instrumentation/graphql/instrumentation.rb
|
224
230
|
- lib/opentelemetry/instrumentation/graphql/tracers/graphql_tracer.rb
|
225
231
|
- lib/opentelemetry/instrumentation/graphql/version.rb
|
226
|
-
homepage: https://github.com/open-telemetry/opentelemetry-contrib
|
232
|
+
homepage: https://github.com/open-telemetry/opentelemetry-ruby-contrib
|
227
233
|
licenses:
|
228
234
|
- Apache-2.0
|
229
235
|
metadata:
|
230
|
-
changelog_uri: https://
|
236
|
+
changelog_uri: https://rubydoc.info/gems/opentelemetry-instrumentation-graphql/0.21.1/file/CHANGELOG.md
|
231
237
|
source_code_uri: https://github.com/open-telemetry/opentelemetry-ruby-contrib/tree/main/instrumentation/graphql
|
232
238
|
bug_tracker_uri: https://github.com/open-telemetry/opentelemetry-ruby-contrib/issues
|
233
|
-
documentation_uri: https://
|
239
|
+
documentation_uri: https://rubydoc.info/gems/opentelemetry-instrumentation-graphql/0.21.1
|
234
240
|
post_install_message:
|
235
241
|
rdoc_options: []
|
236
242
|
require_paths:
|