Hi,
I'm curious whether ORB_init is supposed to fail gracefully (failure
meaning throwing an exception in this case) ?
I have a scenario where i'm calling ORB_init with user specified options
in a batch execution system, so i should be able to report problems and
allow user to restart the process. If the user supplies -ORBIIOPAddr
inet:1.2.3.4:1234 (the ip address is not a valid interface on the
machine) ORB throws an exception when initializing IIOPServer in orb.cc
at line 3856 (mico 2.3.12) which looks like this
// ###ras Bug???
if (!iiop_server_instance->listen (addr, fwproxyaddr))
mico_throw (CORBA::INITIALIZE()); // line 3856
The failure is because the listen call tries to bind which fails (We
also specify -ORBNoResolve , so the address isn't even verified i think?)
The user does not get a pointer to the orb when it throws, so you can't
destroy it in user code. If you call ORB_init again after this with a
valid address it initializes, but the iiop server doesn't bind to the
address specified. This specific scenario could be fixed simply by
destroying the orb instance being created before throwing, but i'm more
interested in the general case:
From looking at ORB_init() I would guess it's not designed to fail
gracefully with exceptions, is this the case ? It would be nice to see
it handle failures gracefully
Best regards,
--
Arne Pajunen
Software Engineer
OpenTTCN Oy, Test and Test Control Components for Test System Vendors
Web: http://www.openttcn.com
_______________________________________________
Mico-devel mailing list
[email protected]
http://www.mico.org/mailman/listinfo/mico-devel