Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #108689 > unrolled thread

Re: OT: limit number of connections from browser to my server?

Started byGrant Edwards <grant.b.edwards@gmail.com>
First post2016-05-16 19:33 +0000
Last post2016-05-17 12:30 +1000
Articles 2 — 2 participants

Back to article view | Back to comp.lang.python

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: OT: limit number of connections from browser to my server? Grant Edwards <grant.b.edwards@gmail.com> - 2016-05-16 19:33 +0000
    Re: OT: limit number of connections from browser to my server? Steven D'Aprano <steve@pearwood.info> - 2016-05-17 12:30 +1000

#108689 — Re: OT: limit number of connections from browser to my server?

FromGrant Edwards <grant.b.edwards@gmail.com>
Date2016-05-16 19:33 +0000
SubjectRe: OT: limit number of connections from browser to my server?
Message-ID<mailman.31.1463427306.19823.python-list@python.org>
On 2016-05-16, Peter Otten <__peter__@web.de> wrote:
> Grant Edwards wrote:
>
>> This is not Python specific, though I'm turning to Python to do some
>> experimentation and to try to prototype a solution.
>> 
>> Is there any way to limit the number of connections a browser uses to
>> download a web page?  Browser writers seems to assume that all https
>> servers are massively parallel server farms with hardware crypto
>> support.
>> 
>> So, when a browser wants to load a page that has the main html file, a
>> css file, a javascript library or two, and a few icons and background
>> bitmaps, they browser opens up a half-dozen SSL connections in
>> parallel.
>
> [brainstorm-mode on]
>
> I think HTTP/2 allows multiple requests over a single TCP connection.

HTTP 1.1 did also.  And our server supports it.  The problem is that
modern browsers won't wait and send requests serially over a single
connection.  They try to "optimize" page load times by opening as many
connections as they cat right away and requesting everything in
parallel.  When the server has a single CPU, that just wastes a lot of
time -- particulary when connections have a high per-connection
overhead like SSL does.

-- 
Grant Edwards               grant.b.edwards        Yow! Is this TERMINAL fun?
                                  at               
                              gmail.com            

[toc] | [next] | [standalone]


#108704

FromSteven D'Aprano <steve@pearwood.info>
Date2016-05-17 12:30 +1000
Message-ID<573a8261$0$1584$c3e8da3$5496439d@news.astraweb.com>
In reply to#108689
On Tue, 17 May 2016 05:33 am, Grant Edwards wrote:

> The problem is that
> modern browsers won't wait and send requests serially over a single
> connection.  They try to "optimize" page load times by opening as many
> connections as they cat right away and requesting everything in
> parallel.

(Even more OT for the OT discussion.)

And the funny[1] thing about this is, for all these optimizations, web
browsers in 2016 browsing the web in 2016 are generally *slower* than 1996
browsers browsing the web in 1996.

And it has been like this for coming close to a decade now. At least two
major reasons: websites are even more full of cruft than ever before, and
the mobile web.

http://www.antipope.org/charlie/blog-static/2008/05/why_your_internet_experience_i.html

http://www.wired.com/insights/2014/11/the-web-is-getting-slower/



[1] In the sense of "I must laugh or else I will cry".

-- 
Steven

[toc] | [prev] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web