I’m looking for a page looking for JavaScript memory leaks, but I didn’t find anything. My next attack plan is to check ViewState and Session State. ViewState is simple, but session state brings challenges .
Does anyone know of any tricks or tools that can help figure out the size of the session state?
Edit
The session state is InProc.
int totalBytes;
var formatter = new BinaryFormatter();
for(int i = 0; i{
using (var stream = new MemoryStream())
{
formatter.Serialize(stream, Session[i]);
stream. Flush();
totalBytes += stream.Length;
}
}
In addition, I believe that if you enable tracing it will tell you some details about the session (not Ok this, never tried).
I tried to figure out the size of a specific session state. In one of our heavy pages (a lot of data in the table), it Gradually slowed down. The problem was solved by logging out of the system.
I was looking for pages looking for JavaScript memory leaks, but I didn’t find anything. My next attack plan is to check ViewState and Session State. ViewState is simple, but session state brings challenges.
Does anyone know of any tips or tools that can help figure out the size of session state?
Edit
The session state is InProc.
Measure it:
int totalBytes;
var formatter = new BinaryFormatter();
for(int i = 0; i{
using (var stream = new MemoryStream())
{
formatter.Serialize(stream, Session[i]);
stream.Flush();
totalBytes += stream .Length;
}
}
Also I believe if you enable tracing it will tell you some details about the session (not sure about this, never tried it).