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

graphql: Start collecting and returning errors from remote remote GraphQL endpoints. #5328

Merged
merged 7 commits into from
Apr 30, 2020

Conversation

pawanrawal
Copy link
Contributor

@pawanrawal pawanrawal commented Apr 29, 2020

Earlier while resolving fields, errors returned from GraphQL endpoints were not propagated to the client. Fixed that with a test case. Fixes GRAPHQL-410.

We also now share the same http.Client to resolve fields and queries/mutations. Earlier we were instantiating a new http.Client in makeRequest for resolving each field which is not recommended.


This change is Reviewable

Docs Preview: Dgraph Preview

Copy link
Contributor

@MichaelJCompton MichaelJCompton left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like you've broken the rule about a PR being about just one change ... looks like it's two things here 😉

The error changes look fine.

I want to investigate if there's a better way to the httpClient. Still looks strange to me how it's done.

Reviewable status: 0 of 6 files reviewed, all discussions resolved (waiting on @manishrjain and @MichaelJCompton)

@pawanrawal pawanrawal merged commit 5e59c51 into master Apr 30, 2020
@pawanrawal pawanrawal deleted the pawanrawal/graphql-errors-from-fields branch April 30, 2020 12:15
dna2github pushed a commit to dna2fork/dgraph that referenced this pull request Jul 18, 2020
…phQL endpoints. (dgraph-io#5328)

Earlier while resolving fields, errors returned from GraphQL endpoints were not propagated to the client. Fixed that with a test case. Fixes GRAPHQL-410.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants