Configuring a Session State Store
By default, Session
state is stored in memory in the same process as the ASP.NET process. There are two significant disadvantages to storing Session
state in the ASP.NET process.
First, in-process Session
state is fragile. If your application restarts, all Session
state is lost. A number of different events can cause an application restart. For example, modifying the web configuration file or errors in your application both can cause an application restart.
Second, in-process Session
state is not scalable. When Session
state is stored in-process, it is stored on a particular web server. In other words, you can’t use in-process Session
state with a web farm.
If you need to implement a more robust version of
Get ASP.NET 4 Unleashed now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.