graphql_rails 0.6.0 → 1.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (87) hide show
  1. checksums.yaml +4 -4
  2. data/.hound.yml +1 -0
  3. data/.rubocop.yml +3 -3
  4. data/.ruby-version +1 -1
  5. data/.travis.yml +2 -2
  6. data/CHANGELOG.md +38 -0
  7. data/Gemfile +3 -2
  8. data/Gemfile.lock +181 -71
  9. data/docs/README.md +48 -9
  10. data/docs/_sidebar.md +5 -0
  11. data/docs/components/controller.md +294 -8
  12. data/docs/components/decorator.md +69 -0
  13. data/docs/components/model.md +349 -11
  14. data/docs/components/routes.md +43 -1
  15. data/docs/getting_started/quick_start.md +9 -2
  16. data/docs/index.html +1 -1
  17. data/docs/logging_and_monitoring/logging_and_monitoring.md +35 -0
  18. data/docs/other_tools/query_runner.md +49 -0
  19. data/docs/other_tools/schema_dump.md +29 -0
  20. data/docs/testing/testing.md +3 -1
  21. data/graphql_rails.gemspec +5 -4
  22. data/lib/generators/graphql_rails/install_generator.rb +50 -0
  23. data/lib/generators/graphql_rails/templates/example_users_controller.erb +19 -0
  24. data/lib/generators/graphql_rails/templates/graphql_application_controller.erb +8 -0
  25. data/lib/generators/graphql_rails/templates/graphql_controller.erb +20 -0
  26. data/lib/generators/graphql_rails/templates/graphql_router.erb +19 -0
  27. data/lib/generators/graphql_rails/templates/graphql_router_spec.erb +21 -0
  28. data/lib/graphql_rails.rb +7 -1
  29. data/lib/graphql_rails/attributes.rb +13 -0
  30. data/lib/graphql_rails/{attribute → attributes}/attributable.rb +25 -20
  31. data/lib/graphql_rails/attributes/attribute.rb +94 -0
  32. data/lib/graphql_rails/{attribute → attributes}/attribute_name_parser.rb +2 -2
  33. data/lib/graphql_rails/attributes/input_attribute.rb +65 -0
  34. data/lib/graphql_rails/attributes/input_type_parser.rb +62 -0
  35. data/lib/graphql_rails/attributes/type_name_info.rb +38 -0
  36. data/lib/graphql_rails/attributes/type_parseable.rb +128 -0
  37. data/lib/graphql_rails/attributes/type_parser.rb +121 -0
  38. data/lib/graphql_rails/concerns/service.rb +19 -0
  39. data/lib/graphql_rails/controller.rb +42 -21
  40. data/lib/graphql_rails/controller/action.rb +12 -67
  41. data/lib/graphql_rails/controller/action_configuration.rb +71 -31
  42. data/lib/graphql_rails/controller/build_controller_action_resolver.rb +52 -0
  43. data/lib/graphql_rails/controller/build_controller_action_resolver/controller_action_resolver.rb +28 -0
  44. data/lib/graphql_rails/controller/configuration.rb +56 -4
  45. data/lib/graphql_rails/controller/log_controller_action.rb +71 -0
  46. data/lib/graphql_rails/controller/request.rb +29 -8
  47. data/lib/graphql_rails/controller/request/format_errors.rb +58 -0
  48. data/lib/graphql_rails/decorator.rb +41 -0
  49. data/lib/graphql_rails/decorator/relation_decorator.rb +75 -0
  50. data/lib/graphql_rails/errors/custom_execution_error.rb +22 -0
  51. data/lib/graphql_rails/errors/execution_error.rb +8 -7
  52. data/lib/graphql_rails/errors/system_error.rb +14 -0
  53. data/lib/graphql_rails/errors/validation_error.rb +1 -5
  54. data/lib/graphql_rails/input_configurable.rb +47 -0
  55. data/lib/graphql_rails/integrations.rb +19 -0
  56. data/lib/graphql_rails/integrations/lograge.rb +39 -0
  57. data/lib/graphql_rails/integrations/sentry.rb +34 -0
  58. data/lib/graphql_rails/model.rb +26 -4
  59. data/lib/graphql_rails/model/add_fields_to_graphql_type.rb +45 -0
  60. data/lib/graphql_rails/model/build_connection_type.rb +52 -0
  61. data/lib/graphql_rails/model/{configuration → build_connection_type}/count_items.rb +5 -5
  62. data/lib/graphql_rails/model/build_enum_type.rb +68 -0
  63. data/lib/graphql_rails/model/{graphql_input_type_builder.rb → build_graphql_input_type.rb} +10 -2
  64. data/lib/graphql_rails/model/call_graphql_model_method.rb +72 -0
  65. data/lib/graphql_rails/model/configurable.rb +6 -2
  66. data/lib/graphql_rails/model/configuration.rb +34 -19
  67. data/lib/graphql_rails/model/find_or_build_graphql_type.rb +64 -0
  68. data/lib/graphql_rails/model/find_or_build_graphql_type_class.rb +46 -0
  69. data/lib/graphql_rails/model/input.rb +25 -11
  70. data/lib/graphql_rails/query_runner.rb +68 -0
  71. data/lib/graphql_rails/railtie.rb +10 -0
  72. data/lib/graphql_rails/router.rb +40 -13
  73. data/lib/graphql_rails/router/resource_routes_builder.rb +19 -11
  74. data/lib/graphql_rails/router/route.rb +21 -6
  75. data/lib/graphql_rails/router/schema_builder.rb +36 -11
  76. data/lib/graphql_rails/rspec_controller_helpers.rb +6 -4
  77. data/lib/graphql_rails/tasks/dump_graphql_schema.rb +57 -0
  78. data/lib/graphql_rails/tasks/schema.rake +14 -0
  79. data/lib/graphql_rails/version.rb +1 -1
  80. metadata +78 -26
  81. data/README.md +0 -194
  82. data/lib/graphql_rails/attribute.rb +0 -28
  83. data/lib/graphql_rails/attribute/type_parser.rb +0 -115
  84. data/lib/graphql_rails/controller/controller_function.rb +0 -50
  85. data/lib/graphql_rails/controller/format_results.rb +0 -36
  86. data/lib/graphql_rails/model/graphql_type_builder.rb +0 -33
  87. data/lib/graphql_rails/model/input_attribute.rb +0 -47
