HTTP每个主机的限制并发连接......每标签,浏览器实例或全球性的? [英] HTTP simultaneous connections per host limit... are per tab, browser instance or global?

查看:151
本文介绍了HTTP每个主机的限制并发连接......每标签,浏览器实例或全球性的?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

根据HTTP规范(w3.org/Protocols/rfc2616/rfc2616-sec8.html#sec8.1.4),HTTP客户端应该限制他们的连接:

According to the HTTP Specification (w3.org/Protocols/rfc2616/rfc2616-sec8.html#sec8.1.4), HTTP clients should limit their connections:

这是使用永久连接应该限制他们维持到给定服务器的并发连接数的客户端。单用户客户端不应该保持与任何服务器或代理超过2个连接。

Clients that use persistent connections SHOULD limit the number of simultaneous connections that they maintain to a given server. A single-user client SHOULD NOT maintain more than 2 connections with any server or proxy.

不同的厂商有不同的实现此限制: HTTP: //www.stevesouders.com/blog/2008/03/20/roundup-on-parallel-connections/

Different vendors implement this limit differently: http://www.stevesouders.com/blog/2008/03/20/roundup-on-parallel-connections/

不过。这是否限制每个标签应用,每个浏览器实例或全局为浏览器的所有实例?被认为是一个标签或独立标签的一部分?弹出窗口(对话)

But. does this limitation applies per tab, per browser instance or globally for all the instances of the browser? Are pop-ups (dialogs) considered part of a tab or independent tabs?

对于相同的WebSockets,并每出身的连接限制每个标签,浏览器实例或全局应用于?

Same for websockets, does the limit on connections per origin applies per tab, browser instance or globally?

推荐答案

浏览器

实施细则也必然是不同的浏览器,浏览器版本或互联网连接速度(IE8使用在拨号2个连接和6个其他方式)。

The implementation details are bound to be different for different browsers, browser versions or internet connection speeds (IE8 uses 2 connections on dial-up and up to 6 otherwise).

此外,这些限制通常是用户可配置(即network.http.max - 连接 - 每个服务器在Mozilla),一个不应该假定基于浏览器版本的具体数值。实际值可能是一个脚本访问虽然,如window.maxConnectionsPerServer在IE中。

Also, these limits are usually user-configurable (i.e. network.http.max-connections-per-server in Mozilla) and one shouldn't assume specific values based on the browser version. The actual value might be accessible to a script though, such as window.maxConnectionsPerServer in IE.

不过。这是否限制每个标签应用,每个浏览器实例或全局为浏览器的所有实例?

But. does this limitation applies per tab, per browser instance or globally for all the instances of the browser?

唯一的相关资料片,我发现这是关于IE(<一个href=\"http://social.msdn.microsoft.com/Forums/ie/en-US/a46bb0ba-419d-43ec-ad1b-f9596d508ca3/simultaneous-http-connection-limit\" rel=\"nofollow\">http://social.msdn.microsoft.com/Forums/ie/en-US/a46bb0ba-419d-43ec-ad1b-f9596d508ca3/simultaneous-http-connection-limit):

The only relevant piece of information I found was this regarding IE (http://social.msdn.microsoft.com/Forums/ie/en-US/a46bb0ba-419d-43ec-ad1b-f9596d508ca3/simultaneous-http-connection-limit):

连接限制每个进程,浏览器会做出有关进程创建一个网站的所有者你不能真正改变的决心。这个过程可能多个标签/窗口之间共享也可能不会,这取决于很多因素,你的控制范围之外

The connection limit is per process, the browser will make the determination about process creation as a web site owner you can't really change that. The process may be shared between multiple tabs/windows or it may not, it depends on many factors outside your control

有关浏览器的更多最新数据可在www.browserscope.org/?category=network

More current data about browsers can be found at www.browserscope.org/?category=network

RFC

有是淘汰了RFC2616(如获批准)的最新草案。
援引相关部分(从的http:/ /tool​​s.ietf.org/html/draft-ietf-httpbis-p1-messaging-21#section-6.2.3 ):

There is an updated draft which obsoletes RFC2616 (if approved). Citing the relevant part (from http://tools.ietf.org/html/draft-ietf-httpbis-p1-messaging-21#section-6.2.3):

客户端应该限制同时连接的数量,它们
     维持到一个给定的服务器。

6.2.3. Concurrency

Clients SHOULD limit the number of simultaneous connections that they maintain to a given server.

previous的HTTP版本,得到作为连接的特定数量的
     天花板上,但是这被认为是不切实际的许多应用。
     其结果是,本说明书不特定最大授权
     连接的数量,而是鼓励客户端是
     保守打开多个连接时。

Previous revisions of HTTP gave a specific number of connections as a ceiling, but this was found to be impractical for many applications. As a result, this specification does not mandate a particular maximum number of connections, but instead encourages clients to be conservative when opening multiple connections.

多个连接通常用于避免头的行
     堵的问题,其中一个是需要显著服务器 - 要求
     侧处理和/或具有大的有效载荷块的后续请求
     上相同的连接。然而,每个连接消耗服务器
     资源。此外,使用多个连接可引起
     不良的副作用在拥挤的网络。

Multiple connections are typically used to avoid the "head-of-line blocking" problem, wherein a request that takes significant server- side processing and/or has a large payload blocks subsequent requests on the same connection. However, each connection consumes server resources. Furthermore, using multiple connections can cause undesirable side effects in congested networks.

注意,服务器可能会拒绝他们认为滥用的流量,
     包括从客户端连接的数量过多

Note that servers might reject traffic that they deem abusive, including an excessive number of connections from a client.

这篇关于HTTP每个主机的限制并发连接......每标签,浏览器实例或全球性的?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