axis-c-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Susantha Kumara" <susan...@opensource.lk>
Subject RE: Suggestion on receiving soap fault
Date Thu, 06 May 2004 09:30:04 GMT
Lets look at the user's perspective in this regard. How does a user need
a stub to look like ?.

Theoretically an application which uses a stub should feel as if it's a
local method. Isn't it so ?.

---
Susantha

-----Original Message-----
From: damitha@opensource.lk [mailto:damitha@opensource.lk] 
Sent: Thursday, May 06, 2004 11:35 AM
To: axis-c-dev@ws.apache.org; axis-c-user@ws.apache.org
Subject: Suggestion on receiving soap fault

Hi,

Curretnly Axis C++ does not handle a soap body that contains a soap
fault.
When we receive a soap fault, I have suggestions how to handle it.
Suppose that we request to add two numbers in the calculator sample.
in the current code
iResult = ws.add(i1, i2); But then we cannot get the status of the
response, success or fail. Instead if we have
iStatus = ws.add(i1, i2, iResult) where i1, i2 are the numbers to add,
iResult is to accept the result of the addition and iStatus is the
status
of the response, success or failure.

So if server returns soap fault we should have iStatus = fail.

In addition SoapDeseriazer concatenate Faultcode, Faultstring,
Faultactor
and FaultDetail into a string. So when we receive iStatus = fail we can
request
the fault string that the SoapDeserializer stored as follows

iStatus = ws.add(i1, i2, iResult);
if(AXIS_SUCCESS == iStatus)
    printf("Result : %d\n\n", iResult);
else
{
    printf("Failed\n");
    ws.getFaultDetail(&pcDetail);
    printf("pcDetail:%s\n", pcDetail);
}

Any suggestions?

regds
damitha







Mime
View raw message