IIS 8.5的多少个并发请求设置 [英] how many concurrent requests settings for IIS 8.5

查看:241
本文介绍了IIS 8.5的多少个并发请求设置的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在IIS 8.5中可以执行多少个并发请求?

How many concurrent requests can be executed in IIS 8.5?

我找不到在IIS 8.5中可以执行多少个并发请求的正确值

I could not find proper values for how many concurrent requests can be executed in IIS 8.5

我发现以下2个不同的值:

As I found out below 2 different values:


  1. 默认情况下,IIS 8.5可以根据aspnet.config中的 MaxConcurrentRequestsPerCPU 设置处理5000个并发请求

  1. By default IIS 8.5 can handle 5000 concurrent requests as per MaxConcurrentRequestsPerCPU settings in aspnet.config

在machine.config中,maxconnection每个CPU默认为2。因此,如果有6个核心CPU,则默认情况下可能有12个并发请求。

In machine.config, the maxconnection is 2 per CPU as default. So if have 6 core CPU then 12 concurrent requests are possible by default.

所以我想知道对于IIS 8.5的并发请求,1是正确的,Point 2是正确的。

So I would like to know that Point 1 is right or Point 2 is right for concurrent requests for IIS 8.5.

推荐答案

假设您正在使用ASP.NET应用程序,执行的并发请求可能会根据编写应用程序代码的方式以及用于运行该应用程序的框架版本(2.0、3.5、4+等)而有所不同。另外,您对并发请求的最大连接感到困惑。两者是两个不同的东西。

Assuming that you are using ASP.NET application, the concurrent requests executed can vary based on the way the application code is written and the framework version you are using to run the application(2.0,3.5,4+ etc). Also You are confusing with max connect with concurrent requests.Both are two different things.

要了解更多详细信息,请阅读msdn博客 IIS 7.5,IIS 7.0和IIS 6.0上的ASP.NET线程使用情况

For more detailed understanding please read msdn blog ASP.NET Thread Usage on IIS 7.5, IIS 7.0, and IIS 6.0 .

总结



  1. 中的MaxConcurrentRequestsPerCPU HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\ASP.NET\2.0.50727.0 确定并发请求数每个CPU。默认情况下,它不存在,并且每个CPU的请求数限制为12

  1. MaxConcurrentRequestsPerCPU within HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\ASP.NET\2.0.50727.0 determines the number of concurrent requests per CPU. By default, it does not exist and the number of requests per CPU is limited to 12

如果您的asp.net应用程序完全是异步请求,则默认MaxConcurrentReqeustsPerCPU的上限为12个,因此将MaxConcurrentRequestsPerCPU的设置提高为一个很高的数字。

If your asp.net application is written entirely asynchronous requests, the default MaxConcurrentReqeustsPerCPU limit of 12 is less and increasse this setting MaxConcurrentRequestsPerCPU to a very high number.

Maxconnection 是每个HTTP协议。任何应用程序只能向任何服务器发出两个并发请求。例如您的浏览器(IE 6,7)只能与您的www.example.com建立两个连接。但是为了提高速度,许多浏览器当前同时建立了6个以上的同时连接(在chrome,firefox和IE中不同)。类似地,当您的服务器应用程序向Web服务或rest API发出请求时,客户端就是您的应用程序,并且maxconnection会强制执行对于同一服务器(其余端点),只允许建立两个连接。

Maxconnection is the setting per HTTP protocol.Any applicaion can only make two concurrent requests to any server.e.g. Your browser(IE 6,7) can make only two connection to your www.example.com. But for speed improvement ,many of the browsers currently make more than 6 simultaneous connections (vary in chrome,firefox and IE).Similarly when your server application make a request to a webservice or a rest API,the client is your application and maxconnection enforces that for the same server(rest end point),you are allowed to make only two connections .


在ASP.NET中增加maxconnection应用程序,以编程方式设置
System.Net.ServicePointManager.DefaultConnectionLimit,例如Application_Start中的
您可以将其设置为Int32.MaxValue

To increase maxconnection in an ASP.NET application, set System.Net.ServicePointManager.DefaultConnectionLimit programatically, from Application_Start, E.g. You can set this to Int32.MaxValue

希望这会有所帮助!

这篇关于IIS 8.5的多少个并发请求设置的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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