[omniORB] CORBA::UserException / omni compatibility

David Riddoch djr@orl.co.uk
Thu, 24 Dec 1998 12:09:53 +0000 (GMT)


Oleg,

> Seems, we found that omniORB2 exception mechanism is incompatible
> with CORBA-arch 2.2 (feb 1998). 
> 
> On the page 20-58 of the standard is written that class Exception
> must have virtual method _raise(), which is absent in case of
> OmniORB.

Yes this feature is missing in omniORB 2.6 and previous versions. It is
present in the next release though.


> We discovered it when we tried to solve the following problem:
> 
> There exists an exception 
> exception GTexception{
> short type;
> } 
> and there is a lot of attribute variables on our interfaces.
> Attributes are mapped by omniidl2 into 2 methods of classes (let us
> call them set_ and get_ methods). In some cases due to security
> reasons set_ method must be able to throw GTexception with
> type=ACCESS_VIOLATION, but of course _sk_ classes would not catch
> this exception and server will receive something like SIGINT or
> SIGUSR1. the possible solution is manually rewrite all the IDL code
> and convert all the attributes on interfaces into two methods (both
> of them will be able to raise GTexception), but we do not like this
> approach very much.
> 
> maybe someone will advise something, which is better..........

I don't think I can help here - the spec says (CORBA 2.2 p3-34)

  "Attribute operations return errors by means of standard exceptions."


David