Github user ok2c commented on the issue:
https://github.com/apache/httpcomponents-core/pull/91
@rschmitt The current API has been designed to work well with both HTTP/1.1
and HTTP/2.0. For instance, the initial capacity is out of control for
individual HTTP/2 consumers. They must be prepared to consume at least the
initial amount of data defined by HTTP/2 settings during the HTTP/2 protocol
handshake. The capacity value returned by `#consume` method was necessary to
make the same API work with HTTP/1.1 connections that do not even support a
concept of data capacity. There is no easy way for HTTP/1.1 consumers to make
the event handler aware of the fact that they are not able to process more
data. The only alternative I can think of using different capacity interfaces
for different HTTP protocol versions which would be terrible and hardly any
simpler.
Please do go ahead and try to simplify the APIs as you deem fit, but the
result might well end up being a different API complex in a different way.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]