ASP.Net Session

前端 未结 13 1340
清酒与你
清酒与你 2020-12-08 07:54

I am wanting to store the \"state\" of some actions the user is performing in a series of different ASP.Net webforms. What are my choices for persisting state, and what are

13条回答
  •  野趣味
    野趣味 (楼主)
    2020-12-08 08:27

    As far as I know, Session is the intended way of storing this information. Please keep in mind that session state generally is stored in the process by default. If you have multiple web servers, or if there is an IIS reboot, you lose session state. This can be fixed by using a ASP.NET State Service, or even an SQL database to store sessions. This ensures people get their session back, even if they are rerouted to a different web server, or in case of a recycle of the worker process.

提交回复
热议问题