semyon-levin-workato commented on code in PR #743:
URL:
https://github.com/apache/httpcomponents-client/pull/743#discussion_r4146586606
##########
httpclient5/src/main/java/org/apache/hc/client5/http/impl/async/ContentCompressionAsyncExec.java:
##########
@@ -150,9 +150,6 @@ public AsyncDataConsumer handleResponse(final HttpResponse
rsp,
throw new HttpException("Unsupported
Content-Encoding: " + codec);
}
}
- rsp.removeHeaders(HttpHeaders.CONTENT_ENCODING);
Review Comment:
Hi @ok2c,
I understand that the PR is merged and released, but it introduced
regressions in code that relies in values of these headers like Spring's
`StringHttpMessageConverter`.
Before the PR:
1. A gzipped response comes
2. It's decompressed
3. These headers are removed
4. Code that relies on the headers can't find them and don't rely on them
Now:
1. A gzipped response comes
2. It's decompressed
3. The headers represent the state **before** decompression
4. Code that relies on the headers (e.g., `Content-Length`) becomes broken
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]