Using the J2EE reference implementation, I have a simple bean that throws an
EJBException. Instead of receiving a RemoteException, the client gets a
org.omg.CORBA.UNKNOWN exception. In particular, the client gets:
org.omg.CORBA.UNKNOWN: minor code: 0 completed: Maybe
at com.sun.corba.se.internal.core.UEInfoServiceContext.<init>(UEInfoServiceContext.java:32)
at java.lang.reflect.Constructor.newInstance(Native Method)
at com.sun.corba.se.internal.core.ServiceContextData.makeServiceContext(ServiceContextData.java:108)
at com.sun.corba.se.internal.core.ServiceContexts.unmarshal(ServiceContexts.java:163)
at com.sun.corba.se.internal.core.ServiceContexts.get(ServiceContexts.java:342)
at com.sun.corba.se.internal.core.ServiceContexts.get(ServiceContexts.java:328)
at com.sun.corba.se.internal.corba.ClientDelegate.invoke(ClientDelegate.java:203)
at org.omg.CORBA.portable.ObjectImpl._invoke(ObjectImpl.java:454)
at server._EJBExceptionThrower_Stub.throwEJBException(_EJBExceptionThrower_Stub.java:384)
at client.EJBExceptionClient.main(EJBExceptionClient.java:29)
I decompiled the client-side stub, which contains the following code:
try {
...
}
catch(SystemException ex)
{
throw Util.mapSystemException(ex);
}
The incoming exception is org.omg.CORBA.portable.UnknownException. The
method javax.rmi.CORBA.Util.mapSystemException handles it by throwing
org.omg.CORBA.UNKNOWN.
Under WebLogic 7.0 the code works as I'd expect: the client receives a
RemoteException.
Is there something basic I'm missing here?
-- Flocon
P.S.
My environment is:
OS: Windows 2000
J2EE: 1.3.1
J2SE: 1.3.1_09