SchemaValidation anootation JBoss 6.1.0 (cxf 2.3.1-patch-01)
poyge394 Feb 9, 2012 11:49 AMWe have problem migrating our webservice to JBoss 6.1.0, the service deploys fine but when calling the service we get validation error (stack trace on the end of thread). We dont need validation and i whant to turn it off. I have try to that with anotation org.apache.cxf.annotations.SchemaValidation, hear is the code:
@WebService(name = "handleCorrespondencePortType", targetNamespace = "http://soa.jboss.org/handleCorrespondenceCategory", wsdlLocation = "WEB-INF/wsdl/handleCorrespondenceNew.wsdl", portName = "handleCorrespondencePortType", serviceName = "handleCorrespondenceService")
@SOAPBinding(parameterStyle = SOAPBinding.ParameterStyle.BARE)
@BindingType(value = "http://schemas.xmlsoap.org/wsdl/soap/http?mtom=true")
@org.apache.cxf.annotations.SchemaValidation(enabled = false)
public class HandleCorrespondenceImpl {
This does not work.
I also have try with org.jboss.ws.annotation.SchemaValidation.
Can I get this to work with anootation ?
17:28:23,893 INFO [STDOUT] DefaultValidationEventHandler: [ERROR]: unexpected element (uri:"http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0", local:"supplierInvoiceMetadata"). Expected elements are <{http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}claimMetadata>,<{http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}businessObjectType>,<{http://xxxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}recipient>,<{http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}documents>,<{http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}claimPSVMetadata>,<{http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}caseType>,<{http:/xxxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}policyLifeMetadata>,<{http://xxxse/interfaces/correspondence/handleCorrespondenceRequest/1.0}claimInvoiceMetadata>,<{http://xxxse/interfaces/correspondence/handleCorrespondenceRequest/1.0}correspondenceId>,<{http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}comment>,<{http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}businessObjectId>,<{http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}correspondenceDate>,<{http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}sender>
17:28:23,893 INFO [STDOUT] Location: line 18
17:28:23,894 WARN [org.apache.cxf.phase.PhaseInterceptorChain] Interceptor for {http://soa.jboss.org/handleCorrespondenceCategory}handleCorrespondenceService#{http://soa.jboss.org/handleCorrespondenceCategory}handleCorrespondenceOp has thrown exception, unwinding now: org.apache.cxf.interceptor.Fault: Unmarshalling Error: unexpected element (uri:"http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0", local:"supplierInvoiceMetadata"). Expected elements are <{http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}claimMetadata>,<{http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}businessObjectType>,<{http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}recipient>,<{http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}documents>,<{http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}claimPSVMetadata>,<{http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}caseType>,<{http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}policyLifeMetadata>,<{http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}claimInvoiceMetadata>,<{http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}correspondenceId>,<{http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}comment>,<{http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}businessObjectId>,<{http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}correspondenceDate>,<{http://xxx.se/interfaces/correspondence/handleCorrespondenceRequest/1.0}sender>
at org.apache.cxf.jaxb.JAXBEncoderDecoder.unmarshall(JAXBEncoderDecoder.java:787) [:2.3.1-patch-01]
at org.apache.cxf.jaxb.JAXBEncoderDecoder.unmarshall(JAXBEncoderDecoder.java:628) [:2.3.1-patch-01]
at org.apache.cxf.jaxb.io.DataReaderImpl.read(DataReaderImpl.java:133) [:2.3.1-patch-01]
at org.apache.cxf.interceptor.DocLiteralInInterceptor.handleMessage(DocLiteralInInterceptor.java:198) [:2.3.1-patch-01]
at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:255) [:2.3.1-patch-01]