I don't know if this still interesting for you but it might help someone else.
Anyway, I faced the same problem. I'm using JAXB 2 mappings for the parameter passed to the REST service method. I tried to use @XmlRootElement first and getting the same exception by after I've changed it to the @XmlType it started woring properly. It is because the cplxType = (XmlSchemaComplexType)findSchemaType(schemas, element.getSchemaTypeName()); in *IriDecoderHelper* returns null for element which cause later a NPE. Good luck! - Ivan gdprao wrote: > > Can anyone please help me out on this as I am facing this problem after > migrating to 2.0.2 version. > > Thanks, > Durga > > > gdprao wrote: >> >> Hi, >> >> I am experiencing the following exception after migrating to CXF-2.0.2 >> with my REST service which was working fine with CXF-2.0.1 version. If I >> set the "wrapped" attribute to "false", it is working fine but if I make >> it to "true" it is throwing the following exception. Any help to fix >> this problem is appreciated. >> >> Thanks, >> Durga >> >> Rest service configration: >> >> <!-- Rest End Point configuration --> >> <jaxws:endpoint id="myServiceRestEndPoint" >> implementor="#myWebService" address="/rest" >> bindingUri="http://apache.org/cxf/binding/http"> >> <jaxws:serviceFactory> >> <ref bean="restJaxWsServiceFactory"></ref> >> </jaxws:serviceFactory> >> </jaxws:endpoint> >> >> <!-- Rest JaxWsServiceFactory --> >> <bean id="restJaxWsServiceFactory" >> class="org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean"> >> <property name="wrapped" value="true" /> >> </bean> >> >> >> Exception stack details: >> >> Oct 3, 2007 3:36:53 PM org.apache.cxf.interceptor.AttachmentInInterceptor >> handleMessage >> INFO: AttachmentInInterceptor skipped in HTTP GET method >> Oct 3, 2007 3:36:53 PM >> org.apache.cxf.binding.http.interceptor.DispatchInterceptor handleMessage >> INFO: Invoking GET on /myMappedURI >> Oct 3, 2007 3:36:53 PM >> org.apache.cxf.binding.http.interceptor.URIParameterInInterceptor >> handleMessage >> INFO: URIParameterInterceptor handle message on path [/myMappedURI] with >> content-type [null] >> Oct 3, 2007 3:36:53 PM org.apache.cxf.phase.PhaseInterceptorChain >> doIntercept >> INFO: Interceptor has thrown exception, unwinding now >> java.lang.NullPointerException >> at >> org.apache.cxf.binding.http.IriDecoderHelper.buildDocument(IriDecoderHelper.java:236) >> at >> org.apache.cxf.binding.http.interceptor.URIParameterInInterceptor.mergeParams(URIParameterInInterceptor.java:127) >> at >> org.apache.cxf.binding.http.interceptor.URIParameterInInterceptor.handleMessage(URIParameterInInterceptor.java:103) >> at >> org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:207) >> at >> org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationObserver.java:73) >> at >> org.apache.cxf.transport.servlet.ServletDestination.doMessage(ServletDestination.java:79) >> at >> org.apache.cxf.transport.servlet.ServletController.invokeDestination(ServletController.java:235) >> at >> org.apache.cxf.transport.servlet.ServletController.invoke(ServletController.java:106) >> at >> org.apache.cxf.transport.servlet.CXFServlet.invoke(CXFServlet.java:278) >> at >> org.apache.cxf.transport.servlet.CXFServlet.doGet(CXFServlet.java:260) >> at javax.servlet.http.HttpServlet.service(HttpServlet.java:689) >> at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) >> at >> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252) >> at >> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) >> > > -- View this message in context: http://www.nabble.com/CXF-2.0.2-Rest-service-exception-tf4564911.html#a13384567 Sent from the cxf-user mailing list archive at Nabble.com.
