By Gowtham K
Since the HTTP protocol used by web applications is a stateless protocol - which means that their data is not stored anywhere, and for every web request, a new HTTP connection is opened by the browser - the ASP.NET Core provides sessions for storing user data. This data store is maintained by the ASP.NET Core application itself on the same server as the application. Although ASP.NET Core provides an in-memory session provider that stores sessions, sometimes the load needs to be balanced. In such scenarios, session storage strategies like sticky sessions can be used. We need some distributed Cache Mechanism to overcome this issue.Read full Article
ASP.NET Core application uses the sticky session to tie each session to the specific app instance on an individual server through Application Request Routing module. The sticky sessions can affect the scalability due to improper distribution of load in server. When the requests to the application increase, the server load will increase as well, in such case we need to scale up the server which is very complicated by using sticky session.
The better approach is to use the SQL Server or distributed cache for session storage to overcome the issue in sticky session. However, when it comes to scalable ASP.NET core application, the SQL databases become a performance bottleneck because in SQL the sessions are saved as BLOBs.
On basis of scalability the best approach is using the distributed cache for session storage.Read full Article