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 does aspcompat="true" mean?

0 Answers  


How does ASP.NET framework maps client side events to Server side events.?

0 Answers  


How long the items in ViewState exists?

0 Answers   SwanSoft Technologies,


What property must you set, and what method must you call in your code, in order to bind the data from some data source to the Repeater control?

4 Answers  


How to make paging concepts in datagrid in ASP.NET?

0 Answers   Sans Pareil IT Services,






In ViewState How much lifespan items stored?

0 Answers   Siebel,


What is full trust in asp.net?

0 Answers  


benefits of migration from asp to asp.net hi frnds, i have to give presentation to a client about how useful would be migrating their project from asp to asp.net .plz give me some points which i should incorporate in my ppt thanks

0 Answers  


How to send auto matic emails based on scheduled tasks to several of my clients

6 Answers  


How do you relate an aspx page with its code behind Page?

2 Answers   Accenture,


How do I create a web form?

0 Answers  


Can we change the session timeout in ASP.NET, if yes then how and from where?

7 Answers   L&T,


Categories