File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Web Services and the fly likes Application Exeptions mapped to SOAP faults Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Web Services
Bookmark "Application Exeptions mapped to SOAP faults" Watch "Application Exeptions mapped to SOAP faults" New topic

Application Exeptions mapped to SOAP faults

Luke Murphy
Ranch Hand

Joined: May 12, 2010
Posts: 300
Ok so we know that Application Exceptions can be mapped to SOAP faults.
However, I am wondering what happens if they are not mapped?

Luke Murphy
Ranch Hand

Joined: May 12, 2010
Posts: 300
answer from IBM...

What about unmodeled faults?

What happens when an unmodeled fault occurs? For example, what happens when the service above throws an exception other than sample2.fault.Fault (for instance, NullPointerException)? What happens on the client? The answer to that depends on the messaging protocol. For instance, when communicating via SOAP/HTTP, the server-side SOAP engine creates a SOAP message containing a SOAP fault (see Listing 9) with information relevant to the problem in the faultcode and faultstring fields. Because a SOAP fault is returned to the client, JAX-WS has defined an exception named SOAPFaultException. When the service throws an unmodeled fault, the client receives a SOAPFaultException. is a protocol-specific exception. It extends JAX-WS defines another extension of ProtocolException: for the XML/HTTP communication channel. Those are the only standardized bindings defined for WSDL. For other bindings, assume the binding provider defines other extensions of ProtocolException, one for each new binding.
I agree. Here's the link:
subject: Application Exeptions mapped to SOAP faults
Similar Threads
handling SOAP fault in JAVA
SOAP, Exceptions, and Faults... Oh my!
how to handle exception propagation in webservice client?
Can we raise SOAP Fault for Application errors?
Proper Exception handling in WebServices