Architecture question: Exceptions vs status codes

C

chen

We're having an internal debate about the merits & demerits of
returning status codes in the output message vs exceptions to signify
errors in handling a Web method.

The status code camp is arguing that business rules related errors are
to be conveyed using status code while reserving the exception approach
(using SoapException) to system related errors (like say database
connection issues). This implies that GetFoo() returns a composite
message that includes StatusCode, Foo (the result) as well as other
error code/descriptions.

The cons of the status code approach is that it makes client side code
really painful:

try {
response = proxy.GetFoo();
switch ( response.StatusCode )
{
case Success:
// response.Foo is valid
case NotFound: // handle this error
case OtherError:
// look at response.ErrDetail for additional
context about the error
....
}
}
catch (SoapException ex)
{
// unpack the Detail element to figure out what happened &
handle it
// appropriately
}

The other big drawback, is that the client could completely ignore the
status code. Also, the status codes will have to be conveyed
"out-of-band" thru other means of documentation - the .wsdl alone is
perhaps not sufficient.

The exception camp is arguing for using Soap Faults in the WSDL &
throwing SoapExceptions from the web method. This allows for
consistent handling of all errors (business or system related errors)
on the client side.

The cons of the exception approach is that 1.1 WSDL simply ignores the
SOAP Fault when generating client side proxy code. [Other toolkits,
notably, Axis for e.g. turns the SOAP Faults into custom exceptions
which makes it easier for clients to handle them appropriately].
Does WSDL 2.0 and/or WCF (Indigo) handle SOAP Faults any better?

Although the exception approach seems like a hands down winner, are
there any scenarios where returning status code might make sense?? or
is exception approach the way to go always? Comments?

TIA
 
W

WebMatrix

I would also be interested what others have to say.

In my experience dealing with application related errors, it's always best
to "throw" those to the client and let client handle them, this way there's
no ambiguity to the client, it’s an exception that have to be handled;
display message to the users, log it, ignore it, whatever.
Besides any client should have try catch around web service call anyway to
check for other errors like Internet connectivity.
catch (SoapException ex)
{
// unpack the Detail element to figure out what happened &
handle it
// appropriately
}

There is not really any unpacking to do: ex..Message and ex.InnerException
should be sufficient to tell you what went wrong for most of the cases. Also,
from what I understand, when Web Service throws an exception .NET runtime
does generate SOAP Fault message as part of the response, and proxy class
built with VS .NET should pick it up and load it into Exception object for
you.

As far as custom error messages/codes, I am not a big fan of magic numbers.
It requires too much administration, documentation and creates unnecessary
confusion.
 
S

Steven Cheng[MSFT]

Hi Chen,

I also think if there is no much concerns about using custom exceptions in
your scenario, it'll be the prefered means. And for status code, it's good
and simple if we're designing a certain well-defined and reusable
framework( e.g the COM runtime system....). Otherwise, for concrete
business logic specific application, we're recommended to define some
custom exceptions(with human readable error message....) and put the
exception handling code at clientside.....

Please feel free to post here if you have any other concerns or
consideration...

Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

