-
Notifications
You must be signed in to change notification settings - Fork 320
GraphQlClient#retrieve does not raise FieldAccessException for failures at a path nested below the target field #499
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
Comments
Do you mean that
We raise The only other option is for |
If you would like us to look at this issue, please provide the requested information. If the information is not provided within the next 7 days this issue will be closed. |
Thanks for the response. I do understand that an exception can only be expected after the Mono is subscribed too. |
No worries, take your time. |
I reproduced the situation: If you run the tests in the class ClientTest, they show that a FieldAccessException is only thrown if the the Root data object is missing, and not if the Branch data object is missing. |
Thanks for the repro. It looks like |
I agree. |
On closer look, the Javaodc for In the mean time, for 1.0.x, we can still correct the behavior for |
I ended up deprecating While making changes I've also noticed one more related thing that needed a change, see #525. |
I love that there is a Spring GraphQL library available. Thanks.
The javadoc for the retrieve method states:
throws FieldAccessException if the target field has any errors, including nested errors.
To me this suggests that a FieldAccessException is thrown if the results are partial. Yet if I test it, non is thrown. My suggestion would be to clarify this in the javadoc.
So the current only method to determine if a result is partial is probably to use the execute() method. Is that correct?
Background of my questions....
I retrieve a large data structure using graphql. When I receive a partial result in the GraphQlClient, I want to be able to easily determine they are partial, without checking all the data. In other words, check if any field errors are returned.
To make the retrieval of data easy I use the 'retrieve' method. But I see no way to check if the results are partial and what the returned errors are. Do I miss something?
The text was updated successfully, but these errors were encountered: