Hi,

I am using CXF webservice as camel from uri and to uri is to a bean which
does a jdbc operation and return the result of the jdbc operation. generated
java code using wsdl2Java of cxf.  The whole thing works fine when the
schema validation of cxf is set to false. When i enable the schema
validation the request comes to the bean but when it tried to send the
response i get "Marshalling Error: The uri may not be theempty string". I am
using apache-cxf-2.1.2 and camel apache-camel-1.4.0

The exception i get is 

org.apache.cxf.interceptor.Fault: Marshalling Error: The uri may not be
theempty string.
        at
org.apache.cxf.jaxb.JAXBEncoderDecoder.marshall(JAXBEncoderDecoder.java:176)
        at org.apache.cxf.jaxb.io.DataWriterImpl.write(DataWriterImpl.java:131)
        at
org.apache.cxf.interceptor.AbstractOutDatabindingInterceptor.writeParts(AbstractOutDatabindingInterceptor.java:113)
        at
org.apache.cxf.interceptor.BareOutInterceptor.handleMessage(BareOutInterceptor.java:68)
        at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:220)
        at
org.apache.cxf.interceptor.OutgoingChainInterceptor.handleMessage(OutgoingChainInterceptor.java:74)
        at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:220)
        at
org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationObserver.java:78)
        at
org.apache.cxf.transport.servlet.ServletDestination.invoke(ServletDestination.java:92)
        at
org.apache.cxf.transport.servlet.ServletController.invokeDestination(ServletController.java:283)
        at
org.apache.cxf.transport.servlet.ServletController.invoke(ServletController.java:166)
        at
org.apache.cxf.transport.servlet.AbstractCXFServlet.invoke(AbstractCXFServlet.java:174)
        at
org.apache.cxf.transport.servlet.AbstractCXFServlet.doPost(AbstractCXFServlet.java:152)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:763)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
        at
weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
        at
weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
        at
weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:283)
        at
weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:175)
        at
weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3231)
        at
weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
        at
weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121)
        at
weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2002)
        at
weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:1908)
        at
weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1362)
        at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
        at weblogic.work.ExecuteThread.run(ExecuteThread.java:181)
Caused by: java.lang.IllegalArgumentException: The uri may not be theempty
string.
        at
weblogic.xml.stax.util.NamespaceContextImpl.getPrefix(NamespaceContextImpl.java:76)
        at
org.apache.cxf.staxutils.CachingXmlEventWriter$NSContext.getPrefix(CachingXmlEventWriter.java:266)
        at
com.sun.xml.bind.v2.runtime.StAXPostInitAction.run(StAXPostInitAction.java:95)
        at
com.sun.xml.bind.v2.runtime.MarshallerImpl.prewrite(MarshallerImpl.java:365)
        at
com.sun.xml.bind.v2.runtime.MarshallerImpl.write(MarshallerImpl.java:327)
        at
com.sun.xml.bind.v2.runtime.MarshallerImpl.marshal(MarshallerImpl.java:175)
        at
org.apache.cxf.jaxb.JAXBEncoderDecoder.writeObject(JAXBEncoderDecoder.java:377)
        at
org.apache.cxf.jaxb.JAXBEncoderDecoder.marshall(JAXBEncoderDecoder.java:155)
        ... 26 more
-- 
View this message in context: 
http://www.nabble.com/CXF-endpoint-with-schema-validation-true-tp20578529s22882p20578529.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Reply via email to