IBM Support

PK96733: JAX-WS DISPATCH THROWS A SOAPFAULTEXCEPTION WHEN A SOAP FAULT ENVELOPE IS RECEIVED

Subscribe

You can track all active APARs for this component.

 

APAR status

  • Closed as program error.

Error description

  • A customer using the JAX-WS Dispatch<T> API, received a
    SOAPFaultException.  The customer expected to receive a
    message contaning a soapenv:Fault element.
    
    Below is the Response SOAP Envelope that customer sent from the
    Provider  Endpoint:
    HTTP/1.1 500 Internal Server Error
    Content-Type: text/xml; charset=UTF-8
    Content-Language: en-US
    Content-Length: 420
    Connection: Close
    Date: Tue, 11 Aug 2009 09:47:27 GMT
    Server: WebSphere Application Server/7.0
    
    <?xml version="1.0" encoding="UTF-8"?>
    <soapenv:Envelope
    xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
    <soapenv:Body>
    <soapenv:Fault
    xmlns:m="http://schemas.xmlsoap.org/soap/envelope/">
    ...
    </soapenv:Fault>
    </soapenv:Body>
    </soapenv:Envelope>
    
    On the client, the customer was using the JAX-WS<OMElement>
    api and expected to receive an OMElement tree containing a
    soapenv:Fault element.  Instead a SOAPFaultException was
    thrown.  Here is the Exception that the customer sees in the
    trace.logs.
    
    org.apache.axis2.AxisFault:
    javax.xml.ws.soap.SOAPFaultException:
    

Local fix

Problem summary

  • ****************************************************************
    * USERS AFFECTED:  All users of IBM WebSphere Application      *
    *                  Server Version 7.0                          *
    ****************************************************************
    * PROBLEM DESCRIPTION: Web services application receives       *
    *                      unexpected SOAPFaultException from      *
    *                      JAX-WS provider endpoint.               *
    ****************************************************************
    * RECOMMENDATION:  Install a fixpack that contains this APAR   *
    ****************************************************************
    The JAX-WS Dispatch<T> API allows the customer to
    send a SOAP message to a web service and receive a SOAP
    message from the web service.  If the returned message
    contains a soapenv:Fault, the JAX-WS specification indicates
    that the Web Service runtime must throw a SOAPFaultException.
    The WebSphere Application Server Web Service runtime is
    working as designed.
    
    There are many customers that are surprised by this
    behavior.  The intended purpose of the Dispatch<T> API is to
    facilitate the sending and receiving of messages.  The
    SOAPFaultException hinders the usage of the Dispatch<T> API.
    

Problem conclusion

  • The JAX-WS Specification cannot be changed.  Instead a new
    property is introduced, to allow customers to avoid the
    SOAPFaultException.
    
    The new property is:"jaxws.response.throwExceptionIfSOAPFault".
    The value of the property is a Boolean.
    The default value is Boolean.TRUE.
    If this property is set to Boolean.FALSE, JAX-WS runtime will
    not throw a SOAPFaultException.
    The property is set on the Dispatch's RequestContext.
    
    Here is an example:
    
    Dispatch<OMElement> dispatch = service.createDispatch(
    portName, OMElement.class, Mode.MESSAGE);
    BindingProvider bp = (BindingProvider)dispatch;
    bp.getRequestContext().put(
    "jaxws.response.throwExceptionIfSOAPFault", Boolean.FALSE);
    
    The fix for this APAR is currently targeted for inclusion in
    fix pack 7.0.0.7.  Please refer to the Recommended Updates
    page for delivery information:
    http://www.ibm.com/support/docview.wss?rs=180&uid=swg27004980
    

Temporary fix

Comments

APAR Information

  • APAR number

    PK96733

  • Reported component name

    WEBSPHERE APP S

  • Reported component ID

    5724J0800

  • Reported release

    700

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt

  • Submitted date

    2009-09-21

  • Closed date

    2009-09-28

  • Last modified date

    2009-09-30

  • APAR is sysrouted FROM one or more of the following:

  • APAR is sysrouted TO one or more of the following:

Fix information

  • Fixed component name

    WEBSPHERE APP S

  • Fixed component ID

    5724J0800

Applicable component levels

  • R700 PSY

       UP

[{"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Product":{"code":"SSEQTP","label":"WebSphere Application Server"},"Component":"","ARM Category":[],"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"7.0","Edition":"","Line of Business":{"code":"LOB45","label":"Automation"}}]

Document Information

Modified date:
10 February 2022