asp.netrediswebformssession-state

Session State Management Options for a Load Balanced ASP.NET WebForms


I have an older ASP.NET WebForms application. We are in a load balanced environment but have been using IP Persistence up until this point. We would like to move to round robin load balancing.

What are my options at this point to manage session? Is it possible for me to use Redis with WebForms for session state management? I have seen many examples of using an ASPState database on the sql server. Any info on what my options are would be greatly appreciated.

Jason


Solution

  • If you going to rely on session, then the solution is to turn on SQL session state management, since then any server in the form can and will share the same session() state.

    You of course can't use in-memory session, since of course different servers don't share their memory, but with SQL server based sessions, then all servers are using the one same instance of SQL server to manage the session state. So, one possible solution is to turn on (enable) SQL server based session management.