users@glassfish.java.net

Prevent Mapping of Exceptions to CORBA Exceptions?

From: <glassfish_at_javadesktop.org>
Date: Wed, 27 Feb 2008 04:42:46 PST

Glassfish [com.sun.enterprise.iiop.POAProtocolMgr.mapException()] maps certain known Exceptions to CORBA equivalents, e.g from javax.ejb.TransactionRolledbackLocalException to org.omg.CORBA.TRANSACTION_ROLLEDBACK.

This may be sensible if you require interoperability or language independence, but in a controlled pure Java environment it simply has the effect that clients now have to program against CORBA Exceptions instead of the standard Java/EJB Exceptions. They no longer get the expected J2EE responses. Why is the transport impacting the programming API?

Is it possible to switch this mapping off? Exceptions that it doesn't know how to map come through fine (tunnelled via org.omg.CORBA.UNKNOWN and automatically unwrapped in the stubs). I'd rather it didn't know about any of them.
[Message sent by forum member 'jim_b_o' (jim_b_o)]

http://forums.java.net/jive/thread.jspa?messageID=261156