Greetings,
I am attempting to setup a custom exception handler through CXF-DOSGi using
Declarative Services to register my provider.
My endpoints registration file (for REST) declares the following:
<property name="org.apache.cxf.rs.provider"
value="com.MyExceptionClassPath.TestExceptionMapper" />
The class TestExceptionMapper is defined with the following signature and
default method:
package com.MyExceptionClassPath;
public class TestExceptionMapper implements
ExceptionMapper<MyCustomException> {
public Response toResponse(MyCustomException arg0) {
return Response.status(Response.Status.FORBIDDEN).build();
}
}
I am using SoapUI to call into my web service and I am trying a test of the
custom exception provider by simply calling:
throw new MyCustomException();
I have a breakpoint set at TestExceptionMapper.toResponse(), but it is never
hit. Instead, the execution stack just falls through MyCustomException.
I must add a common caveat. This is all extremely new to me, so any
responsdor needs to understand that I do not have a deep background (working
on it) in this technological field.
Thanks for any forthcoming assistance.
Cheers, Ian
--
View this message in context:
http://cxf.547215.n5.nabble.com/Help-with-Declarative-Services-and-ExceptionMapper-tp3311555p3311555.html
Sent from the cxf-issues mailing list archive at Nabble.com.