Title: Slow introspection query execution for large schemas · Issue #101 · graphql-python/graphql-core · GitHub
Open Graph Title: Slow introspection query execution for large schemas · Issue #101 · graphql-python/graphql-core
X Title: Slow introspection query execution for large schemas · Issue #101 · graphql-python/graphql-core
Description: The graphql-core graphql_sync function takes approximately 20x slower than a module that I wrote that solely executes the introspection query. https://github.com/kensho-technologies/graphql-compiler/blob/main/graphql_compiler/fast_intros...
Open Graph Description: The graphql-core graphql_sync function takes approximately 20x slower than a module that I wrote that solely executes the introspection query. https://github.com/kensho-technologies/graphql-compile...
X Description: The graphql-core graphql_sync function takes approximately 20x slower than a module that I wrote that solely executes the introspection query. https://github.com/kensho-technologies/graphql-compile...
Opengraph URL: https://github.com/graphql-python/graphql-core/issues/101
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Slow introspection query execution for large schemas","articleBody":"The graphql-core `graphql_sync` function takes approximately 20x slower than a module that I wrote that solely executes the introspection query. https://github.com/kensho-technologies/graphql-compiler/blob/main/graphql_compiler/fast_introspection.py\r\n\r\nWith the graphql-core Python library, executing the default introspection query (outputted from `get_introspection_query`) on a schema of around ten thousand types with `graphql_sync` takes 26 seconds to run. Writing my own module that calls the same graphql-core Type resolvers executes the same query on the same schema in 1.37 seconds.\r\n\r\nI'm not sure what exactly is the time sink with the graphql-core's approach, but it might have to do with the generality of `graphql_sync` and thus, computing the next field to resolve at every step, and also `graphql_sync`'s recursive nature. Interestingly, I ran the same query on the same schema using Graphql.js, and the execution took less than 2 seconds (around 1.7 seconds).\r\n\r\nThank you for your time and all the work to port GraphQL.js to Python!","author":{"url":"https://github.com/lonerz","@type":"Person","name":"lonerz"},"datePublished":"2020-08-06T19:02:46Z","url":"https://github.com/graphql-python/graphql-core/issues/101"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:c72fc2e5-82f2-39fb-9995-805e9ed5d475 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | EC60:2AD163:1A31721:234F7D3:6AFFFBAE |
| html-safe-nonce | ef8cd27c5416765a55144ec11f7157606ed2293e8a3e7dfda553a05961ba0064 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFQzYwOjJBRDE2MzoxQTMxNzIxOjIzNEY3RDM6NkFGRkZCQUUiLCJ2aXNpdG9yX2lkIjoiMjIxNzY5MDg5NDYxMjU2MDgxNCIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 1cc2d85c1e4c774d0457d82c4bedb7a3ecca35cd120f0f4da9e35e49b72cff47 |
| hovercard-subject-tag | issue:674536183 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/graphql-python/graphql-core/101/issue_layout |
| twitter:image | https://opengraph.githubassets.com/3401acd61d8bea8d11abf27434e7084b8418b4cf555dedc12df05afd1203469a/graphql-python/graphql-core/issues/101 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/3401acd61d8bea8d11abf27434e7084b8418b4cf555dedc12df05afd1203469a/graphql-python/graphql-core/issues/101 |
| og:image:alt | The graphql-core graphql_sync function takes approximately 20x slower than a module that I wrote that solely executes the introspection query. https://github.com/kensho-technologies/graphql-compile... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | lonerz |
| hostname | github.com |
| expected-hostname | github.com |
| None | 0a0d8686a27478df474dd7415776a7a080cde8838b3cd92ea7601187572e5729 |
| turbo-cache-control | no-preview |
| go-import | github.com/graphql-python/graphql-core git https://github.com/graphql-python/graphql-core.git |
| octolytics-dimension-user_id | 15002022 |
| octolytics-dimension-user_login | graphql-python |
| octolytics-dimension-repository_id | 143207933 |
| octolytics-dimension-repository_nwo | graphql-python/graphql-core |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 143207933 |
| octolytics-dimension-repository_network_root_nwo | graphql-python/graphql-core |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 16a11879678aaf97e2a42c33ee70830aa084fa37 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width