Merge pull request #7982 from tchak/graphql-update

chore(graphql): update
This commit is contained in:
Paul Chavard 2022-10-31 19:27:00 +01:00 committed by GitHub
commit d0c6560f25
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 79 additions and 81 deletions

View file

@ -4,40 +4,40 @@ GEM
aasm (5.2.0)
concurrent-ruby (~> 1.0)
acsv (0.0.1)
actioncable (6.1.6.1)
actionpack (= 6.1.6.1)
activesupport (= 6.1.6.1)
actioncable (6.1.7)
actionpack (= 6.1.7)
activesupport (= 6.1.7)
nio4r (~> 2.0)
websocket-driver (>= 0.6.1)
actionmailbox (6.1.6.1)
actionpack (= 6.1.6.1)
activejob (= 6.1.6.1)
activerecord (= 6.1.6.1)
activestorage (= 6.1.6.1)
activesupport (= 6.1.6.1)
actionmailbox (6.1.7)
actionpack (= 6.1.7)
activejob (= 6.1.7)
activerecord (= 6.1.7)
activestorage (= 6.1.7)
activesupport (= 6.1.7)
mail (>= 2.7.1)
actionmailer (6.1.6.1)
actionpack (= 6.1.6.1)
actionview (= 6.1.6.1)
activejob (= 6.1.6.1)
activesupport (= 6.1.6.1)
actionmailer (6.1.7)
actionpack (= 6.1.7)
actionview (= 6.1.7)
activejob (= 6.1.7)
activesupport (= 6.1.7)
mail (~> 2.5, >= 2.5.4)
rails-dom-testing (~> 2.0)
actionpack (6.1.6.1)
actionview (= 6.1.6.1)
activesupport (= 6.1.6.1)
actionpack (6.1.7)
actionview (= 6.1.7)
activesupport (= 6.1.7)
rack (~> 2.0, >= 2.0.9)
rack-test (>= 0.6.3)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.2.0)
actiontext (6.1.6.1)
actionpack (= 6.1.6.1)
activerecord (= 6.1.6.1)
activestorage (= 6.1.6.1)
activesupport (= 6.1.6.1)
actiontext (6.1.7)
actionpack (= 6.1.7)
activerecord (= 6.1.7)
activestorage (= 6.1.7)
activesupport (= 6.1.7)
nokogiri (>= 1.8.5)
actionview (6.1.6.1)
activesupport (= 6.1.6.1)
actionview (6.1.7)
activesupport (= 6.1.7)
builder (~> 3.1)
erubi (~> 1.4)
rails-dom-testing (~> 2.0)
@ -55,26 +55,26 @@ GEM
activemodel (>= 5.2.0)
activestorage (>= 5.2.0)
activesupport (>= 5.2.0)
activejob (6.1.6.1)
activesupport (= 6.1.6.1)
activejob (6.1.7)
activesupport (= 6.1.7)
globalid (>= 0.3.6)
activemodel (6.1.6.1)
activesupport (= 6.1.6.1)
activerecord (6.1.6.1)
activemodel (= 6.1.6.1)
activesupport (= 6.1.6.1)
activestorage (6.1.6.1)
actionpack (= 6.1.6.1)
activejob (= 6.1.6.1)
activerecord (= 6.1.6.1)
activesupport (= 6.1.6.1)
activemodel (6.1.7)
activesupport (= 6.1.7)
activerecord (6.1.7)
activemodel (= 6.1.7)
activesupport (= 6.1.7)
activestorage (6.1.7)
actionpack (= 6.1.7)
activejob (= 6.1.7)
activerecord (= 6.1.7)
activesupport (= 6.1.7)
marcel (~> 1.0)
mini_mime (>= 1.1.0)
activestorage-openstack (1.5.1)
fog-openstack (~> 1.0)
marcel
rails (>= 5.2.2)
activesupport (6.1.6.1)
activesupport (6.1.7)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 1.6, < 2)
minitest (>= 5.1)
@ -288,18 +288,18 @@ GEM
i18n (>= 0.7)
multi_json
request_store (>= 1.0)
graphql (1.12.5)
graphql-batch (0.4.3)
graphql (>= 1.3, < 2)
graphql (2.0.15)
graphql-batch (0.5.1)
graphql (>= 1.10, < 3)
promise.rb (~> 0.7.2)
graphql-rails_logger (1.2.3)
actionpack (> 5.0)
activesupport (> 5.0)
railties (> 5.0)
rouge (~> 3.0)
graphql-schema_comparator (1.0.0)
graphql-schema_comparator (1.1.2)
bundler (>= 1.14)
graphql (~> 1.10)
graphql (>= 1.10, < 3.0)
thor (>= 0.19, < 2.0)
graphql_playground-rails (2.1.0)
rails (>= 5.1.0)
@ -517,20 +517,20 @@ GEM
rack
rack-test (2.0.2)
rack (>= 1.3)
rails (6.1.6.1)
actioncable (= 6.1.6.1)
actionmailbox (= 6.1.6.1)
actionmailer (= 6.1.6.1)
actionpack (= 6.1.6.1)
actiontext (= 6.1.6.1)
actionview (= 6.1.6.1)
activejob (= 6.1.6.1)
activemodel (= 6.1.6.1)
activerecord (= 6.1.6.1)
activestorage (= 6.1.6.1)
activesupport (= 6.1.6.1)
rails (6.1.7)
actioncable (= 6.1.7)
actionmailbox (= 6.1.7)
actionmailer (= 6.1.7)
actionpack (= 6.1.7)
actiontext (= 6.1.7)
actionview (= 6.1.7)
activejob (= 6.1.7)
activemodel (= 6.1.7)
activerecord (= 6.1.7)
activestorage (= 6.1.7)
activesupport (= 6.1.7)
bundler (>= 1.15.0)
railties (= 6.1.6.1)
railties (= 6.1.7)
sprockets-rails (>= 2.0.0)
rails-controller-testing (1.0.5)
actionpack (>= 5.0.1.rc1)
@ -549,9 +549,9 @@ GEM
rails-i18n (7.0.3)
i18n (>= 0.7, < 2)
railties (>= 6.0.0, < 8)
railties (6.1.6.1)
actionpack (= 6.1.6.1)
activesupport (= 6.1.6.1)
railties (6.1.7)
actionpack (= 6.1.7)
activesupport (= 6.1.7)
method_source
rake (>= 12.2)
thor (~> 1.0)
@ -581,7 +581,7 @@ GEM
dry-inflector (~> 0.1)
rubyzip (>= 1.0)
rotp (6.2.0)
rouge (3.26.0)
rouge (3.30.0)
rqrcode (1.2.0)
chunky_png (~> 1.0)
rqrcode_core (~> 0.2)

View file

@ -1,6 +1,9 @@
class API::V2::Schema < GraphQL::Schema
default_max_page_size 100
max_complexity 300
default_page_size 100
# Disable max_complexity for now because of what looks like a bug in graphql gem.
# After some internal changes complexity for our avarage query went from < 300 to 25 000.
max_complexity nil
max_depth 15
query Types::QueryType
@ -70,8 +73,6 @@ class API::V2::Schema < GraphQL::Schema
raise GraphQL::ExecutionError.new("An object of type #{error.type.graphql_name} was hidden due to permissions", extensions: { code: :unauthorized })
end
use GraphQL::Execution::Interpreter
use GraphQL::Analysis::AST
use GraphQL::Schema::Timeout, max_seconds: 10
use GraphQL::Batch
use GraphQL::Backtrace
@ -91,8 +92,5 @@ class API::V2::Schema < GraphQL::Schema
query_analyzer(LogQueryComplexity)
query_analyzer(LogQueryDepth)
else
query_analyzer(GraphQL::Analysis::AST::MaxQueryComplexity)
query_analyzer(GraphQL::Analysis::AST::MaxQueryDepth)
end
end

View file

@ -298,7 +298,7 @@ input CreateDirectUploadInput {
}
"""
Autogenerated return type of CreateDirectUpload
Autogenerated return type of CreateDirectUpload.
"""
type CreateDirectUploadPayload {
"""
@ -823,7 +823,7 @@ input DossierAccepterInput {
}
"""
Autogenerated return type of DossierAccepter
Autogenerated return type of DossierAccepter.
"""
type DossierAccepterPayload {
"""
@ -855,7 +855,7 @@ input DossierArchiverInput {
}
"""
Autogenerated return type of DossierArchiver
Autogenerated return type of DossierArchiver.
"""
type DossierArchiverPayload {
"""
@ -887,7 +887,7 @@ input DossierChangerGroupeInstructeurInput {
}
"""
Autogenerated return type of DossierChangerGroupeInstructeur
Autogenerated return type of DossierChangerGroupeInstructeur.
"""
type DossierChangerGroupeInstructeurPayload {
"""
@ -926,7 +926,7 @@ input DossierClasserSansSuiteInput {
}
"""
Autogenerated return type of DossierClasserSansSuite
Autogenerated return type of DossierClasserSansSuite.
"""
type DossierClasserSansSuitePayload {
"""
@ -1000,7 +1000,7 @@ input DossierEnvoyerMessageInput {
}
"""
Autogenerated return type of DossierEnvoyerMessage
Autogenerated return type of DossierEnvoyerMessage.
"""
type DossierEnvoyerMessagePayload {
"""
@ -1052,7 +1052,7 @@ input DossierModifierAnnotationAjouterLigneInput {
}
"""
Autogenerated return type of DossierModifierAnnotationAjouterLigne
Autogenerated return type of DossierModifierAnnotationAjouterLigne.
"""
type DossierModifierAnnotationAjouterLignePayload {
annotation: RepetitionChamp
@ -1091,7 +1091,7 @@ input DossierModifierAnnotationCheckboxInput {
}
"""
Autogenerated return type of DossierModifierAnnotationCheckbox
Autogenerated return type of DossierModifierAnnotationCheckbox.
"""
type DossierModifierAnnotationCheckboxPayload {
annotation: Champ
@ -1130,7 +1130,7 @@ input DossierModifierAnnotationDateInput {
}
"""
Autogenerated return type of DossierModifierAnnotationDate
Autogenerated return type of DossierModifierAnnotationDate.
"""
type DossierModifierAnnotationDatePayload {
annotation: Champ
@ -1169,7 +1169,7 @@ input DossierModifierAnnotationDatetimeInput {
}
"""
Autogenerated return type of DossierModifierAnnotationDatetime
Autogenerated return type of DossierModifierAnnotationDatetime.
"""
type DossierModifierAnnotationDatetimePayload {
annotation: Champ
@ -1208,7 +1208,7 @@ input DossierModifierAnnotationIntegerNumberInput {
}
"""
Autogenerated return type of DossierModifierAnnotationIntegerNumber
Autogenerated return type of DossierModifierAnnotationIntegerNumber.
"""
type DossierModifierAnnotationIntegerNumberPayload {
annotation: Champ
@ -1247,7 +1247,7 @@ input DossierModifierAnnotationTextInput {
}
"""
Autogenerated return type of DossierModifierAnnotationText
Autogenerated return type of DossierModifierAnnotationText.
"""
type DossierModifierAnnotationTextPayload {
annotation: Champ
@ -1285,7 +1285,7 @@ input DossierPasserEnInstructionInput {
}
"""
Autogenerated return type of DossierPasserEnInstruction
Autogenerated return type of DossierPasserEnInstruction.
"""
type DossierPasserEnInstructionPayload {
"""
@ -1324,7 +1324,7 @@ input DossierRefuserInput {
}
"""
Autogenerated return type of DossierRefuser
Autogenerated return type of DossierRefuser.
"""
type DossierRefuserPayload {
"""
@ -1361,7 +1361,7 @@ input DossierRepasserEnConstructionInput {
}
"""
Autogenerated return type of DossierRepasserEnConstruction
Autogenerated return type of DossierRepasserEnConstruction.
"""
type DossierRepasserEnConstructionPayload {
"""
@ -1398,7 +1398,7 @@ input DossierRepasserEnInstructionInput {
}
"""
Autogenerated return type of DossierRepasserEnInstruction
Autogenerated return type of DossierRepasserEnInstruction.
"""
type DossierRepasserEnInstructionPayload {
"""