|The main thing is: multiple physical threads, yes, but only one logical
|thread of execution. The transaction, or "call flow", may involve several
|physical threads as beans call beans in other servers or in the same server
|or whatever, but there is only one "flow". The river never splits into two
|concurrent flows of execution.
no rickard, where is that magical scheduler that makes sure that calls are
"serialized as they come in"... and don't cheat, don't quote the spec AFTER
our scheduler, I want a part of the spec that says "calls coming in are
already serialized"
marc
|
|Hence, if we come to a point where a context is used by the same tx as we
|are in there are two things that can happen (which is the if(ctx.isLocked)
|check):
|1) The context is not locked -> the context has been used before
|in this tx,
|but it is not a reentrant call
|2) The context is locked -> the current thread of execution ("call flow")
|has already been to this instance and locked it, hence it is a reentrant
|call (which may or may not be ok)
|
|So, basically, the else branch of the isLocked() check should throw a
|RemoteException if isCallAllowed returns false.
|
|Do you see now?
|
|/Rickard
|
|
|
|