-
Notifications
You must be signed in to change notification settings - Fork 639
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
[4.x]: GraphQL schema is no longer lazy loaded #15429
Comments
Thanks for pointing that out. On second look, the problematic query in #13622 could have been solved by putting the fragment after the main query, so I probably should have just recommended doing that. I can’t revert the change without potentially breaking things at this point, but I did just add a new |
Thanks @brandonkelly! This is great and exactly what we needed. |
Note: I tried updating my |
What happened?
Description
The entire GraphQL schema is read in on every request, regardless of the query complexity or query needs. Because of this our web requests are rather slow (1.5s instead of 500ms). This adds up when you have a headless front-end making 3-4 requests per page.
I believe I've identified the reason for this, here: b9d8ec5
Steps to reproduce
{ping}
.Expected behavior
The schema should be lazy loaded, where possible.
Actual behavior
The entire schema is read every time.
Notes
I'm not sure how realistic is to reverse this decision or if there could be a config for it? Basically wondering what sort of issues I'd run in to if I tried to force a lazy schema.
Craft CMS version
4.9.5
PHP version
8.3.4
Operating system and version
Ubuntu
Database type and version
MySQL 8
Image driver and version
n/a
Installed plugins and versions
No response
The text was updated successfully, but these errors were encountered: