axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bobby Lawrence (JIRA)" <>
Subject [jira] Updated: (AXIS-1909) Fault returned from server, but not thrown by org.apache.axis.client.Call.invokeEngine
Date Mon, 02 May 2005 15:54:05 GMT
     [ ]

Bobby Lawrence updated AXIS-1909:

    Attachment: TestCase.jar

Don't know why I need to upload a test case, I thought the problem was pretty clear...
The problem is that RemoteException (AxisFault) is only thrown in certain cases in the "invokeOneWay"
method of the Call object.
Maybe that was intentional, but in the current implementation of the SAAJ API, I have to get
the response and parse it fully to determine if we have gotten a fault returned from the service.
 This is completely different from the JAX-RPC API where any fault is thrown in the form of
a RemoteException.
I think that if the client Call object gets a fault returned, it should throw an Exception.
Maybe I shouldn't have classified it this issue as a bug, but it sure looked like one when
I found the original webservice didn't really return anything.

> Fault returned from server, but not thrown by org.apache.axis.client.Call.invokeEngine
> --------------------------------------------------------------------------------------
>          Key: AXIS-1909
>          URL:
>      Project: Axis
>         Type: Bug
>   Components: Basic Architecture
>  Environment: Windows XP Pro, Java 1.4.2, Axis 1.2 RC3
>     Reporter: Bobby Lawrence
>  Attachments: TestCase.jar
> I have a client that uploads data to the service.
> I wanted the ability to upload a single XML Document, so I wrote a method to do so using
> With the SAAJ API, you have to create a SOAPConnection and call its 'call' method.
> In the Axis implementation of this, it creates a Call object and invokes.
> The Call object internally calls the 'invokeEngine' method.
> Inside this method, there is a piece of code that checks to see if the returned object
is a SOAPFault (below).  
> If we have a fault, the method throws an AxisFault if there are some things about the
OperationDesc that it knows.
> I think that this OperationDesc checking needs to be removed and ALL faults should be
thrown back up the exception chain.
> I had my client uploading a dateTime type with 'asgasdg' as the value of the element.
 The server side deserialization threw a fault (java.lang.NumberFormatException: Invalid date/time),
but the client just did nothing.  It looked to be that the client had completed its data upload
processing and everything worked fine when in fact, it didn't upload anything and there was
an error!
> if(operation == null || 
>    operation.getReturnClass() == null || 
>    operation.getReturnClass() != javax.xml.soap.SOAPMessage.class
>   ) {
>     //unless we don't care about the return value or we want
>     //a raw message back
>     //get the fault from the body and throw it
>     throw ((SOAPFault)respBody).getFault();
> }

This message is automatically generated by JIRA.
If you think it was sent incorrectly contact one of the administrators:
For more information on JIRA, see:

View raw message