Hi Christian! Sorry for the late response, was on a Conference last week.
This might well be an error in the interceptor logic of OWB. We wrap the original Exception into a InvocationTargetException and probably don't do the proper unwrapping afterwards. Can you please file a JIRA issue for tracking this? txs and LieGrue, strub ----- Original Message ----- > From: Mark Struberg <[email protected]> > To: MyFaces Discussion <[email protected]> > Cc: "[email protected]" <[email protected]> > Sent: Monday, November 7, 2011 8:33 PM > Subject: Re: OWB Decorator problem > > hi Christian! > > guess this was meant for [email protected]? :) > > LieGrue, > strub > > > > ----- Original Message ----- >> From: Christian Beikov <[email protected]> >> To: [email protected] >> Cc: >> Sent: Monday, November 7, 2011 7:16 PM >> Subject: OWB Decorator problem >> >> Hello there! >> >> I have a problem with OWB that does not occur on WELD and I wasn't able > to >> find a solution for that yet. >> I am using OWB 1.0 shipped with IBM WAS 8.0.0.1 and the scenario is like > this: >> >> class A implements Service{} >> class ADecorator implements Service{} >> class InterceptorImpl{} >> >> Now I call a method of the Service interface and the call is delegated to > the >> decorator as expected. The decorator passes the call to the underlying >> implementation and the impl throws an exception. Now the decorator does not > see >> the concrete exception that occurred in the impl but an >> InvocationTargetException and within that, the actual exception. >> >> Am I wrong or should I see the actual exception and not the >> InvocationTargetException? I can't even add an Interceptor to the > decorator >> methods to generically unwrap that exception, because AroundInvoke > interceptors >> are not called if they are applied on decorators. Is that the expected > behavior >> too? >> >> Thanks in advance! >> >> Regards, >> Christian >> >
