-
-
Notifications
You must be signed in to change notification settings - Fork 137
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pregenerate and Caching GraphqlSchema with Pickle #222
Comments
Pickling schemas should work and is tested as part of the test suite since GraphQL-core 3.3.0a2. Probably you're using an older version of GraphQL-core. |
I just upgraded and now I am getting this error
|
Looks like this happens because the Graphene schema wrapper or some types created by it cannot be pickled. Unfortunately this cannot be solved here. The Graphene project would be the right place to ask for help. |
Thank you so much for your prompt reply. You are wonderful!!! |
I am running graphene-django on serverless
I am posting here because Schema loading is in GraphqlSchema.
often time when there is cold start and the cold start is very slow because the schema loading is very slow, 1xx+ms for a fairly small schema. For larger service the schema load time can be over 3xx-4xx+ms
(please don't tell me to stop running serverless, thx)
I am trying to pregenerate and cache the Schema for production environment,
I tried to pickle the schema because I saw #173 , but it isn't working. I am getting the error
Can't pickle local object 'TypeMap.create_objecttype.<locals>.interfaces
Or are there other way to speed up start time? Maybe write it in another language as extension?
The text was updated successfully, but these errors were encountered: