[omniORB] Single Threaded Policy: really same thread?

Kevin Wooten kwooten@itracs.com
Tue Dec 17 18:18:02 2002


The "main thread" defaults to the thread that initialized the ORB, you
can change the "main thread" to a different thread by calling
setMainThread. Invoking setMainThread in every invocation is probably
unnecessary either just use the main thread or choose a random second
thread.

> -----Original Message-----
> From: Kevin Matassa [mailto:kevin.matassa@adobe.com]
> Sent: Tuesday, December 17, 2002 10:40 AM
> To: 'omniorb-list@omniorb-support.com'
> Subject: RE: [omniORB] Single Threaded Policy: really same thread?
> 
> 
> I'm not sure what setMainThread() does?  Am I able to call
setMainThread
> from within each instance of my server object, such that all
subsequent
> calls to that instance will continue to use the same thread?
> 
> -Kevin
> 
> 
> -----Original Message-----
> From: Duncan Grisby [mailto:duncan@grisby.org]
> Sent: December 17, 2002 12:32 PM
> To: Kevin Matassa
> Cc: 'omniorb-list@omniorb-support.com'
> Subject: Re: [omniORB] Single Threaded Policy: really same thread?
> 
> 
> On Tuesday 17 December, Kevin Matassa wrote:
> 
> > I've tried this setting to no avail on my XP box.  The only way I
see
> > the same thread is by defining the MAIN_THREAD model in my POA.
> 
> The MAIN_THREAD policy is the only way to do what you want. Note that
you
> don't have to actually use the main thread. You can use a different
thread
> by calling omniORB::setMainThread() from the thread you want to use.
You
> must, of course, give the chosen thread to the ORB by calling
orb->run(),
> or
> perform_work().
> 
> Cheers,
> 
> Duncan.
> 
> --
>  -- Duncan Grisby         --
>   -- duncan@grisby.org     --
>    -- http://www.grisby.org --
> _______________________________________________
> omniORB-list mailing list
> omniORB-list@omniorb-support.com
> http://www.omniorb-support.com/mailman/listinfo/omniorb-list