Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Web Services > Is this a valid SOAP fault response ..

Reply
Thread Tools

Is this a valid SOAP fault response ..

 
 
BusyBoy
Guest
Posts: n/a
 
      04-21-2009
Is the following a valid SOAP Response for a SOAP Fault ?
I am getting a response as shown

<NS1:Envelope xmlns:NS1="http://schemas.xmlsoap.org/soap/envelope/">
<NS1:Header/>
<NS1:Body>
<NS1:Fault>
<NS1:faultcode>SOAP-ENV:Server</NS1:faultcode>
<NS1:faultstring>This is an operation implementation
generated fault</NS1:faultstring>
<NS1:faultactor/>
<detail>
<NS2:CustomFault xmlns:NS2="http://www.hbos.co.uk/xmlns/
Fault">
<NS2:ExceptionName>DDiNotFoundException</
NS2:ExceptionName>
<NS2:ExceptionReason>No DDs found</NS2:ExceptionReason>
<NS2:ExceptionType>Business</NS2:ExceptionType>
<NS2:ExceptionCode>00009</NS2:ExceptionCode>
<NS2:ExceptionTrace/>
</NS2:BPMSFault>
</detail>
</NS1:Fault>
</NS1:Body>
</NS1:Envelope>

The above is the response which we are getting from SOAPUI .

Whenever a soapexception is being thrown in my consumer code I am
expecting the excpeiton to be caught as an SoapException object and
not as an exception object.

see the code below :

catch (SoapException soap)
{
int i;
i = 0;
}
catch (Exception e)
{
int i;
i = 0;
}

Here the above fault comes to the second block i.e. ( Exception e).

The exception shown is

"Start element 'faultcode' from namespace '' expected. Found element
'NS1:faultcode' from namespace 'http://schemas.xmlsoap.org/soap/
envelope/'. Line 2, position 118."

Is this a problem because the SoapFault has ns1 prefixed. I would have
though ASP.Net can take care of the NS1 prefixing.

Thanks

Rajan
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to make soap request and receive soap response from php soapservice Ivan S ASP .Net 0 08-13-2008 03:35 PM
SOAP Request is repeated in the SOAP response. comp.text.xml XML 0 09-20-2006 08:41 AM
Soap fault on Tomcat Viv Java 0 11-05-2005 07:26 AM
Does ServiceDescriptionobject generate valid soap fault bindings? fjodor ASP .Net Web Services 0 01-18-2005 05:15 PM
Stack fault and page fault help S.Flournoy Computer Support 2 04-17-2004 04:23 PM



Advertisments