Closed inwaar closed 1 year ago
Hi @inwaar,
the PR webonyx/graphql-php#557 basically makes possible to set closures as GraphQL field types, making them lazy loadable. This feature was introduced in webonyx/graphql-php
v14.0.0. The current stable version of GraphQL Bundle is 0.13.4 and it uses webonyx/graphql-php
v0.13.5, which means you cannot use closures as field types.
To add this optimization into current stable version, we first need to update the ' webonyx' dependency and update the generator class. I don't have time right now to do it and I don't believe anyone else in the Overblog team has.
The next major version (1.0) will use webonyx/graphql-php
v14 and it will have this optimization. You can consider using 1.0 instead of 0.13. It was planned to be released until the end of this year, but I don't know whether it will be. Only @mcg-web can answer this question.
One more thing to take into account when chosing a bundle version: I noticed a request time degradation from 0.12 to 0.13 and from 0.13 to 1.0 (master). I believe this is due to increasing codebase of the project, as it gets more features. For this reason we decided to split the bundle into separate modules in the next versions, so that you could install only features you need, something like this:
overblog/graphql-core
overblog/graphql-annotations
overblog/graphql-validator
overblog/graphql-security
overblog/graphql-profiler
overblog/graphql-expression-language
overblog/graphql-relay
The work on this has not started yet and I'm not sure when this will be implemented.
P. S. I would like to see how you performed benchmarks if possible.
1.0 milestone will be postpone for some months so we can finish some major features. We will add the support of 14.0 in the next release 0.11, 0.12 and 0.13 of the bundle.
We will add the support of 14.0 in the next release 0.11, 0.12 and 0.13 of the bundle.
Hi @mcg-web Great to hear that! Is there any ETA when it could be released? (We unfortunately can not use version 1.0 since it requires a newer Symfony version).
@murtukov I don't have enough samples in blackfire but it look similar of what mentioned in webonyx/graphql-php#425 Also I see thousands calls of this method
We are considering to start using this bundle in production. So far we see one stopper - it adds around 300-400 extra ms to each request comparing to the current serializer we use for RESTful API.
It looks quite similar to https://github.com/webonyx/graphql-php/issues/425 And It seems that it was solved by https://github.com/webonyx/graphql-php/pull/557
Is there any chance branch 13 to include this optimization?