Re: (ORBit-mt-0.5.7)g_main_iterate(): main loop already active in another thread



Hi Dave,

> The closest I could find in the current specification for CORBA was in the
> POA section on Threading Models.  It would seem that the ORBIT-mt doesn't
> quite match up with the current specification.   I remember seeing "
> THREAD_PER_OBJECT" etc mentioned in an "old" talk....  But I can't seem to
> locate it.

Indeed the threading policies of ORBit-mt are homebrewed. But I followed
some artcile of Doug Schmidt there.

>     ORB_CTRL_MODEL - The ORB is responsible for assigning requests for an
>    ORB-controlled POA to threads. In a multi-threaded environment,
>    concurrent requests may be delivered using multiple threads.

This amounts to PortableServer_THREAD_PER_OBJECT in ORBit-mt but is
available as a literal.

>     SINGLE_THREAD_MODEL - Requests for a single-threaded POA are processed
>    sequentially. In a multi-threaded environment, all upcalls made by this
>    POA to implementation code (servants and servant managers) are made in a
>    manner that is safe for code that is multi-thread-unaware. The POA will
>    still allow reentrant calls from an object implementation to itself, or
>    to another object implementation managed by the same POA.

This is avaiable in ORBit-mt too.

>    MAIN_THREAD_MODEL - Requests for all main-thread POAs are processed
>    sequentially. In a multi-threaded environment, all upcalls made by all
>    POAs with this policy to servants are made in a manner that is safe for
>    code that is multi-thread-unaware. If the environment has special
>    requirements that some code must run on a distinguished main thread,
>    servant upcalls will be processed on that thread. (See Section 4.2.4,
>    "Thread-Related Operations," on page 4-9.)

This seems to be new (actually I had a hard time finding out, what  they
mean with it). It mostly compares to PortableServer_THREAD_PER_POA, only
that this guarantees serialization only for one POA, compared to all
POAs (what are main-thread POAs?, presumably mentioned in 4.2.4) for
MAIN_THREAD_MODEL.

I'll have to look, how to integrate that into ORBit-mt. Thanks for the
info anyway.

Bye,
Sebastian 
-- 
Sebastian Wilhelmi
mailto:wilhelmi@ira.uka.de
http://goethe.ira.uka.de/~wilhelmi





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]