Re: Newbie to ORBit2 threading



"Mr C.A.Beazley" wrote:
> Sorry for such a basic question, but, I would like to write a CORBA server
> (using orbit2), so that when a user logs in, a separate thread is created for
> that user's session. At the moment the apploications being run are not
> trivial which causes long delays for multiple users.
> 
> So far I've set up a simple object factory "Session_Manager" which creates an
> "Applications" object, but I need to know where to go from here.
> 
> How do I tell the server to fork off a new thread when the
> Session_Manager_login method is called?

So, you want a thread-per-connection?

If you can't get the orb to support that, the alternative
is to make your methods just queue a work item, and
call a callback in the client when the work item is done.
That can give you nearly the same effect, but without multiple
threads.

- Dan



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