[英]Classic ASP website using windows authentication takes a while to load the first time after some time of inactivity
My company has a Classic ASP website, hosted in IIS 10 on Windows Server 2016, that I have been tasked with optimizing the load time for.我的公司有一个经典的 ASP 网站,托管在 Windows Server 2016 上的 IIS 10 中,我的任务是优化加载时间。 I have done everything else to get the page running optimally, however after about 5 or 10 minutes of inactivity, the page load of any given page takes about 10-15 seconds to load (then it runs smoothly afterwards until the next 5 or 10 minutes of inactivity).
我已经做了所有其他事情来让页面以最佳方式运行,但是在大约 5 或 10 分钟不活动后,任何给定页面的页面加载需要大约 10-15 秒来加载(然后它会平稳运行直到接下来的 5 或 10 分钟不活动)。 I have already disabled the idle timeout and the played with the recycling properties, so I have already ruled that out.
我已经禁用了空闲超时并使用了回收属性,所以我已经排除了这种可能性。 I have even played with the keep-alive timeout header value which has no affect on the behavior in question.
我什至玩过 keep-alive timeout 标头值,它对相关行为没有影响。
What I believe I have narrowed it down to is the authentication.我相信我已将其缩小到身份验证。 The website uses Windows Authentication and expects a company domain account to enter the admin area of the site.
该网站使用 Windows 身份验证,并希望公司域帐户进入该网站的管理区域。 And, if I access any part of the site that doesn't require authentication, this page load delay does not happen.
而且,如果我访问不需要身份验证的站点的任何部分,则不会发生此页面加载延迟。 I am thinking that maybe our company has a domain policy in place that automatically logs a user out of a session after some specific amount of time of inactivity.
我在想,也许我们公司有一个域策略,在一段特定的不活动时间后自动将用户从会话中注销。 And so maybe the site is just re-authenticating after each automatic logout which causes the delay.
因此,也许该站点只是在每次自动注销后重新进行身份验证,这会导致延迟。 Any ideas?
有任何想法吗?
Try adding the following settings in the webconfig.尝试在 webconfig 中添加以下设置。 It will set the session state expire after 30 minutes.
它将设置会话状态在 30 分钟后过期。
<configuration>
<system.web>
<sessionState timeout="30"></sessionState>
</system.web>
</configuration>
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.