>
> > I think the policy is quite simple:  you don't lock session, if you
> > are only reading session variables.  You lock only if you modify
> > session certain variables; and you lock it immediately before you
> > write, and unlock immediately before you write.
>
> If that's your locking policy, I don't see the point of locking at all.


As I understand it, currently, reading and writing will lock sessions.
And the point where the lock is acquired is when the control function
is called, and released when it finishes.

Then, we have a problem: a long running controller function will lock
session even if it is not touching session variables at all.

This means other controller functions will have to wait for it to
finish.   The current remedy is to ask the long-running process to
release lock if it doesn't need it.

This policy is okay, but not good for reasons argued above.  It is
better not acquiring a lock unless you need one than to keeping a lock
unless you don't need it.


Reply via email to