[omniORB] ConnectionFailure exception in IDL causes problems...

scott.rediger at teradyne.com scott.rediger at teradyne.com
Thu Sep 25 13:16:39 BST 2003


Hi,

I haven't done in-depth investigation into this problem, because a simple
IDL exception name-change fixed my issue. However, I am curious if anyone
could point out why this might be happening. Basically, my IDL has an
exception named "ConnectionFailure" defined within a module and interface.
See example idl below:

module A
{
      interface B
      {
            exception ConnectionFailure
            {
                  [...]
            };

            void func(in long dummy)
                  raises(ConnectionFailure);
      };
};

In my servant code I am throwing this ConnectionFailure in certain cases:

void ServantClass::func(long dummy)
{
      try
      {
            [...]
      }
      catch( const myException& e )
      {
            A::B::ConnectionFailure cf;
            // fill in internal cf parameters here
            throw cf;
      }
};

Herein lies the problem: when my servant throws the IDL ConnectionFailure
exception, fully-scoped (A::B::ConnectionFailure), the client's catch block
for A::B::ConnectionFailure is not "catching" but rather the catch-all case
CORBA::Exception is "catching".

If I change the IDL exception "ConnectionFailure" to "ConnectionProblem"
and the servant and client code change to catch this exception, it works
every time!

It appears as if there is a namespace issue with ConnectionFailure within
omniORB-4.0.1 or within the OS. However, I have done a grep for
ConnectionFailure inside all header and cc files under omniORB-4.0.1 and
found nothing, so I am perplexed.

Any ideas??

System Info:
------------------
omniORB-4.0.1
Solaris2.8
CC: Sun Workshop 6 update 2 C++ 5.3 Patch 111685-13 2003/02/04

Scott Rediger





More information about the omniORB-list mailing list