只是试图找出我们在生产网站上遇到的一些性能问题。
目前的设置是:
小标准网站实例(1核,1.75gb RAM)MVC3 ASP.NET 4.5 EF5
32位设置
我正在使用“进程中”会话设置,我理解这可能是我的问题的一部分。 我慢慢来。 我使用New Relic监控网站。
我的会话代码,在web.config中是:
<sessionState mode="InProc" timeout="30"> <providers> <add name="DefaultSessionProvider" type="System.Web.Providers.DefaultSessionStateProvider, System.Web.Providers, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" connectionStringName="DefaultConnection" /> </providers> </sessionState>我已经读过“在Proc中”在Azure网站中不起作用,但它对我有用吗? 无论是有效还是有问题,我都不确定。
您对上述建议表示赞赏。
非常感谢。
Just trying to isolate some performance issues we are getting on our production site.
The current setup is :
Small Standard Website instance(1 core, 1.75gb RAM) MVC3 ASP.NET 4.5 EF5
32bit setup
I am using an "in process" session setup which I understand may be part of my issue. I get slow ups. I monitor the site with New Relic.
My session code, in web.config is:
<sessionState mode="InProc" timeout="30"> <providers> <add name="DefaultSessionProvider" type="System.Web.Providers.DefaultSessionStateProvider, System.Web.Providers, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" connectionStringName="DefaultConnection" /> </providers> </sessionState>I have read that "in Proc" does not work in Azure websites, but it does for me? Whether it works and has issues, I am unsure.
Your advice on the above would be appreciated.
Many thanks.
最满意答案
InProc会话管理不应该使您的网站变慢,这是管理会话的最快方式。 只要您只有一个运行代码的实例,InProc会话就可以正常工作。 InProc会话保留在服务器的RAM中,因此一旦您开始使用多个实例,并且负载均衡器决定将用户带到与其登录的实例不同的实例,她将不得不再次登录(在那个新服务器)。
InProc session management should not be making your site slower, it's the fastest way to manage the session. The InProc session will work OK as long as you have only 1 instance running your code. InProc session is mantained in the server's RAM, so as soon as you start using more than 1 instance, and the load balancer decides to take the user to a different instance than the one she logged in, she will have to log in again (on that new server).
更多推荐
发布评论