Hello Dan, i don't see snapshot from last days here http://people.apache.org/repo/m2-snapshot-repository/org/apache/cxf/apache-cxf/2.1.1-SNAPSHOT/
best regards jano Daniel Kulp <[EMAIL PROTECTED]> 05/14/2008 23:33 Bitte antworten an [email protected] An [email protected] Kopie Thema Re: jaxws client proxy validation error after recreation [Virus checked] In 2.0.6/2.1, we introduced a cache for the JAXB stuff to make it faster. Unfortunately, there are a couple bugs in it that folks have found. I think you hit one of them. Can you try the latest snapshots and see if that helps? (I deployed a 2.0.7 snap this morning. A 2.1 snap is deploying now.) Alternatively, call: JAXBDataBinding.clearCaches(); before calling the factory again to clear it out and force recreation. Dan On May 14, 2008, at 4:06 PM, [EMAIL PROTECTED] wrote: > Hello, > > I have a strange error and don't know what could be a reason. Maybe > someone has an idea. > > i'm using spring 2.5.x, jboss 4.0.4, application is bundled as EAR and > using CxfServlet and default cxf configuration. > <value>classpath:META-INF/cxf/cxf.xml</value> > <value>classpath:META-INF/cxf/cxf-extension-soap.xml</value> > <value>classpath:META-INF/cxf/cxf-servlet.xml</value> > > When service is invoked, its implementation is calling another > webservice > using client fetched using following code: > JaxWsProxyFactoryBean factory = new > JaxWsProxyFactoryBean(); > factory.setServiceClass(serviceInterface); > factory.setAddress(address); > factory.setWsdlLocation(wsdlLocation); > > factory.setServiceName(QName.valueOf(serviceName > )); > factory.setProperties(new HashMap<String, > Object>()); > factory.getProperties().put( > "schema-validation-enabled", new Boolean(schemaValidationEnabled)); > T port = (T) factory.create(); > > It's working perfectly until i call this code again (even if with > the same > parameter values). After second and later initilialization i always > ends > with error: > at > org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java: > 218)
 > Caused by: org.apache.cxf.interceptor.Fault: Marshalling Error: cvc- > elt.1: > Cannot find the declaration of element > 'ns2:rbpMapService2Template'.
 > at > org > .apache.cxf.jaxb.JAXBEncoderDecoder.marshall(JAXBEncoderDecoder.java: > 208)
 > at > org.apache.cxf.jaxb.io.DataWriterImpl.write(DataWriterImpl.java: > 79)
 > at > org > .apache > .cxf > .interceptor > .AbstractOutDatabindingInterceptor > .writeParts(AbstractOutDatabindingInterceptor.java:86)
 > at > org > .apache > .cxf > .interceptor > .BareOutInterceptor.handleMessage(BareOutInterceptor.java:68)
 > at > org > .apache > .cxf > .phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java: > 221)
 > at > org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:276)
 > at > org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:222)
 > at > org.apache.cxf.frontend.ClientProxy.invokeSync(ClientProxy.java: > 73)
 > at > org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java: > 177)
 > ... 115 more
 > Caused by: javax.xml.bind.MarshalException > - with linked exception: > [org.xml.sax.SAXParseException: cvc-elt.1: Cannot find the > declaration of > element 'ns2:rbpMapService2Template'.]
 > at > com.sun.xml.bind.v2.runtime.MarshallerImpl.write(MarshallerImpl.java: > 331)
 > at > com > .sun.xml.bind.v2.runtime.MarshallerImpl.marshal(MarshallerImpl.java: > 257)
 > at > javax > .xml > .bind > .helpers.AbstractMarshallerImpl.marshal(AbstractMarshallerImpl.java: > 75)
 > at > org > .apache > .cxf.jaxb.JAXBEncoderDecoder.writeObject(JAXBEncoderDecoder.java: > 436)
 > at > org > .apache.cxf.jaxb.JAXBEncoderDecoder.marshall(JAXBEncoderDecoder.java: > 189)
 > ... 123 more
 > Caused by: org.xml.sax.SAXParseException: cvc-elt.1: Cannot find the > declaration of element 'ns2:rbpMapService2Template'.
 > at > org > .apache > .xerces.util.ErrorHandlerWrapper.createSAXParseException(Unknown > Source)
 > at org.apache.xerces.util.ErrorHandlerWrapper.error(Unknown > Source)
 > at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown > Source)
 > at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown > Source)
 > at > org > .apache.xerces.impl.xs.XMLSchemaValidator.handleStartElement(Unknown > Source)
 > at > org.apache.xerces.impl.xs.XMLSchemaValidator.startElement(Unknown > Source)
 > at > org > .apache > .xerces.jaxp.validation.ValidatorHandlerImpl.startElement(Unknown > Source)
 > at org.xml.sax.helpers.XMLFilterImpl.startElement(Unknown > Source)
 > at > com > .sun.xml.bind.v2.runtime.output.SAXOutput.endStartTag(SAXOutput.java: > 124)
 > at > com > .sun > .xml > .bind.v2.runtime.output.ForkXmlOutput.endStartTag(ForkXmlOutput.java: > 102)
 > at > com > .sun > .xml.bind.v2.runtime.XMLSerializer.endAttributes(XMLSerializer.java: > 302)
 > at > com > .sun > .xml.bind.v2.runtime.XMLSerializer.childAsXsiType(XMLSerializer.java: > 680)
 > at > com.sun.xml.bind.v2.runtime.ElementBeanInfoImpl > $1.serializeBody(ElementBeanInfoImpl.java:151)
 > at > com.sun.xml.bind.v2.runtime.ElementBeanInfoImpl > $1.serializeBody(ElementBeanInfoImpl.java:185)
 > at > com > .sun > .xml > .bind > .v2 > .runtime.ElementBeanInfoImpl.serializeBody(ElementBeanInfoImpl.java: > 305)
 > at > com > .sun > .xml > .bind > .v2 > .runtime.ElementBeanInfoImpl.serializeRoot(ElementBeanInfoImpl.java: > 312)
 > at > com > .sun > .xml > .bind > .v2 > .runtime.ElementBeanInfoImpl.serializeRoot(ElementBeanInfoImpl.java: > 71)
 > at > com > .sun > .xml.bind.v2.runtime.XMLSerializer.childAsRoot(XMLSerializer.java: > 490)
 > at > com.sun.xml.bind.v2.runtime.MarshallerImpl.write(MarshallerImpl.java: > 328)
 > ... 127 more
 > > any idea why? > > i tested the same process of creating client proxies for client of > "wsdl_first" sample, and there it's working without problems (but of > course, it's completly different setup) > > best regards > jano --- Daniel Kulp [EMAIL PROTECTED] http://www.dankulp.com/blog
