[ 
https://issues.apache.org/jira/browse/AXIOM-448?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Nathan Clement updated AXIOM-448:
---------------------------------

    Description: 
The following 2 classes both implement SOAPFault:

org.apache.axiom.soap.impl.dom.soap11.SOAP11FaultImpl
org.apache.axiom.soap.impl.llom.soap11.SOAP11FaultImpl

However, they implement the getNode() method differently.  The LLOM 
implementation returns null, but the DOOM implementation throws 
UnsupportedOperationException.  As such, I can't switch from LLOM to DOOM under 
Axis2 due to the following exception:

Caused by: java.lang.UnsupportedOperationException: SOAP 1.1 has no Fault Node
    at 
org.apache.axiom.soap.impl.dom.soap11.SOAP11FaultImpl.getNode(SOAP11FaultImpl.java:138)
    at org.apache.axis2.AxisFault.initializeValues(AxisFault.java:202)
    at org.apache.axis2.AxisFault.<init>(AxisFault.java:196)
    at 
org.apache.axis2.util.Utils.getInboundFaultFromMessageContext(Utils.java:531)

Please change the DOOM implementation to also return null.

Also, the 
org.apache.axiom.soap.impl.dom.factory.DOMSOAPFactory.getDefaultFaultEnvelope() 
implementation is not correct for SOAP 1.1.  I got around this by adding the 
following method to org.apache.axiom.soap.impl.dom.soap11.SOAP11Factory (copied 
from org.apache.axiom.soap.impl.llom.soap11.SOAP11Factory):

{code}

    public SOAPEnvelope getDefaultFaultEnvelope() throws 
SOAPProcessingException {
        SOAPEnvelope defaultEnvelope = getDefaultEnvelope();
        SOAPFault fault = createSOAPFault(defaultEnvelope.getBody());

        SOAPFaultCode faultCode = createSOAPFaultCode(fault);

        SOAPFaultReason reason = createSOAPFaultReason(fault);
        //createSOAPFaultText(reason);

        createSOAPFaultDetail(fault);

        return defaultEnvelope;
    }
{code}

  was:
The following 2 classes both implement SOAPFault:

org.apache.axiom.soap.impl.dom.soap11.SOAP11FaultImpl
org.apache.axiom.soap.impl.llom.soap11.SOAP11FaultImpl

However, they implement the getNode() method differently.  The LLOM 
implementation returns null, but the DOOM implementation throws 
UnsupportedOperationException.  As such, I can't switch from LLOM to DOOM under 
Axis2 due to the following exception:

Caused by: java.lang.UnsupportedOperationException: SOAP 1.1 has no Fault Node
    at 
org.apache.axiom.soap.impl.dom.soap11.SOAP11FaultImpl.getNode(SOAP11FaultImpl.java:138)
    at org.apache.axis2.AxisFault.initializeValues(AxisFault.java:202)
    at org.apache.axis2.AxisFault.<init>(AxisFault.java:196)
    at 
org.apache.axis2.util.Utils.getInboundFaultFromMessageContext(Utils.java:531)

Please change the DOOM implementation to also return null.

    
> Inconsistency in LLOM and DOOM SOAP11FaultImpl implementations
> --------------------------------------------------------------
>
>                 Key: AXIOM-448
>                 URL: https://issues.apache.org/jira/browse/AXIOM-448
>             Project: Axiom
>          Issue Type: Improvement
>    Affects Versions: 1.2.13, 1.2.14
>            Reporter: Nathan Clement
>
> The following 2 classes both implement SOAPFault:
> org.apache.axiom.soap.impl.dom.soap11.SOAP11FaultImpl
> org.apache.axiom.soap.impl.llom.soap11.SOAP11FaultImpl
> However, they implement the getNode() method differently.  The LLOM 
> implementation returns null, but the DOOM implementation throws 
> UnsupportedOperationException.  As such, I can't switch from LLOM to DOOM 
> under Axis2 due to the following exception:
> Caused by: java.lang.UnsupportedOperationException: SOAP 1.1 has no Fault Node
>     at 
> org.apache.axiom.soap.impl.dom.soap11.SOAP11FaultImpl.getNode(SOAP11FaultImpl.java:138)
>     at org.apache.axis2.AxisFault.initializeValues(AxisFault.java:202)
>     at org.apache.axis2.AxisFault.<init>(AxisFault.java:196)
>     at 
> org.apache.axis2.util.Utils.getInboundFaultFromMessageContext(Utils.java:531)
> Please change the DOOM implementation to also return null.
> Also, the 
> org.apache.axiom.soap.impl.dom.factory.DOMSOAPFactory.getDefaultFaultEnvelope()
>  implementation is not correct for SOAP 1.1.  I got around this by adding the 
> following method to org.apache.axiom.soap.impl.dom.soap11.SOAP11Factory 
> (copied from org.apache.axiom.soap.impl.llom.soap11.SOAP11Factory):
> {code}
>     public SOAPEnvelope getDefaultFaultEnvelope() throws 
> SOAPProcessingException {
>         SOAPEnvelope defaultEnvelope = getDefaultEnvelope();
>         SOAPFault fault = createSOAPFault(defaultEnvelope.getBody());
>         SOAPFaultCode faultCode = createSOAPFaultCode(fault);
>         SOAPFaultReason reason = createSOAPFaultReason(fault);
>         //createSOAPFaultText(reason);
>         createSOAPFaultDetail(fault);
>         return defaultEnvelope;
>     }
> {code}

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to