agoo 2.11.7 → 2.13.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -103,6 +103,7 @@ configure(agooErr err, int port, const char *root, VALUE options) {
103
103
  }
104
104
  agoo_server.thread_cnt = 0;
105
105
  the_rserver.worker_cnt = 1;
106
+ the_rserver.uses = NULL;
106
107
  atomic_init(&agoo_server.running, 0);
107
108
  agoo_server.listen_thread = 0;
108
109
  agoo_server.con_loops = NULL;
@@ -209,6 +210,7 @@ configure(agooErr err, int port, const char *root, VALUE options) {
209
210
  agooHook dump_hook;
210
211
  agooHook get_hook;
211
212
  agooHook post_hook;
213
+ agooHook options_hook;
212
214
  char schema_path[256];
213
215
  long plen;
214
216
 
@@ -227,9 +229,11 @@ configure(agooErr err, int port, const char *root, VALUE options) {
227
229
  dump_hook = agoo_hook_func_create(AGOO_GET, schema_path, gql_dump_hook, &agoo_server.eval_queue);
228
230
  get_hook = agoo_hook_func_create(AGOO_GET, path, gql_eval_get_hook, &agoo_server.eval_queue);
229
231
  post_hook = agoo_hook_func_create(AGOO_POST, path, gql_eval_post_hook, &agoo_server.eval_queue);
232
+ options_hook = agoo_hook_func_create(AGOO_OPTIONS, path, gql_eval_options_hook, &agoo_server.eval_queue);
230
233
  dump_hook->next = get_hook;
231
234
  get_hook->next = post_hook;
232
- post_hook->next = agoo_server.hooks;
235
+ post_hook->next = options_hook;
236
+ options_hook->next = agoo_server.hooks;
233
237
  agoo_server.hooks = dump_hook;
234
238
  }
235
239
  if (Qnil != (v = rb_hash_lookup(options, ID2SYM(rb_intern("quiet"))))) {
@@ -381,7 +385,7 @@ handle_base_inner(VALUE x) {
381
385
 
382
386
  static void*
383
387
  handle_base(void *x) {
384
- rb_rescue2(handle_base_inner, (VALUE)x, rescue_error, (VALUE)x, rb_eException, 0);
388
+ rb_rescue2(handle_base_inner, (VALUE)x, rescue_error, (VALUE)x, rb_eException, (VALUE)0);
385
389
 
386
390
  return NULL;
387
391
  }
@@ -610,7 +614,7 @@ handle_rack_inner(VALUE x) {
610
614
  static void*
611
615
  handle_rack(void *x) {
612
616
  //rb_gc_disable();
613
- rb_rescue2(handle_rack_inner, (VALUE)x, rescue_error, (VALUE)x, rb_eException, 0);
617
+ rb_rescue2(handle_rack_inner, (VALUE)x, rescue_error, (VALUE)x, rb_eException, (VALUE)0);
614
618
  //rb_gc_enable();
615
619
  //rb_gc();
616
620
 
@@ -635,7 +639,7 @@ handle_wab_inner(VALUE x) {
635
639
 
636
640
  static void*
637
641
  handle_wab(void *x) {
638
- rb_rescue2(handle_wab_inner, (VALUE)x, rescue_error, (VALUE)x, rb_eException, 0);
642
+ rb_rescue2(handle_wab_inner, (VALUE)x, rescue_error, (VALUE)x, rb_eException, (VALUE)0);
639
643
 
640
644
  return NULL;
641
645
  }
@@ -693,7 +697,7 @@ handle_push_inner(VALUE x) {
693
697
 
694
698
  static void*
695
699
  handle_push(void *x) {
696
- rb_rescue2(handle_push_inner, (VALUE)x, rescue_error, (VALUE)x, rb_eException, 0);
700
+ rb_rescue2(handle_push_inner, (VALUE)x, rescue_error, (VALUE)x, rb_eException, (VALUE)0);
697
701
  return NULL;
698
702
  }
699
703
 
@@ -1011,6 +1015,14 @@ handle(VALUE self, VALUE method, VALUE pattern, VALUE handler) {
1011
1015
  }
1012
1016
  }
1013
1017
  }
1018
+ if (NULL != the_rserver.uses) {
1019
+ RUse u;
1020
+
1021
+ for (u = the_rserver.uses; NULL != u; u = u->next) {
1022
+ u->argv[0] = handler;
1023
+ handler = rb_funcall2(u->clas, rb_intern("new"), u->argc, u->argv);
1024
+ }
1025
+ }
1014
1026
  if (NULL == (hook = rhook_create(meth, pat, handler, &agoo_server.eval_queue))) {
1015
1027
  rb_raise(rb_eStandardError, "out of memory.");
1016
1028
  } else {
@@ -1192,6 +1204,40 @@ rack_early_hints(VALUE self, VALUE on) {
1192
1204
  return on;
1193
1205
  }
1194
1206
 
1207
+ /* Document-method: use
1208
+ *
1209
+ * call-seq: use(middleware, *args)
1210
+ *
1211
+ * The use function must be called before the _handle_ functions. Any
1212
+ * invocations of _use_ apply only to handlers called after the call to use.
1213
+ */
1214
+ static VALUE
1215
+ use(int argc, VALUE *argv, VALUE self) {
1216
+ VALUE mc;
1217
+ RUse u;
1218
+
1219
+ if (argc < 1) { // at least the middleware class must be provided.
1220
+ rb_raise(rb_eArgError, "no middleware class provided");
1221
+ }
1222
+ mc = argv[0];
1223
+ if (T_CLASS != rb_type(mc)) {
1224
+ rb_raise(rb_eArgError, "the first argument to use must be a class");
1225
+ }
1226
+ if (NULL == (u = (RUse)AGOO_MALLOC(sizeof(struct _rUse)))) {
1227
+ rb_raise(rb_eNoMemError, "Failed to allocate memory for a middleware use.");
1228
+ }
1229
+ u->clas = mc;
1230
+ u->argc = argc;
1231
+ if (NULL == (u->argv = (VALUE*)AGOO_MALLOC(sizeof(VALUE) * u->argc))) {
1232
+ rb_raise(rb_eNoMemError, "Failed to allocate memory for a middleware use.");
1233
+ }
1234
+ memcpy(u->argv, argv, argc * sizeof(VALUE));
1235
+ u->next = the_rserver.uses;
1236
+ the_rserver.uses = u;
1237
+
1238
+ return Qnil;
1239
+ }
1240
+
1195
1241
  /* Document-class: Agoo::Server
1196
1242
  *
1197
1243
  * An HTTP server that support the rack API as well as some other optimized
@@ -1211,6 +1257,7 @@ server_init(VALUE mod) {
1211
1257
  rb_define_module_function(server_mod, "path_group", path_group, 2);
1212
1258
  rb_define_module_function(server_mod, "header_rule", header_rule, 4);
1213
1259
  rb_define_module_function(server_mod, "domain", domain, 2);
1260
+ rb_define_module_function(server_mod, "use", use, -1);
1214
1261
 
1215
1262
  rb_define_module_function(server_mod, "rack_early_hints", rack_early_hints, 1);
1216
1263
 
@@ -7,10 +7,18 @@
7
7
 
8
8
  #define MAX_WORKERS 32
9
9
 
10
+ typedef struct _rUse {
11
+ struct _rUse *next;
12
+ VALUE clas;
13
+ VALUE *argv;
14
+ int argc;
15
+ } *RUse;
16
+
10
17
  typedef struct _rServer {
11
18
  int worker_cnt;
12
19
  int worker_pids[MAX_WORKERS];
13
20
  VALUE *eval_threads; // Qnil terminated
21
+ RUse uses;
14
22
  } *RServer;
15
23
 
16
24
  extern struct _rServer the_rserver;
@@ -168,14 +168,13 @@ make_scalar(agooErr err, agooDoc doc, const char *desc, int len, bool x) {
168
168
  }
169
169
 
170
170
  static int
171
- read_type(agooErr err, agooDoc doc, gqlType *typep, bool *required) {
171
+ read_type(agooErr err, agooDoc doc, gqlType *typep) {
172
172
  agoo_doc_skip_white(doc);
173
173
  if ('[' == *doc->cur) {
174
174
  gqlType base;
175
- bool not_empty = false;
176
175
 
177
176
  doc->cur++;
178
- if (AGOO_ERR_OK != read_type(err, doc, &base, &not_empty)) {
177
+ if (AGOO_ERR_OK != read_type(err, doc, &base)) {
179
178
  return err->code;
180
179
  }
181
180
  agoo_doc_skip_white(doc);
@@ -183,7 +182,7 @@ read_type(agooErr err, agooDoc doc, gqlType *typep, bool *required) {
183
182
  return agoo_doc_err(doc, err, "List type not terminated with a ]");
184
183
  }
185
184
  doc->cur++;
186
- if (NULL == (*typep = gql_assure_list(err, base, not_empty))) {
185
+ if (NULL == (*typep = gql_assure_list(err, base))) {
187
186
  return err->code;
188
187
  }
189
188
  } else {
@@ -196,10 +195,13 @@ read_type(agooErr err, agooDoc doc, gqlType *typep, bool *required) {
196
195
  return err->code;
197
196
  }
198
197
  }
199
- *required = false;
200
198
  agoo_doc_skip_white(doc);
201
199
  if ('!' == *doc->cur) {
202
- *required = true;
200
+ gqlType base = *typep;
201
+
202
+ if (NULL == (*typep = gql_assure_nonnull(err, base))) {
203
+ return err->code;
204
+ }
203
205
  doc->cur++;
204
206
  }
205
207
  return AGOO_ERR_OK;
@@ -272,7 +274,6 @@ make_union(agooErr err, agooDoc doc, const char *desc, int len, bool x) {
272
274
  char name[256];
273
275
  gqlType type;
274
276
  gqlType member;
275
- bool required;
276
277
 
277
278
  if (AGOO_ERR_OK != extract_name(err, doc, union_str, sizeof(union_str) - 1, name, sizeof(name))) {
278
279
  return err->code;
@@ -296,7 +297,7 @@ make_union(agooErr err, agooDoc doc, const char *desc, int len, bool x) {
296
297
  agoo_doc_skip_white(doc);
297
298
 
298
299
  while (doc->cur < doc->end) {
299
- if (AGOO_ERR_OK != read_type(err, doc, &member, &required)) {
300
+ if (AGOO_ERR_OK != read_type(err, doc, &member)) {
300
301
  goto ERROR;
301
302
  }
302
303
  if (AGOO_ERR_OK != gql_union_add(err, type, member)) {
@@ -325,7 +326,6 @@ make_dir_arg(agooErr err, agooDoc doc, gqlDir dir) {
325
326
  const char *desc = NULL;
326
327
  size_t dlen;
327
328
  size_t nlen;
328
- bool required = false;
329
329
  gqlValue dv = NULL;
330
330
 
331
331
  if (AGOO_ERR_OK != extract_desc(err, doc, &desc, &dlen)) {
@@ -368,7 +368,9 @@ make_dir_arg(agooErr err, agooDoc doc, gqlDir dir) {
368
368
  }
369
369
  agoo_doc_skip_white(doc);
370
370
  if ('!' == *doc->cur) {
371
- required = true;
371
+ if (NULL == (type = gql_assure_nonnull(err, type))) {
372
+ return err->code;
373
+ }
372
374
  doc->cur++;
373
375
  } else if ('=' == *doc->cur) {
374
376
  if (NULL == (dv = agoo_doc_read_value(err, doc, type))) {
@@ -379,7 +381,7 @@ make_dir_arg(agooErr err, agooDoc doc, gqlDir dir) {
379
381
  if ('@' == *doc->cur) {
380
382
  // TBD directive
381
383
  }
382
- if (NULL == gql_dir_arg(err, dir, name, type, desc, dlen, dv, required)) {
384
+ if (NULL == gql_dir_arg(err, dir, name, type, desc, dlen, dv)) {
383
385
  return err->code;
384
386
  }
385
387
  return AGOO_ERR_OK;
@@ -451,7 +453,6 @@ make_field_arg(agooErr err, agooDoc doc, gqlField field) {
451
453
  gqlType type;
452
454
  const char *desc = NULL;
453
455
  size_t dlen;
454
- bool required = false;
455
456
  gqlValue dval = NULL;
456
457
 
457
458
  if (AGOO_ERR_OK != extract_desc(err, doc, &desc, &dlen)) {
@@ -467,7 +468,7 @@ make_field_arg(agooErr err, agooDoc doc, gqlField field) {
467
468
  }
468
469
  doc->cur++;
469
470
 
470
- if (AGOO_ERR_OK != read_type(err, doc, &type, &required)) {
471
+ if (AGOO_ERR_OK != read_type(err, doc, &type)) {
471
472
  return err->code;
472
473
  }
473
474
  agoo_doc_skip_white(doc);
@@ -484,7 +485,7 @@ make_field_arg(agooErr err, agooDoc doc, gqlField field) {
484
485
  default: // ) or next arg
485
486
  break;
486
487
  }
487
- if (NULL == gql_field_arg(err, field, name, type, desc, dlen, dval, required)) {
488
+ if (NULL == gql_field_arg(err, field, name, type, desc, dlen, dval)) {
488
489
  return err->code;
489
490
  }
490
491
  return AGOO_ERR_OK;
@@ -500,7 +501,6 @@ make_field(agooErr err, agooDoc doc, gqlType type) {
500
501
  gqlValue dval = NULL;
501
502
  const char *desc = NULL;
502
503
  size_t dlen;
503
- bool required = false;
504
504
 
505
505
  if (AGOO_ERR_OK != extract_desc(err, doc, &desc, &dlen)) {
506
506
  return err->code;
@@ -531,7 +531,7 @@ make_field(agooErr err, agooDoc doc, gqlType type) {
531
531
  default:
532
532
  return agoo_doc_err(doc, err, "Expected : or (");
533
533
  }
534
- if (AGOO_ERR_OK != read_type(err, doc, &return_type, &required)) {
534
+ if (AGOO_ERR_OK != read_type(err, doc, &return_type)) {
535
535
  return err->code;
536
536
  }
537
537
  if ('=' == *doc->cur) {
@@ -543,7 +543,7 @@ make_field(agooErr err, agooDoc doc, gqlType type) {
543
543
  if (AGOO_ERR_OK != extract_dir_use(err, doc, &uses)) {
544
544
  return err->code;
545
545
  }
546
- if (NULL == (field = gql_type_field(err, type, name, return_type, dval, desc, dlen, required))) {
546
+ if (NULL == (field = gql_type_field(err, type, name, return_type, dval, desc, dlen))) {
547
547
  return err->code;
548
548
  }
549
549
  field->dir = uses;
@@ -574,7 +574,6 @@ make_input_arg(agooErr err, agooDoc doc, gqlType type) {
574
574
  gqlValue dval = NULL;
575
575
  const char *desc = NULL;
576
576
  size_t dlen;
577
- bool required = false;
578
577
 
579
578
  if (AGOO_ERR_OK != extract_desc(err, doc, &desc, &dlen)) {
580
579
  return err->code;
@@ -588,7 +587,7 @@ make_input_arg(agooErr err, agooDoc doc, gqlType type) {
588
587
  return agoo_doc_err(doc, err, "Expected :");
589
588
  }
590
589
  doc->cur++;
591
- if (AGOO_ERR_OK != read_type(err, doc, &return_type, &required)) {
590
+ if (AGOO_ERR_OK != read_type(err, doc, &return_type)) {
592
591
  return err->code;
593
592
  }
594
593
  if ('=' == *doc->cur) {
@@ -600,7 +599,7 @@ make_input_arg(agooErr err, agooDoc doc, gqlType type) {
600
599
  if (AGOO_ERR_OK != extract_dir_use(err, doc, &uses)) {
601
600
  return err->code;
602
601
  }
603
- if (NULL == (arg = gql_input_arg(err, type, name, return_type, desc, dlen, dval, required))) {
602
+ if (NULL == (arg = gql_input_arg(err, type, name, return_type, desc, dlen, dval))) {
604
603
  return err->code;
605
604
  }
606
605
  arg->dir = uses;
@@ -699,7 +698,6 @@ static int
699
698
  extract_interfaces(agooErr err, agooDoc doc, gqlTypeLink *interfacesp) {
700
699
  gqlType type;
701
700
  gqlTypeLink link;
702
- bool required;
703
701
  bool first = true;
704
702
 
705
703
  agoo_doc_skip_white(doc);
@@ -722,9 +720,8 @@ extract_interfaces(agooErr err, agooDoc doc, gqlTypeLink *interfacesp) {
722
720
  return agoo_doc_err(doc, err, "Expected &");
723
721
  }
724
722
  first = false;
725
- required = false;
726
723
  type = NULL;
727
- if (AGOO_ERR_OK != read_type(err, doc, &type, &required)) {
724
+ if (AGOO_ERR_OK != read_type(err, doc, &type)) {
728
725
  return err->code;
729
726
  }
730
727
  if (NULL == (link = (gqlTypeLink)AGOO_MALLOC(sizeof(struct _gqlTypeLink)))) {
@@ -1052,7 +1049,6 @@ static int
1052
1049
  make_op_var(agooErr err, agooDoc doc, gqlOp op) {
1053
1050
  char name[256];
1054
1051
  gqlType type;
1055
- bool ignore;
1056
1052
  gqlValue value = NULL;
1057
1053
  gqlVar var;
1058
1054
 
@@ -1070,7 +1066,7 @@ make_op_var(agooErr err, agooDoc doc, gqlOp op) {
1070
1066
  }
1071
1067
  doc->cur++;
1072
1068
 
1073
- if (AGOO_ERR_OK != read_type(err, doc, &type, &ignore)) {
1069
+ if (AGOO_ERR_OK != read_type(err, doc, &type)) {
1074
1070
  return err->code;
1075
1071
  }
1076
1072
  agoo_doc_skip_white(doc);
@@ -1496,6 +1492,7 @@ lookup_field_type(gqlType type, const char *field, bool qroot) {
1496
1492
  break;
1497
1493
  }
1498
1494
  case GQL_LIST:
1495
+ case GQL_NON_NULL:
1499
1496
  ftype = lookup_field_type(type->base, field, false);
1500
1497
  break;
1501
1498
  case GQL_UNION: // Can not be used directly for query type determinations.
@@ -1524,7 +1521,7 @@ sel_set_type(agooErr err, gqlType type, gqlSel sels, bool qroot) {
1524
1521
  }
1525
1522
  } else {
1526
1523
  if (NULL == (sel->type = lookup_field_type(type, sel->name, qroot))) {
1527
- return agoo_err_set(err, AGOO_ERR_EVAL, "Failed to determine the type for %s.", sel->name);
1524
+ return agoo_err_set(err, AGOO_ERR_EVAL, "Failed to determine the type for %s in %s.", sel->name, type->name);
1528
1525
  }
1529
1526
  }
1530
1527
  if (NULL != sel->sels) {
@@ -15,6 +15,6 @@ extern int sdl_parse(agooErr err, const char *str, int len);
15
15
  // Parse a execution definition.
16
16
  extern struct _gqlDoc* sdl_parse_doc(agooErr err, const char *str, int len, struct _gqlVar *vars, gqlOpKind default_kind);
17
17
 
18
- extern gqlVar gql_op_var_create(agooErr err, const char *name, struct _gqlType *type, struct _gqlValue *value);
18
+ extern gqlVar gql_op_var_create(agooErr err, const char *name, struct _gqlType *type, struct _gqlValue *value);
19
19
 
20
20
  #endif // AGOO_SDL_H
@@ -4,6 +4,7 @@ end
4
4
 
5
5
  require 'stringio' # needed for Ruby 2.7
6
6
  require 'agoo/version'
7
+ require 'agoo/graphql'
7
8
  require 'rack/handler/agoo'
8
9
  require 'agoo/agoo' # C extension
9
10
 
@@ -0,0 +1,9 @@
1
+
2
+ module Agoo
3
+ class GraphQL
4
+ end
5
+ end
6
+
7
+ require 'agoo/graphql/arg'
8
+ require 'agoo/graphql/field'
9
+ require 'agoo/graphql/type'
@@ -0,0 +1,13 @@
1
+
2
+ module Agoo
3
+ class GraphQL
4
+
5
+ class Arg
6
+ attr_accessor :name
7
+ attr_accessor :description
8
+ attr_accessor :type_name
9
+ attr_accessor :default_value
10
+ end
11
+
12
+ end
13
+ end
@@ -0,0 +1,14 @@
1
+
2
+ module Agoo
3
+ class GraphQL
4
+
5
+ class Field
6
+ attr_accessor :name
7
+ attr_accessor :description
8
+ attr_accessor :type_name
9
+ attr_accessor :args
10
+ attr_accessor :default_value
11
+ end
12
+
13
+ end
14
+ end
@@ -0,0 +1,12 @@
1
+
2
+ module Agoo
3
+ class GraphQL
4
+
5
+ class Type
6
+ attr_accessor :name
7
+ attr_accessor :description
8
+ attr_accessor :fields
9
+ end
10
+
11
+ end
12
+ end
@@ -1,5 +1,5 @@
1
1
 
2
2
  module Agoo
3
3
  # Agoo version.
4
- VERSION = '2.11.7'
4
+ VERSION = '2.13.0'
5
5
  end
@@ -26,7 +26,7 @@ class Artist
26
26
  @likes = 0
27
27
  end
28
28
 
29
- def song(args={})
29
+ def song(args)
30
30
  @songs[args['name']]
31
31
  end
32
32
 
@@ -35,7 +35,7 @@ class Artist
35
35
  @songs << song
36
36
  end
37
37
 
38
- def genre_songs(args={})
38
+ def genre_songs(args)
39
39
  g = args['genre']
40
40
  a = []
41
41
  @songs.each { |s|
@@ -126,7 +126,7 @@ class Query
126
126
  @artists = artists
127
127
  end
128
128
 
129
- def artist(args={})
129
+ def artist(args)
130
130
  @artists[args['name']]
131
131
  end
132
132
  end
@@ -138,7 +138,7 @@ class Mutation
138
138
  @artists = artists
139
139
  end
140
140
 
141
- def like(args={})
141
+ def like(args)
142
142
  artist = @artists[args['artist']]
143
143
  artist.like
144
144
  artist
@@ -227,6 +227,12 @@ directive @ruby(class: String!) on SCHEMA | OBJECT
227
227
  Agoo::GraphQL.load($songs_sdl)
228
228
  Agoo::GraphQL.load($extend_sdl)
229
229
  }
230
+ =begin
231
+ Agoo::GraphQL.build_headers = proc{ |req|
232
+ { 'Set-Cookie' => 'UserID=Bozo; Max-Age=3600; Version=1' }
233
+ }
234
+ =end
235
+ Agoo::GraphQL.headers({ 'Set-Cookie' => 'UserID=Bozo; Max-Age=3600; Version=1' })
230
236
  @@server_started = true
231
237
  end
232
238
 
@@ -283,6 +289,7 @@ directive @ruby(class: String!) on SCHEMA | OBJECT
283
289
  }
284
290
  content = res.body
285
291
  assert_equal('application/json', res['Content-Type'])
292
+ assert_equal('UserID=Bozo; Max-Age=3600; Version=1', res['Set-Cookie'])
286
293
  assert_equal(expect, content)
287
294
  end
288
295
 
@@ -671,7 +678,7 @@ query skippy($boo: Boolean = true){
671
678
  "__type":{
672
679
  "name":"[__Type!]",
673
680
  "ofType":{
674
- "name":"__Type"
681
+ "name":"__Type!"
675
682
  }
676
683
  }
677
684
  }
@@ -735,7 +742,7 @@ query skippy($boo: Boolean = true){
735
742
  {
736
743
  "name":"name",
737
744
  "type":{
738
- "name":"String"
745
+ "name":"String!"
739
746
  },
740
747
  "args":[
741
748
  ]
@@ -837,9 +844,6 @@ query skippy($boo: Boolean = true){
837
844
  {
838
845
  "name":"Boolean"
839
846
  },
840
- {
841
- "name":"schema"
842
- },
843
847
  {
844
848
  "name":"String"
845
849
  },
@@ -913,15 +917,14 @@ query skippy($boo: Boolean = true){
913
917
  ]
914
918
  },
915
919
  {
916
- "name":"skip",
920
+ "name":"deprecated",
917
921
  "locations":[
918
- "FIELD",
919
- "FRAGMENT_SPREAD",
920
- "INLINE_FRAGMENT"
922
+ "FIELD_DEFINITION",
923
+ "ENUM_VALUE"
921
924
  ],
922
925
  "args":[
923
926
  {
924
- "name":"if"
927
+ "name":"reason"
925
928
  }
926
929
  ]
927
930
  },
@@ -939,14 +942,15 @@ query skippy($boo: Boolean = true){
939
942
  ]
940
943
  },
941
944
  {
942
- "name":"deprecated",
945
+ "name":"skip",
943
946
  "locations":[
944
- "FIELD_DEFINITION",
945
- "ENUM_VALUE"
947
+ "FIELD",
948
+ "FRAGMENT_SPREAD",
949
+ "INLINE_FRAGMENT"
946
950
  ],
947
951
  "args":[
948
952
  {
949
- "name":"reason"
953
+ "name":"if"
950
954
  }
951
955
  ]
952
956
  }