在Stack Overflow there is the mention that结束时,它可以在间隔完成时重新启动…
By default,application pool recycling is overlapped,which means that the worker process that is to be shut down is kept running until after a new worker process is started. After a new worker process starts,new requests are passed to it. The old worker process shuts down after it finishes processing its existing requests,or after a configured time-out,whichever comes first. This way of recycling ensures uninterrupted service to clients. However,if an application in the application pool cannot run more than one instance of itself at a time,overlapping rotation can be disabled.
在我看来,根据定义,由于cpu消耗过多而终止工作进程将意味着不允许完成挂起的请求(因为它们耗尽了cpu配额).
说到你的主要问题:我没有看到任何让我相信新的工人流程不会自动旋转的东西.您的Stack Overflow链接中的语句确实让我怀疑,IIS使用的算法实际上是否可以将回收与用于测量cpu配额耗尽的计时器的分辨率联系起来.我知道确定的最佳方法是编写cpu浪费的服务器端组件,将其部署到测试环境中,并查看其回收行为的行为.一个简单的组件,它在一个紧密的循环中停留几秒钟,然后返回一个已知的字符串,与一个运行测试工具的客户端相结合,可能就像一个并行的“wget”进程池.用一堆来自客户端的并行请求来锤击它,并报告请求如何获得正确的响应与错误消息等等.(这让我觉得如此愚蠢,不得不求助于这样的事情而不是去看看在源代码…)