graphql 2.3.3 → 2.3.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/generators/graphql/install/mutation_root_generator.rb +2 -2
- data/lib/graphql/analysis/ast/query_complexity.rb +1 -1
- data/lib/graphql/dataloader/async_dataloader.rb +1 -0
- data/lib/graphql/dataloader/null_dataloader.rb +1 -1
- data/lib/graphql/dataloader.rb +6 -3
- data/lib/graphql/execution/interpreter/runtime/graphql_result.rb +7 -4
- data/lib/graphql/execution/interpreter/runtime.rb +52 -63
- data/lib/graphql/execution/interpreter.rb +1 -1
- data/lib/graphql/language/nodes.rb +60 -26
- data/lib/graphql/language/parser.rb +56 -15
- data/lib/graphql/query.rb +2 -2
- data/lib/graphql/rubocop/graphql/base_cop.rb +1 -1
- data/lib/graphql/schema/addition.rb +21 -11
- data/lib/graphql/schema/has_single_input_argument.rb +1 -0
- data/lib/graphql/schema/input_object.rb +1 -0
- data/lib/graphql/schema/introspection_system.rb +2 -2
- data/lib/graphql/schema/late_bound_type.rb +4 -0
- data/lib/graphql/schema/list.rb +2 -2
- data/lib/graphql/schema/member/has_arguments.rb +2 -35
- data/lib/graphql/schema/member/has_directives.rb +1 -1
- data/lib/graphql/schema/member/relay_shortcuts.rb +1 -1
- data/lib/graphql/schema/member/type_system_helpers.rb +1 -2
- data/lib/graphql/schema/warden.rb +2 -3
- data/lib/graphql/schema.rb +20 -20
- data/lib/graphql/static_validation/rules/fields_will_merge.rb +1 -1
- data/lib/graphql/subscriptions/action_cable_subscriptions.rb +1 -1
- data/lib/graphql/tracing/prometheus_trace.rb +8 -8
- data/lib/graphql/tracing/sentry_trace.rb +10 -10
- data/lib/graphql/type_kinds.rb +1 -1
- data/lib/graphql/version.rb +1 -1
- data/lib/graphql.rb +0 -8
- metadata +2 -2
@@ -12,7 +12,7 @@ module GraphQL
|
|
12
12
|
@set_transaction_name = set_transaction_name
|
13
13
|
super
|
14
14
|
end
|
15
|
-
|
15
|
+
|
16
16
|
def execute_query(**data)
|
17
17
|
set_this_txn_name = data[:query].context[:set_sentry_transaction_name]
|
18
18
|
if set_this_txn_name == true || (set_this_txn_name.nil? && @set_transaction_name)
|
@@ -20,7 +20,7 @@ module GraphQL
|
|
20
20
|
scope.set_transaction_name(transaction_name(data[:query]))
|
21
21
|
end
|
22
22
|
end
|
23
|
-
|
23
|
+
instrument_sentry_execution("graphql.execute", "execute_query", data) { super }
|
24
24
|
end
|
25
25
|
|
26
26
|
{
|
@@ -34,33 +34,33 @@ module GraphQL
|
|
34
34
|
}.each do |trace_method, platform_key|
|
35
35
|
module_eval <<-RUBY, __FILE__, __LINE__
|
36
36
|
def #{trace_method}(**data)
|
37
|
-
|
37
|
+
instrument_sentry_execution("#{platform_key}", "#{trace_method}", data) { super }
|
38
38
|
end
|
39
39
|
RUBY
|
40
40
|
end
|
41
41
|
|
42
42
|
def platform_execute_field(platform_key, &block)
|
43
|
-
|
43
|
+
instrument_sentry_execution(platform_key, "execute_field", &block)
|
44
44
|
end
|
45
45
|
|
46
46
|
def platform_execute_field_lazy(platform_key, &block)
|
47
|
-
|
47
|
+
instrument_sentry_execution(platform_key, "execute_field_lazy", &block)
|
48
48
|
end
|
49
49
|
|
50
50
|
def platform_authorized(platform_key, &block)
|
51
|
-
|
51
|
+
instrument_sentry_execution(platform_key, "authorized", &block)
|
52
52
|
end
|
53
53
|
|
54
54
|
def platform_authorized_lazy(platform_key, &block)
|
55
|
-
|
55
|
+
instrument_sentry_execution(platform_key, "authorized_lazy", &block)
|
56
56
|
end
|
57
57
|
|
58
58
|
def platform_resolve_type(platform_key, &block)
|
59
|
-
|
59
|
+
instrument_sentry_execution(platform_key, "resolve_type", &block)
|
60
60
|
end
|
61
61
|
|
62
62
|
def platform_resolve_type_lazy(platform_key, &block)
|
63
|
-
|
63
|
+
instrument_sentry_execution(platform_key, "resolve_type_lazy", &block)
|
64
64
|
end
|
65
65
|
|
66
66
|
def platform_field_key(field)
|
@@ -77,7 +77,7 @@ module GraphQL
|
|
77
77
|
|
78
78
|
private
|
79
79
|
|
80
|
-
def
|
80
|
+
def instrument_sentry_execution(platform_key, trace_method, data=nil, &block)
|
81
81
|
return yield unless Sentry.initialized?
|
82
82
|
|
83
83
|
Sentry.with_child_span(op: platform_key, start_timestamp: Sentry.utc_now.to_f) do |span|
|
data/lib/graphql/type_kinds.rb
CHANGED
@@ -16,7 +16,7 @@ module GraphQL
|
|
16
16
|
@description = description
|
17
17
|
end
|
18
18
|
|
19
|
-
# Does this TypeKind have multiple possible
|
19
|
+
# Does this TypeKind have multiple possible implementers?
|
20
20
|
# @deprecated Use `abstract?` instead of `resolves?`.
|
21
21
|
def resolves?; @abstract; end
|
22
22
|
# Is this TypeKind abstract?
|
data/lib/graphql/version.rb
CHANGED
data/lib/graphql.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: graphql
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.3.
|
4
|
+
version: 2.3.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Robert Mosolgo
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-06-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: base64
|