[omniORB] Multithreading and OMNI

Duncan Grisby dgrisby@uk.research.att.com
Tue, 31 Jul 2001 15:36:46 +0100


On Wednesday 25 July, Giga Giguashvili wrote:

[...]
> - What is the best way of using ORB objects in the scenario I described?
> Do I have to create two ORB objects or not?

You cannot create two ORB objects in omniORB. Every time you call
ORB_init(), you get the same ORB instance.

> - Is there some known issues regarding the shutdown?->destroy calls in
> OMNI, leading to a deadlock or something?

If you call shutdown() with wait_for_completion true or destroy() from
within an operation implementation, it will deadlock waiting for
itself to complete. It should throw BAD_INV_ORDER in that situation,
but that requires Current support, which omniORB 3 does not have.
omniORB 4 will properly throw the exception. Regardless, it's a
programming bug to try to shutdown or destroy in a way that waits for
operations to complete while you are in the middle of an operation.

There are no other known issues with deadlocks.

I don't quite understand what you are trying to achieve. Can you post
a minimal example which demonstrates the problem?

Cheers,

Duncan.

-- 
 -- Duncan Grisby  \  Research Engineer  --
  -- AT&T Laboratories Cambridge          --
   -- http://www.uk.research.att.com/~dpg1 --