Click here to Skip to main content
15,888,325 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hello all

I have a simple ASP.NET application that has a form and then it query a database for a result, during this operation cycle the application uses the session variable 2 or 4 time (it stores a DateTime object and a boolean variable, could be more if some button is pressed more than once). My question is how to determine the way I'm using the Session variable is affecting performance in a noticeable way? Not for my case only but in general. I have read this article and I did not understand it.

Thanks!.
Posted
Updated 25-Jun-14 21:22pm
v2

1 solution

Refer - Chapter 6 — Improving ASP.NET Performance -> Session State[^].
Quote:
To ensure optimized session state performance, follow these guidelines:
  • Prefer basic types to reduce serialization costs.
  • Disable session state if you do not use it.
  • Avoid storing STA COM objects in session state.
  • Use the ReadOnly attribute when you can.
Also do read the Blog - SessionState Performance[^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900