Skip to content
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

batched queries do not handle errors correctly #551

Closed
jmiazga opened this issue Aug 17, 2016 · 3 comments
Closed

batched queries do not handle errors correctly #551

jmiazga opened this issue Aug 17, 2016 · 3 comments
Assignees
Labels

Comments

@jmiazga
Copy link

jmiazga commented Aug 17, 2016

I have setup my backend to return an error for 2 separate queries. I made subsequent queries with the apollo client, and they were successfully batched together. Both queries return and error, but each promise was resolved successfully.

If I turn off batching, two separate calls are made to the backend and each promise was rejected as expected.

Let me know if you need anymore information.

@stubailo
Copy link
Contributor

@Poincare any thoughts? Perhaps in this case the best solution is to use #531 (transport batching, rather than query merging)

@jmiazga what GraphQL server are you using?

@Poincare
Copy link
Contributor

I don't think there's a good solution to doing error handling (esp. network error handling) for query merging. The right way to do this is probably through #531 once it is merged (probably by the middle of next week).

The successfully resolved promises does seem like a bug, however. @jmiazga if you could add a test to QueryManager that reproduces that issue, that would be incredibly helpful!

@jmiazga
Copy link
Author

jmiazga commented Aug 22, 2016

@stubailo we are using graphql-java

@Poincare ill try to add one shortly

@Poincare Poincare self-assigned this Aug 26, 2016
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 17, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

3 participants