Hi Martijn, Not sure I can help you here without further information. What you say seems to be true. In any case, I don't think there's any link with Cactus as Cactus should be completely transparent to this.
WRT the RemoteException vs EJBException vs Exception, it all depends on the version of the EJB spec you're using. I'd recommend reading it again carefully (I know I read it again everytime as I can never remember what exceptions I should throw and whether it roll backs any transactions automatically or not... :-)). Thanks -Vincent > -----Original Message----- > From: Verburg, Martijn [mailto:[EMAIL PROTECTED] > Sent: 17 July 2003 01:59 > To: '[EMAIL PROTECTED]' > Subject: Exceptions thrown from code not caught by test > > Hi all, > > I think I've gotten my head mixed up over class loaders or Remote vs Local > interfaces here, but here is my problem: > > 1.) I have code in an EAR which throws a standard Business Exception. > 2.) My Test Case (deployed in a WAR) gets a local home for an Entity Bean > (in the EAR) and calls a finder on it. > 3.) The Test case (using the Entity Bean returned from the finder) calls > the code with the Business Exception, triggering that Exception on > purpose. > 4.) The Test Case then does _not_ catch the Exception returned, even if I > set it to the base type of Exception itself. > > However, it does work if I make the Exception a RemoteException, but I > _think_ I'm going over a local interface, so why the restriction to > RemoteException? > > Cheers, > Martijn > > > This communication is confidential and may contain privileged material. > If you are not the intended recipient you must not use, disclose, copy or > retain it. > If you have received it in error please immediately notify me by return > email > and delete the emails. > Thank you. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