--------------------
| Thread-Topic: Architecture question: Exceptions vs status codes
| thread-index: AcYFpG6026XdDQlrQiavfy8oBNariw==
| X-WBNR-Posting-Host: 67.134.238.195
| From: =?Utf-8?B?V2ViTWF0cml4?= <[email protected]>
| References: <[email protected]>
| Subject: RE: Architecture question: Exceptions vs status codes
| Date: Tue, 20 Dec 2005 12:32:01 -0800
| Lines: 27
| Message-ID: <[email protected]>
| MIME-Version: 1.0
| Content-Type: text/plain;
| charset="Utf-8"
| Content-Transfer-Encoding: 8bit
| X-Newsreader: Microsoft CDO for Windows 2000
| Content-Class: urn:content-classes:message
| Importance: normal
| Priority: normal
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.0
| Newsgroups: microsoft.public.dotnet.framework.aspnet.webservices
| NNTP-Posting-Host: TK2MSFTNGXA03.phx.gbl 10.40.2.250
| Path: TK2MSFTNGXA02.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGXA03.phx.gbl
| Xref: TK2MSFTNGXA02.phx.gbl
microsoft.public.dotnet.framework.aspnet.webservices:31185
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet.webservices
|
| I would also be interested what others have to say.
|
| In my experience dealing with application related errors, it's always
best
| to "throw" those to the client and let client handle them, this way
there's
| no ambiguity to the client, it’s an exception that have to be handled;
| display message to the users, log it, ignore it, whatever.
| Besides any client should have try catch around web service call anyway
to
| check for other errors like Internet connectivity.
|
| > catch (SoapException ex)
| > {
| > // unpack the Detail element to figure out what happened &
| > handle it
| > // appropriately
| > }
|
| There is not really any unpacking to do: ex..Message and
ex.InnerException
| should be sufficient to tell you what went wrong for most of the cases.
Also,
| from what I understand, when Web Service throws an exception .NET runtime
| does generate SOAP Fault message as part of the response, and proxy class
| built with VS .NET should pick it up and load it into Exception object
for
| you.
|
| As far as custom error messages/codes, I am not a big fan of magic
numbers.
| It requires too much administration, documentation and creates
unnecessary
| confusion.
|
|
 
S

Steven Cheng[MSFT]

Hi Chen,

Any progress on this or does my last reply helps a little? If anything else
we can help, please feel free to post here.

Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)
--------------------
| X-Tomcat-ID: 101488329
| References: <[email protected]>
<[email protected]>
| MIME-Version: 1.0
| Content-Type: text/plain
| Content-Transfer-Encoding: 7bit
| From: (e-mail address removed) (Steven Cheng[MSFT])
| Organization: Microsoft
| Date: Wed, 21 Dec 2005 06:05:18 GMT
| Subject: RE: Architecture question: Exceptions vs status codes
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet.webservices
| Message-ID: <[email protected]>
| Newsgroups: microsoft.public.dotnet.framework.aspnet.webservices
| Lines: 81
| Path: TK2MSFTNGXA02.phx.gbl
| Xref: TK2MSFTNGXA02.phx.gbl
microsoft.public.dotnet.framework.aspnet.webservices:31189
| NNTP-Posting-Host: TOMCATIMPORT1 10.201.218.122
|
| Hi Chen,
|
| I also think if there is no much concerns about using custom exceptions
in
| your scenario, it'll be the prefered means. And for status code, it's
good
| and simple if we're designing a certain well-defined and reusable
| framework( e.g the COM runtime system....). Otherwise, for concrete
| business logic specific application, we're recommended to define some
| custom exceptions(with human readable error message....) and put the
| exception handling code at clientside.....
|
| Please feel free to post here if you have any other concerns or
| consideration...
|
| Regards,
|
| Steven Cheng
| Microsoft Online Support
|
| Get Secure! www.microsoft.com/security
| (This posting is provided "AS IS", with no warranties, and confers no
| rights.)
|
| --------------------
| | Thread-Topic: Architecture question: Exceptions vs status codes
| | thread-index: AcYFpG6026XdDQlrQiavfy8oBNariw==
| | X-WBNR-Posting-Host: 67.134.238.195
| | From: =?Utf-8?B?V2ViTWF0cml4?= <[email protected]>
| | References: <[email protected]>
| | Subject: RE: Architecture question: Exceptions vs status codes
| | Date: Tue, 20 Dec 2005 12:32:01 -0800
| | Lines: 27
| | Message-ID: <[email protected]>
| | MIME-Version: 1.0
| | Content-Type: text/plain;
| | charset="Utf-8"
| | Content-Transfer-Encoding: 8bit
| | X-Newsreader: Microsoft CDO for Windows 2000
| | Content-Class: urn:content-classes:message
| | Importance: normal
| | Priority: normal
| | X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.0
| | Newsgroups: microsoft.public.dotnet.framework.aspnet.webservices
| | NNTP-Posting-Host: TK2MSFTNGXA03.phx.gbl 10.40.2.250
| | Path: TK2MSFTNGXA02.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGXA03.phx.gbl
| | Xref: TK2MSFTNGXA02.phx.gbl
| microsoft.public.dotnet.framework.aspnet.webservices:31185
| | X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet.webservices
| |
| | I would also be interested what others have to say.
| |
| | In my experience dealing with application related errors, it's always
| best
| | to "throw" those to the client and let client handle them, this way
| there's
| | no ambiguity to the client, it’s an exception that have to be
handled;
| | display message to the users, log it, ignore it, whatever.
| | Besides any client should have try catch around web service call anyway
| to
| | check for other errors like Internet connectivity.
| |
| | > catch (SoapException ex)
| | > {
| | > // unpack the Detail element to figure out what happened &
| | > handle it
| | > // appropriately
| | > }
| |
| | There is not really any unpacking to do: ex..Message and
| ex.InnerException
| | should be sufficient to tell you what went wrong for most of the cases.
| Also,
| | from what I understand, when Web Service throws an exception .NET
runtime
| | does generate SOAP Fault message as part of the response, and proxy
class
| | built with VS .NET should pick it up and load it into Exception object
| for
| | you.
| |
| | As far as custom error messages/codes, I am not a big fan of magic
| numbers.
| | It requires too much administration, documentation and creates
| unnecessary
| | confusion.
| |
| |
|
|
 
