Open nosedova opened 1 week ago
Describe the bug
Hello. The bug is about performance reduce when query result is empty.
To Reproduce
Steps to reproduce the behavior:
uncomment https://github.com/introproventures/graphql-jpa-query/blob/m…
Run test https://github.com/introproventures/graphql-jpa-query/blob/m…
See console
There are 2 sql queries in the output. First query didn't return keys and second query select all rows again. When database is large and there is a lot of tables - it take several seconds to execute second query.
Expected behavior
Only one query has been executed
Additional context
This can be fixed by adding to https://github.com/introproventures/graphql-jpa-query/blob/m…
if (queryKeys.isEmpty()) { return pagedResult.build(); }
Describe the bug
Hello. The bug is about performance reduce when query result is empty.
To Reproduce
Steps to reproduce the behavior:
uncomment https://github.com/introproventures/graphql-jpa-query/blob/m…
Run test https://github.com/introproventures/graphql-jpa-query/blob/m…
See console
There are 2 sql queries in the output. First query didn't return keys and second query select all rows again. When database is large and there is a lot of tables - it take several seconds to execute second query.
Expected behavior
Only one query has been executed
Additional context
This can be fixed by adding to https://github.com/introproventures/graphql-jpa-query/blob/m…