开发者

which session type is better for a asp.net internet application

开发者 https://www.devze.com 2023-02-17 06:41 出处:网络
I开发者_如何转开发 am trying to get the pros and cons of the session management techniques i.e. State server, Sql, Inproc

I开发者_如何转开发 am trying to get the pros and cons of the session management techniques i.e. State server, Sql, Inproc

My application is hosted on internet. Any knowledge of which one would be best for which case?

Thanks in advance


On production servers, you should never use InProc to store user sessions, please exclude it from your considerations.

InProc sessions expire when your IIS server stops,restarts or crashes.

Whether to use StateServer or SQL depends on your needs. As a general rule of thumb, If you have access to an ASP.NET StateServer, it is better to store them on your StateServer, separating those user session data from your back-end database, as session data shouldn't be permanently stored.

There are other concerns such as what sort data are stored in your session, serialisation of session data etc, that may affect your decision.

If you could describe more about your application's desire behaviour, we could provide better suggestions.

0

精彩评论

暂无评论...
验证码 换一张
取 消