Open chipaau opened 7 years ago
It's a known issue. I'm actively working on next version of API lib.
@chipaau these problems were solved in new limoncello-json-api
currently am using my own integration of laravel with limoncello. Is there an easy way to integrate or update my integration to this library.
Despite they are similar from the first look they use different PHP stacks. The new one is based on PSR7 (Zend) and Doctrine as the old one on Symfony and Eloquent. I'm currently migrating a project with 50+ Schemes to new limoncello. With systems of such scale term 'easy' harldy applicable ) I can only say I tried to make it easier. Main parts such as Models and Schemes are not identical but definitely similar so code could be reused with minor changes. API level work with database so obviously more changes would be on this level.
For size of demo app I am familiar with (5 schemes, not much business logic on API level) I would say it would take for me maybe a day to migrate.
Firstly it seems, when schemas involve relation loading, queries are running two times. Also does jsonapi require loading the included resources, when the include paths are not given in the request, i am asking this because it's querying unnecessary data, which is actually not requested by the client. Please clarify this to me, because i'm trying to minimize the database queries, by eliminating the relationships loading, if request does not includes and include paths. Thank you