在共享主机上保持 ASP.NET4.0 页面的温暖
我有一个(但)很少访问的页面部署在共享托管环境上。目前,我的访客数量非常少,比如每天 1 位访客。
看起来 IIS 7.0 在闲置太久后“删除”了我的网站。此后第一个页面加载需要 30 秒或更长时间。 由于访问量很少,实际上我所有的访问者都为网站启动付费。 (恢复站点后,页面加载正常为1-3秒。)
我了解ASP.NET4.0和IIS7.5的应用程序预热功能,但由于给定的共享托管环境,我无法利用它们。
如何人为地让我的网站保持活力?
I have a (yet) rarely visited page deployed on a shared hosting environment. Currently, I get very low number of visitors, like 1 visitor/day.
It looks like that IIS 7.0 "drops" my site after being idle too long. The first pageload after this takes 30 seconds or more. Due to the rare visits, actually all my visitors pay for the site-startup.
(After reviving the site, the page load normalizes to 1-3 seconds.)
I know about Application Warm-Up features of ASP.NET4.0 and IIS7.5, but due to the given shared hosting environment, I have no way to utilize them.
How can I keep my site artificially alive?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
在
Global.asax
中启动一个计时器,并通过简单的WebRequest
“访问”多个页面来使其自行启动。Fire up a timer in your
Global.asax
and make it poke itself by "visiting" several pages via simpleWebRequest
.尝试免费帐户:http://www.montastic.com/
您只需输入您的网址并告诉它每 30 分钟访问一次。
这将使您的网站保持正常运行
Try the free account on: http://www.montastic.com/
You just enter in your url and tell it to visit it every 30 mins.
This will keep your site up