@@ -11,32 +11,39 @@ module GraphqlRails
11
11
  # graphql router that mimics Rails.application.routes
12
12
  class Router
13
13
  RAW_ACTION_NAMES = %i[
14
- rescue_from query_analyzer instrument cursor_encoder default_max_page_size
14
+ use rescue_from query_analyzer instrument cursor_encoder default_max_page_size
15
15
  ].freeze
16
16
 
17
17
  def self.draw(&block)
18
- router = new
19
- router.instance_eval(&block)
20
- router.graphql_schema
18
+ new.tap do |router|
19
+ router.instance_eval(&block)
20
+ end
21
21
  end
22
22
 
23
23
  attr_reader :routes, :namespace_name, :raw_graphql_actions
24
24
 
25
- def initialize(module_name: '')
25
+ def initialize(module_name: '', group_names: [])
26
26
  @module_name = module_name
27
+ @group_names = group_names
27
28
  @routes ||= Set.new
28
29
  @raw_graphql_actions ||= []
29
30
  end
30
31
 
32
+ def group(*group_names, &block)
33
+ scoped_router = router_with(group_names: group_names)
34
+ scoped_router.instance_eval(&block)
35
+ routes.merge(scoped_router.routes)
36
+ end
37
+
31
38
  def scope(**options, &block)
32
39
  full_module_name = [module_name, options[:module]].reject(&:empty?).join('/')
33
- scoped_router = self.class.new(module_name: full_module_name)
40
+ scoped_router = router_with(module_name: full_module_name)
34
41
  scoped_router.instance_eval(&block)
35
42
  routes.merge(scoped_router.routes)
36
43
  end
37
44
 
38
45
  def resources(name, **options, &block)
39
- builder_options = default_route_options.merge(options)
46
+ builder_options = full_route_options(options)
40
47
  routes_builder = ResourceRoutesBuilder.new(name, **builder_options)
41
48
  routes_builder.instance_eval(&block) if block
42
49
  routes.merge(routes_builder.routes)
@@ -56,25 +63,45 @@ module GraphqlRails
56
63
  end
