9 Replies Latest reply on Dec 9, 2010 6:45 PM by Freeman(Yue) Fang

    CXF - Response Schema validation failed

    jc Souvignet Newbie



      I use CXF version 2.2.10-fuse-00-00 or 2.2.9 and I have the same issue :


      I have a jaxws service definied with :





      Without validation (schema-validation-enabled to false) the service is okai.


      "schema-validation-enabled" to true work fine for validating request :

      -> request with bad format raises a soap fault


      BUT the response validation failed each time with :


      org.apache.cxf.interceptor.Fault: Marshalling Error: cvc-elt.1: Cannot find the declaration of element 'checkMajReponse'.

           at org.apache.cxf.jaxb.JAXBEncoderDecoder.marshall(JAXBEncoderDecoder.java:247)

           at org.apache.cxf.jaxb.io.DataWriterImpl.write(DataWriterImpl.java:169)

           at org.apache.cxf.interceptor.AbstractOutDatabindingInterceptor.writeParts(AbstractOutDatabindingInterceptor.java:120)


      (Complete trace in attached file)



      Is it possible to active validation only from IN request ?

      What is wrong whit my config ?


      (Structure of response is valid because it is validated by my client (soapui))


      Thanks in advance for yours answers.