D
deostroll
There is a remote method that returns a datatable to the client. I a
talking of a scenario when there are multiple requests which invoke
the same method. I have a synchronized region of code. By that I mean
only one thread/request should execute that code; others should wait.
I've written simply with a lock. My doubt is that I am doing a return
within that region. Will this release the lock on the synchronized
region?
lock(Handle)
{
//some fetching logic here
//returning datatable
return myDataTableObj;
}
--deostroll
talking of a scenario when there are multiple requests which invoke
the same method. I have a synchronized region of code. By that I mean
only one thread/request should execute that code; others should wait.
I've written simply with a lock. My doubt is that I am doing a return
within that region. Will this release the lock on the synchronized
region?
lock(Handle)
{
//some fetching logic here
//returning datatable
return myDataTableObj;
}
--deostroll