If I update session state, should I lock it, too? Are concurrent accesses by multiple requests executing on multiple threads a concern with session state?



If I update session state, should I lock it, too? Are concurrent accesses by multiple requests execu..

Answer / kumar saurabh

Concurrent accesses aren't an issue with session state, for two reasons. One, it's unlikely that two requests from the same user will overlap. Two, if they do overlap, ASP.NET locks down session state during request processing so that two threads can't touch it at once. Session state is locked down when the HttpApplication instance that's processing the request fires an AcquireRequestState event and unlocked when it fires a ReleaseRequestState event.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More ASP.NET Interview Questions

What is session state server?

0 Answers  


How many types of Cookies are available in ASP.NET?

0 Answers   MindCracker,


What is the difference between visual basic and asp.net?

0 Answers  


What are the action filters available in asp.net mvc

1 Answers   TCS,


Describe the role of inetinfo.exe, aspnet_isapi.dll and aspnet_wp.exe in the page loading process

1 Answers   HCL, Siebel Systems, Visual Soft,


Explain login control and form authentication.

0 Answers  


Explain different authentication modes in asp.net?

0 Answers  


What can we do with asp.net?

0 Answers  


What is difference between session and cookies in asp net?

0 Answers  


What is the latest version of asp.net?

0 Answers  


Explain the different types of assemblies?

0 Answers  


accessing a textbox that was created dynamically? for (int i = 0; i < t1; i++) { TextBox t2 = new TextBox(); t2.ID = "adf" + i; PlaceHolder1.Controls.Add(t2); } accessing data entered in the above created controls.

1 Answers  


Categories