C

chen

While we have decided to go with the exceptions route, the next
question that needs to be answered is how to tell the clients of the
web service how, lets say GetFoo(), will fail.

Here's a WSDL snippet
<operation name="GetFoo">
<documentation xmlns="http://schemas.xmlsoap.org/wsdl/"/>
<input name="GetFooByLabel" message="tns:getFooByLabelIn"/>
<output name="GetFooByLabel" message="tns:getFooByLabelOut"/>
<fault name="NotFound" message="tns:NotFoundException"/>
</operation>

Right now, it appears that the Soap faults are merely documenting the
fact that GetFoo() operation could result in NotFound fault code. All
the tools that i tried (WSDL, wseWSDL) ignore them & there doesn't
appear to be any easy way to turn them into custom exceptions on the
client side. So does it add any value in specifying them in the .wsdl
at all? What are some of the best practices in this area?
 
S

Steven Cheng[MSFT]

Thanks for your followup Chen,

yes, for ASP.NET Webservice, it has limited exception framework, the
serverside webservice can only propagate SoapException as the exception
object to clientside.... And our serverside custom exception detailes can
be encapsulated in the SoapException's properties.... (xmlNode....). The
msdn .NET exception management guide also mentioned this:

#Exception Management Architecture Guide
http://msdn.microsoft.com/library/en-us/dnbda/html/exceptdotnet.asp?frame=tr
ue

And here is a certain tech article discussing on encapsulating custom
exception info through SoapException and the xml data:

#Exception Handling in Web Services
http://www.developer.com/net/csharp/article.php/10918_3088231_1

Hope helps. Thanks,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)



--------------------
| From: "chen" <[email protected]>
| Newsgroups: microsoft.public.dotnet.framework.aspnet.webservices
| Subject: Re: Architecture question: Exceptions vs status codes
| Date: 28 Dec 2005 10:21:00 -0800
| Organization: http://groups.google.com
| Lines: 19
| Message-ID: <[email protected]>
| References: <[email protected]>
| <[email protected]>
| <[email protected]>
| <E077n#[email protected]>
| NNTP-Posting-Host: 141.162.101.50
| Mime-Version: 1.0
| Content-Type: text/plain; charset="iso-8859-1"
| X-Trace: posting.google.com 1135794066 4792 127.0.0.1 (28 Dec 2005
18:21:06 GMT)
| X-Complaints-To: (e-mail address removed)
| NNTP-Posting-Date: Wed, 28 Dec 2005 18:21:06 +0000 (UTC)
| User-Agent: G2/0.2
| X-HTTP-UserAgent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET
CLR 1.0.3705; .NET CLR 1.1.4322; .NET CLR 2.0.50727),gzip(gfe),gzip(gfe)
| Complaints-To: (e-mail address removed)
| Injection-Info: f14g2000cwb.googlegroups.com; posting-host=141.162.101.50;
| posting-account=X7ANQg0AAAB-ENGC8U9YFBV5V2pedTsn
| Path:
TK2MSFTNGXA02.phx.gbl!TK2MSFTNGP08.phx.gbl!newsfeed00.sul.t-online.de!t-onli
ne.de!border2.nntp.dca.giganews.com!border1.nntp.dca.giganews.com!nntp.gigan
ews.com!postnews.google.com!f14g2000cwb.googlegroups.com!not-for-mail
| Xref: TK2MSFTNGXA02.phx.gbl
microsoft.public.dotnet.framework.aspnet.webservices:31228
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet.webservices
|
| While we have decided to go with the exceptions route, the next
| question that needs to be answered is how to tell the clients of the
| web service how, lets say GetFoo(), will fail.
|
| Here's a WSDL snippet
| <operation name="GetFoo">
| <documentation xmlns="http://schemas.xmlsoap.org/wsdl/"/>
| <input name="GetFooByLabel" message="tns:getFooByLabelIn"/>
| <output name="GetFooByLabel" message="tns:getFooByLabelOut"/>
| <fault name="NotFound" message="tns:NotFoundException"/>
| </operation>
|
| Right now, it appears that the Soap faults are merely documenting the
| fact that GetFoo() operation could result in NotFound fault code. All
| the tools that i tried (WSDL, wseWSDL) ignore them & there doesn't
| appear to be any easy way to turn them into custom exceptions on the
| client side. So does it add any value in specifying them in the .wsdl
| at all? What are some of the best practices in this area?
|
|
 
S

Steven Cheng[MSFT]

Hi Chen,

Does the things in my latest reply helps? If still anything else we can
help, please feel free to post here.

Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

--------------------
| X-Tomcat-ID: 107681489
| References: <[email protected]>
<[email protected]>
| MIME-Version: 1.0
| Content-Type: text/plain
| Content-Transfer-Encoding: 7bit
| From: (e-mail address removed) (Steven Cheng[MSFT])
| Organization: Microsoft
| Date: Thu, 29 Dec 2005 07:00:03 GMT
| Subject: Re: Architecture question: Exceptions vs status codes
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet.webservices
| Message-ID: <[email protected]>
| Newsgroups: microsoft.public.dotnet.framework.aspnet.webservices
| Lines: 89
| Path: TK2MSFTNGXA02.phx.gbl
| Xref: TK2MSFTNGXA02.phx.gbl
microsoft.public.dotnet.framework.aspnet.webservices:31231
| NNTP-Posting-Host: tomcatimport2.phx.gbl 10.201.218.182
|
| Thanks for your followup Chen,
|
| yes, for ASP.NET Webservice, it has limited exception framework, the
| serverside webservice can only propagate SoapException as the exception
| object to clientside.... And our serverside custom exception detailes
can
| be encapsulated in the SoapException's properties.... (xmlNode....). The
| msdn .NET exception management guide also mentioned this:
|
| #Exception Management Architecture Guide
|
http://msdn.microsoft.com/library/en-us/dnbda/html/exceptdotnet.asp?frame=tr
| ue
|
| And here is a certain tech article discussing on encapsulating custom
| exception info through SoapException and the xml data:
|
| #Exception Handling in Web Services
| http://www.developer.com/net/csharp/article.php/10918_3088231_1
|
| Hope helps. Thanks,
|
| Steven Cheng
| Microsoft Online Support
|
| Get Secure! www.microsoft.com/security
| (This posting is provided "AS IS", with no warranties, and confers no
| rights.)
|
|
|
| --------------------
| | From: "chen" <[email protected]>
| | Newsgroups: microsoft.public.dotnet.framework.aspnet.webservices
| | Subject: Re: Architecture question: Exceptions vs status codes
| | Date: 28 Dec 2005 10:21:00 -0800
| | Organization: http://groups.google.com
| | Lines: 19
| | Message-ID: <[email protected]>
| | References: <[email protected]>
| | <[email protected]>
| | <[email protected]>
| | <E077n#[email protected]>
| | NNTP-Posting-Host: 141.162.101.50
| | Mime-Version: 1.0
| | Content-Type: text/plain; charset="iso-8859-1"
| | X-Trace: posting.google.com 1135794066 4792 127.0.0.1 (28 Dec 2005
| 18:21:06 GMT)
| | X-Complaints-To: (e-mail address removed)
| | NNTP-Posting-Date: Wed, 28 Dec 2005 18:21:06 +0000 (UTC)
| | User-Agent: G2/0.2
| | X-HTTP-UserAgent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1;
..NET
| CLR 1.0.3705; .NET CLR 1.1.4322; .NET CLR 2.0.50727),gzip(gfe),gzip(gfe)
| | Complaints-To: (e-mail address removed)
| | Injection-Info: f14g2000cwb.googlegroups.com;
posting-host=141.162.101.50;
| | posting-account=X7ANQg0AAAB-ENGC8U9YFBV5V2pedTsn
| | Path:
|
TK2MSFTNGXA02.phx.gbl!TK2MSFTNGP08.phx.gbl!newsfeed00.sul.t-online.de!t-onli
|
ne.de!border2.nntp.dca.giganews.com!border1.nntp.dca.giganews.com!nntp.gigan
| ews.com!postnews.google.com!f14g2000cwb.googlegroups.com!not-for-mail
| | Xref: TK2MSFTNGXA02.phx.gbl
| microsoft.public.dotnet.framework.aspnet.webservices:31228
| | X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet.webservices
| |
| | While we have decided to go with the exceptions route, the next
| | question that needs to be answered is how to tell the clients of the
| | web service how, lets say GetFoo(), will fail.
| |
| | Here's a WSDL snippet
| | <operation name="GetFoo">
| | <documentation xmlns="http://schemas.xmlsoap.org/wsdl/"/>
| | <input name="GetFooByLabel" message="tns:getFooByLabelIn"/>
| | <output name="GetFooByLabel" message="tns:getFooByLabelOut"/>
| | <fault name="NotFound" message="tns:NotFoundException"/>
| | </operation>
| |
| | Right now, it appears that the Soap faults are merely documenting the
| | fact that GetFoo() operation could result in NotFound fault code. All
| | the tools that i tried (WSDL, wseWSDL) ignore them & there doesn't
| | appear to be any easy way to turn them into custom exceptions on the
| | client side. So does it add any value in specifying them in the .wsdl
| | at all? What are some of the best practices in this area?
| |
| |
|
|
 
C

cat

I'm more towards using a different approach: return an enum
1. a switch statement to check the returned value, or a set of catch ( ...)
blocks is pretty much the same; you have to define the returned/thrown items
and handle them anyways
2. re "client could completely ignore the status code": you could to that
with an exception, but not trapping or using catch ( Exception ex )
3. security issues: the information from an exception could expose to a
hacker the structure of your application/webservice
4. the client side proxy code could reflect changes in the values of the
enum; if you change the exceptions thrown by the service, or add new ones,
you gotta make sure you convey that to all your clients cuz no proxy code
generator will do that for you
5. marshalling an exception across application domains is very expensive,
and will make your application less scalable (it's several orders of
magnitude slower than a return value)


Steven Cheng said:
Hi Chen,

Does the things in my latest reply helps? If still anything else we can
help, please feel free to post here.

Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

