Uploaded image for project: 'CXF'
  1. CXF
  2. CXF-4784

enhance CXF to follow jaxws spec 3.6.2.3 when using RI or Axis2 client

    XMLWordPrintableJSON

Details

    • Unknown

    Description

      The content of the Outbound SOAP message in RPC/literal web service in current CXF is like below:
      <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
      <soap:Body>
      <ns1:returnNullResponse xmlns:ns1="http://serverrpc.testdata.soapbinding.annotations/">
      <soap:Fault>
      <faultcode>soap:Server</faultcode>
      <faultstring>Cannot write part return. RPC/Literal parts cannot be null. (WS-I BP R2211)</faultstring>
      </soap:Fault>
      </ns1:returnNullResponse>
      </soap:Body>
      </soap:Envelope>
      If we use RI/Axis2 client, then it will not catch the WebServiceException. The reason is that CXF wrapped the Fault in the common response element.
      With this fix, the SOAP message in this scenario will be like below, which will catch the WebServiceException using RI/Axis2 client.
      <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
      <soap:Body>
      <soap:Fault>
      <faultcode>soap:Server</faultcode>
      <faultstring>Cannot write part return. RPC/Literal parts cannot be null. (WS-I BP R2211)</faultstring>
      </soap:Fault>
      </soap:Body>
      </soap:Envelope>

      Attachments

        1. CXF-4784.patch
          2 kB
          Bin Zhu

        Activity

          People

            ffang Freeman Yue Fang
            zhubinbj Bin Zhu
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: