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
Response.InputStreamBody's toString method closes input stream. #1208
Labels
proposal
Proposed Specification or API change
Comments
Hi, |
I agree we should change this. My suggestion would be to not ready the data in |
kdavisk6
added
proposal
Proposed Specification or API change
and removed
feedback provided
Feedback has been provided to the author
labels
Dec 29, 2020
kdavisk6
added a commit
to kdavisk6/feign
that referenced
this issue
Dec 29, 2020
Fixes: OpenFeign#1208 Forgot to add Defate support and removed the implicit parsing of the body during toString. This was also brought up in OpenFeign#1208 and it came up during testing of this change. Users should be using our `asReader` and other methods to access the response body.
kdavisk6
added a commit
to kdavisk6/feign
that referenced
this issue
Dec 31, 2020
Fixes: OpenFeign#1208 Forgot to add Defate support and removed the implicit parsing of the body during toString. This was also brought up in OpenFeign#1208 and it came up during testing of this change. Users should be using our `asReader` and other methods to access the response body.
kdavisk6
added a commit
that referenced
this issue
Jan 8, 2021
Fixes: #934, #1208 This change updates the Input Stream handling when using the Default client implementation to detect when a response is `gzipped` and wrap it in a `GZipInputStream`. This addresses any issues related to compression when using the default client. In addition, removed the implicit parsing of the body during toString. This was also brought up in #1208 and it came up during testing of this change. Users should be using our `asReader` and other methods to access the response body. * Adding Deflate support * Added Deflate Support and removed implicit response body reading * Refactored Gzip and Deflate Conditions * Corrected formatting and line-endings
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The toString() on Response.InputStreamBody causes the underlying inputstream to be closed.
0a0ff3f
When using IntellJ the default behavior while debugging is to call any toString methods that have been overridden.
You can disable this functionality but it would be nice if the toString method just returned a copy of the data.
I have opened a ticket with IntelliJ to allow an 'excludes' list.
https://youtrack.jetbrains.com/issue/IDEA-237009
Thoughts?
The text was updated successfully, but these errors were encountered: