HTTP/2 Concurrent streams question

Michael McMahon michael.x.mcmahon at oracle.com
Wed Nov 7 18:08:53 UTC 2018


That's useful feedback Simone. It sounds like this is a somewhat 
different issue though.
How would you recommend determining when to open a new connection to 
maximise
throughput?

Thanks,
Michael.

On 07/11/2018, 12:00, Simone Bordet wrote:
> Hi,
>
> On Wed, Nov 7, 2018 at 11:44 AM Michael McMahon
> <michael.x.mcmahon at oracle.com>  wrote:
>> Hi,
>>
>> This is the right place to ask! It was implemented that way because RFC 7540
>> recommends that:
>>
>>     Clients SHOULD NOT open more than one HTTP/2 connection to a given
>>     host and port pair, where the host is derived from a URI, a selected
>>     alternative service [ALT-SVC], or a configured proxy.
>>
>> One workaround would be to create a second HttpClient in that situation.
>  From the Jetty experience in the field, opening just one connection is
> most often impractical.
>
> The first reason is that the typical session flow control window will
> be (almost) immediately exhausted and you get a large performance hit
> due to the flow control frames roundtrips.
> The second reason is that even enlarging the session flow control
> window to very large values, you then end up hitting TCP flow control,
> with the same effects on performance.
>
> Opening few connections (many many less that you would with HTTP/1.1)
> showed to be a good compromise between resource utilization and
> performance (and outperforms HTTP/1.1).
>


More information about the net-dev mailing list