★ wanayoo — archive 1999 https://github.com/graphql-java/graphql-java/pull/1567Nouvelle recherche | Portail wanayoo
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

Allow and process DataFetcherResult as an item for GraphQL List fields. #1567

Conversation

@dimdimych
Copy link
Contributor

@dimdimych dimdimych commented Jun 10, 2019

Issue #1559 outlines a lack of control over list items in fetcher result for a list field, in particular, the inability to set a localContext for each item of a list. This pull request modifies list result handling in ExecutionStrategy class allowing an instance of DataFetcherResult as an item of a list. After the improvement, individual list items DataFetcherResult are handled the same way as a regular field's value of DataFetcherResult type: errors are added to query result, localContext for child nodes of the item is set.

Copy link
Member

@bbakerman bbakerman left a comment

Thanks for this. This is an elegant solution. It seems the existing code handled this really neatly (which is a change ;) )

@bbakerman bbakerman added this to the 13.0 milestone Jun 12, 2019
@bbakerman bbakerman requested a review from andimarek Jun 12, 2019
@bbakerman bbakerman merged commit e994f41 into graphql-java:master Jun 12, 2019
1 check passed
1 check passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@dimdimych dimdimych deleted the dimdimych:1559-allow-DataFetcherResult-as-an-item-of-list branch Jun 12, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

3 participants
You can’t perform that action at this time.