J
Justin
Right now, I am managing session state through SQLServer (sessionState
mode="SQLServer").
Any time I am accessing session variable, I know there will be roundtrip
(server hosting the application code to the server hosting the session).
My question is if I am accessing the session variable 5 times in a function,
will this cause 5 roundtrips to the server? (of course you can store session
in a local variable and access that 5 times but I am just curious whether
ASP.NET caches that value). So will the following code cause 5 roundtrips
or 1 roundtrip?
void test()
{
int O = Session["Test"];
int K = Session["Test"];
int L = Session["Test"];
int M = Session["Test"];
int N = Session["Test"];
}
Thanks
mode="SQLServer").
Any time I am accessing session variable, I know there will be roundtrip
(server hosting the application code to the server hosting the session).
My question is if I am accessing the session variable 5 times in a function,
will this cause 5 roundtrips to the server? (of course you can store session
in a local variable and access that 5 times but I am just curious whether
ASP.NET caches that value). So will the following code cause 5 roundtrips
or 1 roundtrip?
void test()
{
int O = Session["Test"];
int K = Session["Test"];
int L = Session["Test"];
int M = Session["Test"];
int N = Session["Test"];
}
Thanks