--------------------
| X-Tomcat-ID: 107681489
| References: <[email protected]>
<[email protected]>
| MIME-Version: 1.0
| Content-Type: text/plain
| Content-Transfer-Encoding: 7bit
| From: (e-mail address removed) (Steven Cheng[MSFT])
| Organization: Microsoft
| Date: Thu, 29 Dec 2005 07:00:03 GMT
| Subject: Re: Architecture question: Exceptions vs status codes
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet.webservices
| Message-ID: <[email protected]>
| Newsgroups: microsoft.public.dotnet.framework.aspnet.webservices
| Lines: 89
| Path: TK2MSFTNGXA02.phx.gbl
| Xref: TK2MSFTNGXA02.phx.gbl
microsoft.public.dotnet.framework.aspnet.webservices:31231
| NNTP-Posting-Host: tomcatimport2.phx.gbl 10.201.218.182
|
| Thanks for your followup Chen,
|
| yes, for ASP.NET Webservice, it has limited exception framework, the
| serverside webservice can only propagate SoapException as the exception
| object to clientside.... And our serverside custom exception detailes
can
| be encapsulated in the SoapException's properties.... (xmlNode....). The
| msdn .NET exception management guide also mentioned this:
|
| #Exception Management Architecture Guide
|
http://msdn.microsoft.com/library/en-us/dnbda/html/exceptdotnet.asp?frame=tr
| ue
|
| And here is a certain tech article discussing on encapsulating custom
| exception info through SoapException and the xml data:
|
| #Exception Handling in Web Services
| http://www.developer.com/net/csharp/article.php/10918_3088231_1
|
| Hope helps. Thanks,
|
| Steven Cheng
| Microsoft Online Support
|
| Get Secure! www.microsoft.com/security
| (This posting is provided "AS IS", with no warranties, and confers no
| rights.)
|
|
|
| --------------------
| | From: "chen" <[email protected]>
| | Newsgroups: microsoft.public.dotnet.framework.aspnet.webservices
| | Subject: Re: Architecture question: Exceptions vs status codes
| | Date: 28 Dec 2005 10:21:00 -0800
| | Organization: http://groups.google.com
| | Lines: 19
| | Message-ID: <[email protected]>
| | References: <[email protected]>
| | <[email protected]>
| | <[email protected]>
| | <E077n#[email protected]>
| | NNTP-Posting-Host: 141.162.101.50
| | Mime-Version: 1.0
| | Content-Type: text/plain; charset="iso-8859-1"
| | X-Trace: posting.google.com 1135794066 4792 127.0.0.1 (28 Dec 2005
| 18:21:06 GMT)
| | X-Complaints-To: (e-mail address removed)
| | NNTP-Posting-Date: Wed, 28 Dec 2005 18:21:06 +0000 (UTC)
| | User-Agent: G2/0.2
| | X-HTTP-UserAgent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1;
.NET
| CLR 1.0.3705; .NET CLR 1.1.4322; .NET CLR 2.0.50727),gzip(gfe),gzip(gfe)
| | Complaints-To: (e-mail address removed)
| | Injection-Info: f14g2000cwb.googlegroups.com;
posting-host=141.162.101.50;
| | posting-account=X7ANQg0AAAB-ENGC8U9YFBV5V2pedTsn
| | Path:
|
TK2MSFTNGXA02.phx.gbl!TK2MSFTNGP08.phx.gbl!newsfeed00.sul.t-online.de!t-onli
|
ne.de!border2.nntp.dca.giganews.com!border1.nntp.dca.giganews.com!nntp.gigan
| ews.com!postnews.google.com!f14g2000cwb.googlegroups.com!not-for-mail
| | Xref: TK2MSFTNGXA02.phx.gbl
| microsoft.public.dotnet.framework.aspnet.webservices:31228
| | X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet.webservices
| |
| | While we have decided to go with the exceptions route, the next
| | question that needs to be answered is how to tell the clients of the
| | web service how, lets say GetFoo(), will fail.
| |
| | Here's a WSDL snippet
| | <operation name="GetFoo">
| | <documentation xmlns="http://schemas.xmlsoap.org/wsdl/"/>
| | <input name="GetFooByLabel" message="tns:getFooByLabelIn"/>
| | <output name="GetFooByLabel" message="tns:getFooByLabelOut"/>
| | <fault name="NotFound" message="tns:NotFoundException"/>
| | </operation>
| |
| | Right now, it appears that the Soap faults are merely documenting the
| | fact that GetFoo() operation could result in NotFound fault code. All
| | the tools that i tried (WSDL, wseWSDL) ignore them & there doesn't
| | appear to be any easy way to turn them into custom exceptions on the
| | client side. So does it add any value in specifying them in the .wsdl
| | at all? What are some of the best practices in this area?
| |
| |
|
|
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,994
Messages
2,570,223
Members
46,813
Latest member
lawrwtwinkle111

Latest Threads

Top