[omniORB] Deadlock on recursive invocation with
SINGLE_THREAD_MODEL
Duncan Grisby
duncan at grisby.org
Thu Sep 10 11:32:12 BST 2009
On Thursday 10 September, "Felix Nawothnig" wrote:
> Looks like when doing an recursive invokation on a POA with the
> SINGLE_THREAD_MODEL policy (with the outer request obviously being
> performed in it's main-thread) omniORB deadlocks.
What exactly are you doing? The SINGLE_THREAD_MODEL does in fact use a
recursive mutex, as required by the POA specification. If you just
recursively call operations on the same POA, from the same thread, it
will work ok.
> The reasons are obvious, and it might not be an actual bug (I really don't
> care what the specs say about this, if anything) but as the ORB could -
> theoretically - recursively dispatch incoming requests while waiting for
> an outgoing one to finish I'm wondering what the developers think about
> this...
It sounds like you are actually doing a remote call from inside your
servant, and the remote side calls back? That definitely can't work.
There's no way to know that any incoming calls are from the same logical
thread of control that was holding the lock. It certainly isn't
acceptable to allow any incoming call, since that would violate the
single threading requirement.
Cheers,
Duncan.
--
-- Duncan Grisby --
-- duncan at grisby.org --
-- http://www.grisby.org --
More information about the omniORB-list
mailing list