57
64
  end
58
65
 
59
- def graphql_schema
60
- SchemaBuilder.new(
66
+ def graphql_schema(group = nil)
67
+ @graphql_schema ||= {}
68
+ @graphql_schema[group&.to_sym] ||= SchemaBuilder.new(
61
69
  queries: routes.select(&:query?),
62
70
  mutations: routes.select(&:mutation?),
63
- raw_actions: raw_graphql_actions
71
+ raw_actions: raw_graphql_actions,
72
+ group: group
64
73
  ).call
65
74
  end
66
75
 
76
+ def reload_schema
77
+ @graphql_schema = nil
78
+ end
79
+
67
80
  private
68
81
 
69
- attr_reader :module_name
82
+ attr_reader :module_name, :group_names
83
+
84
+ def router_with(new_router_options = {})
85
+ default_options = { module_name: module_name, group_names: group_names }
86
+ full_options = default_options.merge(new_router_options)
87
+
88
+ self.class.new(**full_options)
89
+ end
70
90
 
71
91
  def add_raw_action(name, *args, &block)
72
92
  raw_graphql_actions << { name: name, args: args, block: block }
73
93
  end
74
94
 
75
95
  def build_route(route_builder, name, **options)
76
- route_options = default_route_options.merge(options)
77
- route_builder.new(name, route_options)
96
+ route_builder.new(name, **full_route_options(options))
97
+ end
98
+
99
+ def full_route_options(extra_options)
100
+ extra_groups = Array(extra_options[:group]) + Array(extra_options[:groups])
101
+ extra_options = extra_options.except(:group, :groups)
102
+ groups = (group_names + extra_groups).uniq
103
+
104
+ default_route_options.merge(extra_options).merge(groups: groups)
78
105
  end
79
106
 
80
107
  def default_route_options
@@ -20,12 +20,12 @@ module GraphqlRails
20
20
  @routes ||= initial_routes
21
21
  end
22
22
 
23
- def query(*args)
24
- routes << build_query(*args)
23
+ def query(*args, **kwargs)
24
+ routes << build_query(*args, **kwargs)
25
25
  end
26
26
 
27
- def mutation(*args)
28
- routes << build_mutation(*args)
27
+ def mutation(*args, **kwargs)
28
+ routes << build_mutation(*args, **kwargs)
29
29
  end
30
30
 
31
31
  private
@@ -54,19 +54,27 @@ module GraphqlRails
54
54
  routes
55
55
  end
56
56
 
57
- def build_mutation(*args)
58
- build_route(MutationRoute, *args)
57
+ def build_mutation(*args, **kwargs)
58
+ build_route(MutationRoute, *args, **kwargs)
59
59
  end
60
60
 
61
- def build_query(*args)
62
- build_route(QueryRoute, *args)
61
+ def build_query(*args, **kwargs)
62
+ build_route(QueryRoute, *args, **kwargs)
63
63
  end
64
64
 
65
- def build_route(builder, action, prefix: action, on: :member, **custom_options)
65
+ # rubocop:disable Metrics/ParameterLists
66
+ def build_route(builder, action, prefix: action, suffix: false, on: :member, **custom_options)
67
+ if suffix == true
68
+ suffix_name = action
69
+ prefix = ''
70
+ end
71
+
66
72
  action_options = options.merge(custom_options).merge(on: on)
67
- action_name = [prefix, resource_name(on)].reject(&:empty?).join('_')
68
- builder.new(action_name, to: "#{name}##{action}", **action_options)
73
+ controller_method_name = action.to_s.underscore
74
+ action_name = [prefix, resource_name(on), suffix_name].map(&:to_s).reject(&:empty?).join('_')
75
+ builder.new(action_name, to: "#{name}##{controller_method_name}", **action_options)
69
76
  end
77
+ # rubocop:enable Metrics/ParameterLists
70
78
 
71
79
  def initial_action_names(only, except, available)
72
80
  alowed_routes = Array(only || available) & available
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- require_relative '../controller/controller_function'
3
+ require_relative '../controller/build_controller_action_resolver'
4
4
 
5
5
  module GraphqlRails
6
6
  class Router
@@ -8,10 +8,11 @@ module GraphqlRails
8
8
  class Route
9
9
  attr_reader :name, :module_name, :on, :relative_path
10
10
 
11
- def initialize(name, to: '', on:, **options)
11
+ def initialize(name, to: '', on:, groups: nil, **options)
12
12
  @name = name.to_s.camelize(:lower)
13
13
  @module_name = options[:module].to_s
14
14
  @function = options[:function]
15
+ @groups = groups
15
16
  @relative_path = to
16
17
  @on = on.to_sym
17
18
  end
@@ -26,12 +27,26 @@ module GraphqlRails
26
27
  on == :collection
27
28
  end
28
29
 
29
- def member?
30
- on == :member
30
+ def show_in_group?(group_name)
31
+ return true if groups.nil? || groups.empty?
32
+
33
+ groups.include?(group_name&.to_sym)
34
+ end
35
+
36
+ def field_options
37
+ if function
38
+ { function: function }
39
+ else
40
+ { resolver: resolver }
41
+ end
31
42
  end
32
43
 
33
- def function
34
- @function ||= Controller::ControllerFunction.from_route(self)
44
+ private
45
+
46
+ attr_reader :function, :groups
47
+
48
+ def resolver
49
+ @resolver ||= Controller::BuildControllerActionResolver.call(route: self)
35
50
  end
36
51
  end
37
52
  end
@@ -8,34 +8,59 @@ module GraphqlRails
8
8
 
9
9
  attr_reader :queries, :mutations, :raw_actions
10
10
 
11
- def initialize(queries:, mutations:, raw_actions:)
11
+ def initialize(queries:, mutations:, raw_actions:, group: nil)
12
12
  @queries = queries
13
13
  @mutations = mutations
14
14
  @raw_actions = raw_actions
15
+ @group = group
15
16
  end
16
17
 
17
18
  def call
18
- query_type = build_type('Query', queries)
19
- mutation_type = build_type('Mutation', mutations)
19
+ query_type = build_group_type('Query', queries)
20
+ mutation_type = build_group_type('Mutation', mutations)
20
21
  raw = raw_actions
21
22
 
22
- GraphQL::Schema.define do
23
+ Class.new(GraphQL::Schema) do
24
+ connections.add(
25
+ GraphqlRails::Decorator::RelationDecorator,
26
+ GraphQL::Pagination::ActiveRecordRelationConnection
27
+ )
23
28
  cursor_encoder(Router::PlainCursorEncoder)
24
29
  raw.each { |action| send(action[:name], *action[:args], &action[:block]) }
25
30
 
26
- query(query_type)
27
- mutation(mutation_type)
31
+ query(query_type) if query_type
32
+ mutation(mutation_type) if mutation_type
33
+
34
+ def self.type_from_ast(*args)
35
+ type = super
36
+
37
+ type.respond_to?(:to_graphql) ? type.to_graphql : type
38
+ end
28
39
  end
29
40
  end
30
41
 
31
42
  private
32
43
 
33
- def build_type(type_name, routes)
34
- GraphQL::ObjectType.define do
35
- name type_name
44
+ attr_reader :group
45
+
46
+ def build_group_type(type_name, routes)
47
+ group_name = group
48
+ group_routes = routes.select { |route| route.show_in_group?(group_name) }
49
+ return if group_routes.empty?
50
+
51
+ build_type(type_name, group_routes)
52
+ end
53
+
54
+ def build_type(type_name, group_routes)
55
+ Class.new(GraphQL::Schema::Object) do
56
+ graphql_name(type_name)
57
+
58
+ group_routes.each do |route|
59
+ field(*route.name, **route.field_options)
60
+ end
36
61
 
37
- routes.each do |route|
38
- field route.name, function: route.function
62
+ def self.inspect
63
+ "#{GraphQL::Schema::Object}(#{graphql_name})"
39
64
  end
40
65
  end
41
66
  end
@@ -82,11 +82,13 @@ module GraphqlRails
82
82
  action_by_name = config.action_by_name
83
83
  controller_path = controller.name.underscore.sub(/_controller\Z/, '')
84
84
 
85
- Router.draw do
85
+ router = Router.draw do
86
86
  action_by_name.keys.each do |action_name|
87
- query("#{action_name}_test", to: "#{controller_path}##{action_name}")
87
+ query("#{action_name}_test", to: "#{controller_path}##{action_name}", group: :graphql_rspec_helpers)
88
88
  end
89
89
  end
90
+
91
+ router.graphql_schema(:graphql_rspec_helpers)
90
92
  end
91
93
  end
92
94
 
@@ -107,8 +109,8 @@ module GraphqlRails
107
109
  @response
108
110
  end
109
111
 
110
- def mutation(*args)
111
- query(*args)
112
+ def mutation(*args, **kwargs)
113
+ query(*args, **kwargs)
112
114
  end
113
115
 
114
116
  def response
@@ -0,0 +1,57 @@
1
+ # frozen_string_literal: true
2
+
3
+ module GraphqlRails
4
+ # Generates graphql schema dump files
5
+ class DumpGraphqlSchema
6
+ require 'graphql_rails/errors/error'
7
+
8
+ class MissingGraphqlRouterError < GraphqlRails::Error; end
9
+
10
+ attr_reader :name
11
+
12
+ def self.call(*args)
13
+ new(*args).call
14
+ end
15
+
16
+ def initialize(name:)
17
+ @name = name
18
+ end
19
+
20
+ def call
21
+ validate
22
+ File.write(schema_path, schema.to_definition)
23
+ end
24
+
25
+ private
26
+
27
+ def validate
28
+ return if router
29
+
30
+ error_message = \
31
+ 'GraphqlRouter is missing. ' \
32
+ 'Run `rails g graphql_rails:install` to build it'
33
+ raise MissingGraphqlRouterError, error_message
34
+ end
35
+
36
+ def router
37
+ @router ||= '::GraphqlRouter'.safe_constantize
38
+ end
39
+
40
+ def schema
41
+ @schema ||= ::GraphqlRouter.graphql_schema(name.presence)
42
+ end
43
+
44
+ def schema_path
45
+ ENV['GRAPHQL_SCHEMA_DUMP_PATH'] || default_schema_path
46
+ end
47
+
48
+ def default_schema_path
49
+ schema_folder_path = Rails.root.join('spec', 'fixtures')
50
+
51
+ FileUtils.mkdir_p(schema_folder_path)
52
+ file_name = name.present? ? "graphql_#{name}_schema.graphql" : 'graphql_schema.graphql'
53
+
54
+ schema_folder_path.join(file_name)
55
+ end
56
+ end
57
+ end
@@ -0,0 +1,14 @@
1
+ # frozen_string_literal: true
2
+
3
+ require 'graphql_rails/tasks/dump_graphql_schema'
4
+
5
+ namespace :graphql_rails do
6
+ namespace :schema do
7
+ desc 'Dump GraphQL schema'
8
+ task(:dump, %i[name] => :environment) do |_, args|
9
+ default_name = ENV.fetch('SCHEMA_GROUP_NAME', '')
10
+ args.with_defaults(name: default_name)
11
+ GraphqlRails::DumpGraphqlSchema.call(name: args.name)
12
+ end
13
+ end
14
+ end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module GraphqlRails
4
- VERSION = '0.6.0'
4
+ VERSION = '1.2.0'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: graphql_rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.0
4
+ version: 1.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Povilas Jurčys
8
- autorequire:
8
+ autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-04-29 00:00:00.000000000 Z
11
+ date: 2021-02-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: graphql
@@ -16,14 +16,20 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '1'
19
+ version: '1.12'
20
+ - - ">="
21
+ - !ruby/object:Gem::Version
22
+ version: 1.12.4
20
23
  type: :runtime
21
24
  prerelease: false
22
25
  version_requirements: !ruby/object:Gem::Requirement
23
26
  requirements:
24
27
  - - "~>"
25
28
  - !ruby/object:Gem::Version
26
- version: '1'
29
+ version: '1.12'
30
+ - - ">="
31
+ - !ruby/object:Gem::Version
32
+ version: 1.12.4
27
33
  - !ruby/object:Gem::Dependency
28
34
  name: activesupport
29
35
  requirement: !ruby/object:Gem::Requirement
@@ -44,28 +50,28 @@ dependencies:
44
50
  requirements:
45
51
  - - "~>"
46
52
  - !ruby/object:Gem::Version
47
- version: '1.16'
53
+ version: '2'
48
54
  type: :development
49
55
  prerelease: false
50
56
  version_requirements: !ruby/object:Gem::Requirement
51
57
  requirements:
52
58
  - - "~>"
53
59
  - !ruby/object:Gem::Version
54
- version: '1.16'
60
+ version: '2'
55
61
  - !ruby/object:Gem::Dependency
56
62
  name: rake
57
63
  requirement: !ruby/object:Gem::Requirement
58
64
  requirements:
59
65
  - - "~>"
60
66
  - !ruby/object:Gem::Version
61
- version: '10.0'
67
+ version: '13.0'
62
68
  type: :development
63
69
  prerelease: false
64
70
  version_requirements: !ruby/object:Gem::Requirement
65
71
  requirements:
66
72
  - - "~>"
67
73
  - !ruby/object:Gem::Version
68
- version: '10.0'
74
+ version: '13.0'
69
75
  - !ruby/object:Gem::Dependency
70
76
  name: rspec
71
77
  requirement: !ruby/object:Gem::Requirement
@@ -108,7 +114,21 @@ dependencies:
108
114
  - - ">="
109
115
  - !ruby/object:Gem::Version
110
116
  version: '0'
111
- description:
117
+ - !ruby/object:Gem::Dependency
118
+ name: rails
119
+ requirement: !ruby/object:Gem::Requirement
120
+ requirements:
121
+ - - "~>"
122
+ - !ruby/object:Gem::Version
123
+ version: '6'
124
+ type: :development
125
+ prerelease: false
126
+ version_requirements: !ruby/object:Gem::Requirement
127
+ requirements:
128
+ - - "~>"
129
+ - !ruby/object:Gem::Version
130
+ version: '6'
131
+ description:
112
132
  email:
113
133
  - po.jurcys@gmail.com
114
134
  executables: []
@@ -126,7 +146,6 @@ files:
126
146
  - Gemfile
127
147
  - Gemfile.lock
128
148
  - LICENSE.txt
129
- - README.md
130
149
  - Rakefile
131
150
  - bin/console
132
151
  - bin/setup
@@ -134,38 +153,70 @@ files:
134
153
  - docs/README.md
135
154
  - docs/_sidebar.md
136
155
  - docs/components/controller.md
156
+ - docs/components/decorator.md
137
157
  - docs/components/model.md
138
158
  - docs/components/routes.md
139
159
  - docs/getting_started/quick_start.md
140
160
  - docs/getting_started/setup.md
141
161
  - docs/index.html
162
+ - docs/logging_and_monitoring/logging_and_monitoring.md
163
+ - docs/other_tools/query_runner.md
164
+ - docs/other_tools/schema_dump.md
142
165
  - docs/testing/testing.md
143
166
  - graphql_rails.gemspec
167
+ - lib/generators/graphql_rails/install_generator.rb
168
+ - lib/generators/graphql_rails/templates/example_users_controller.erb
169
+ - lib/generators/graphql_rails/templates/graphql_application_controller.erb
170
+ - lib/generators/graphql_rails/templates/graphql_controller.erb
171
+ - lib/generators/graphql_rails/templates/graphql_router.erb
172
+ - lib/generators/graphql_rails/templates/graphql_router_spec.erb
144
173
  - lib/graphql_rails.rb
145
- - lib/graphql_rails/attribute.rb
146
- - lib/graphql_rails/attribute/attributable.rb
147
- - lib/graphql_rails/attribute/attribute_name_parser.rb
148
- - lib/graphql_rails/attribute/type_parser.rb
174
+ - lib/graphql_rails/attributes.rb
175
+ - lib/graphql_rails/attributes/attributable.rb
176
+ - lib/graphql_rails/attributes/attribute.rb
177
+ - lib/graphql_rails/attributes/attribute_name_parser.rb
178
+ - lib/graphql_rails/attributes/input_attribute.rb
179
+ - lib/graphql_rails/attributes/input_type_parser.rb
180
+ - lib/graphql_rails/attributes/type_name_info.rb
181
+ - lib/graphql_rails/attributes/type_parseable.rb
182
+ - lib/graphql_rails/attributes/type_parser.rb
183
+ - lib/graphql_rails/concerns/service.rb
149
184
  - lib/graphql_rails/controller.rb
150
185
  - lib/graphql_rails/controller/action.rb
151
186
  - lib/graphql_rails/controller/action_configuration.rb
152
187
  - lib/graphql_rails/controller/action_hook.rb
153
188
  - lib/graphql_rails/controller/action_hooks_runner.rb
189
+ - lib/graphql_rails/controller/build_controller_action_resolver.rb
190
+ - lib/graphql_rails/controller/build_controller_action_resolver/controller_action_resolver.rb
154
191
  - lib/graphql_rails/controller/configuration.rb
155
- - lib/graphql_rails/controller/controller_function.rb
156
- - lib/graphql_rails/controller/format_results.rb
192
+ - lib/graphql_rails/controller/log_controller_action.rb
157
193
  - lib/graphql_rails/controller/request.rb
194
+ - lib/graphql_rails/controller/request/format_errors.rb
195
+ - lib/graphql_rails/decorator.rb
196
+ - lib/graphql_rails/decorator/relation_decorator.rb
197
+ - lib/graphql_rails/errors/custom_execution_error.rb
158
198
  - lib/graphql_rails/errors/error.rb
159
199
  - lib/graphql_rails/errors/execution_error.rb
200
+ - lib/graphql_rails/errors/system_error.rb
160
201
  - lib/graphql_rails/errors/validation_error.rb
202
+ - lib/graphql_rails/input_configurable.rb
203
+ - lib/graphql_rails/integrations.rb
204
+ - lib/graphql_rails/integrations/lograge.rb
205
+ - lib/graphql_rails/integrations/sentry.rb
161
206
  - lib/graphql_rails/model.rb
207
+ - lib/graphql_rails/model/add_fields_to_graphql_type.rb
208
+ - lib/graphql_rails/model/build_connection_type.rb
209
+ - lib/graphql_rails/model/build_connection_type/count_items.rb
210
+ - lib/graphql_rails/model/build_enum_type.rb
211
+ - lib/graphql_rails/model/build_graphql_input_type.rb
212
+ - lib/graphql_rails/model/call_graphql_model_method.rb
162
213
  - lib/graphql_rails/model/configurable.rb
163
214
  - lib/graphql_rails/model/configuration.rb
164
- - lib/graphql_rails/model/configuration/count_items.rb
165
- - lib/graphql_rails/model/graphql_input_type_builder.rb
166
- - lib/graphql_rails/model/graphql_type_builder.rb
215
+ - lib/graphql_rails/model/find_or_build_graphql_type.rb
216
+ - lib/graphql_rails/model/find_or_build_graphql_type_class.rb
167
217
  - lib/graphql_rails/model/input.rb
168
- - lib/graphql_rails/model/input_attribute.rb
218
+ - lib/graphql_rails/query_runner.rb
219
+ - lib/graphql_rails/railtie.rb
169
220
  - lib/graphql_rails/router.rb
170
221
  - lib/graphql_rails/router/mutation_route.rb
171
222
  - lib/graphql_rails/router/plain_cursor_encoder.rb
@@ -174,12 +225,14 @@ files:
174
225
  - lib/graphql_rails/router/route.rb
175
226
  - lib/graphql_rails/router/schema_builder.rb
176
227
  - lib/graphql_rails/rspec_controller_helpers.rb
228
+ - lib/graphql_rails/tasks/dump_graphql_schema.rb
229
+ - lib/graphql_rails/tasks/schema.rake
177
230
  - lib/graphql_rails/version.rb
178
231
  homepage: https://github.com/samesystem/graphql_rails
179
232
  licenses:
180
233
  - MIT
181
234
  metadata: {}
182
- post_install_message:
235
+ post_install_message:
183
236
  rdoc_options: []
184
237
  require_paths:
185
238
  - lib
@@ -194,9 +247,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
194
247
  - !ruby/object:Gem::Version
195
248
  version: '0'
196
249
  requirements: []
197
- rubyforge_project:
198
- rubygems_version: 2.7.7
199
- signing_key:
250
+ rubygems_version: 3.1.2
251
+ signing_key:
200
252
  specification_version: 4
201
- summary: GraphQL server and client for rails
253
+ summary: Rails style structure for GraphQL API.
202
254
  test_files: []