httpRuntime shutdownTimeout和IIS设置 [英] httpRuntime shutdownTimeout and the IIS setting

查看:234
本文介绍了httpRuntime shutdownTimeout和IIS设置的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在ASP.Net中遇到了一个问题.在任何Web App配置Web.config文件中,都有一个名为httpRuntime的部分,它具有一个属性:shutdownTimeout.根据MSDN文档,此attr指定在ASP.Net运行时终止工作进程之前允许工作进程的空闲时间多长时间.另一方面,在IIS的ApplicationPool的->默认AppPool->属性->性能选项卡下,有一个设置:空闲20分钟后关闭工作进程".

I met an issue in ASP.Net. In any Web App config Web.config file there is a section called httpRuntime, and it has an attriube: shutdownTimeout. According to MSDN documentation, this attr specify how long the idle time of the worker process is allowed before ASP.Net runtime to terminate the worker process. On another side, under IIS's ApplicationPool's -> Default AppPool -> properties -> performance tab, there is a setting: "shutdown worker process after being idle for (20) minutes".

我猜想在IIS下,此设置适用于所有用于处理传入请求的工作进程,而不仅是特定ASP.Net运行时所在的进程.如果Web.Config的shutdownTimeout尚未生效,则IIS的设置将完成其工作.

I guess that under IIS, this setting is for all worker process which is used to handle incoming request not only the process where a specific ASP.Net runtime resides. And if Web.Config's shutdownTimeout has not taken effect yet, the IIS's setting would then do its work.

但是,根据我的观察,尽管httpRuntime的shutdownTimeout默认值为90秒,但是我的Web应用程序在空闲20分钟后始终会关闭.似乎IIS设置在这方面具有优先权.

However from my observation, although the httpRuntime's shutdownTimeout default value is 90 seconds, my web application was always shut down after idle for 20 minutes. It seems the IIS setting take priority for this aspect.

如果有人可以澄清这一点,我们将不胜感激:我的猜测出了什么问题.

It is much appreciated if somebody could clarify on this: what is wrong with my guess.

推荐答案

我做了一些挖掘,并找到了答案:

I did some digging and found out the answer:

属性shutdownTimeout控制如果ASP.Net运行时要求终止工作进程,则ASP.Net运行时将关闭工作进程多长时间,然后工作程序自行正常退出.

the attriubte shutdownTimeout controls how long the ASP.Net runtime will shut down the worker process before it gracefully exits by itself if it is asked to terminate by the ASP.Net runtime.

这是对的,任何意见都将不胜感激.

Is this right, any opinion is greatly appreciated.

这篇关于httpRuntime shutdownTimeout和IIS设置的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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