File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Web Services and the fly likes Exceptions in Web Service consumption Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Web Services
Bookmark "Exceptions in Web Service consumption" Watch "Exceptions in Web Service consumption" New topic
Author

Exceptions in Web Service consumption

Monu Tripathi
Rancher

Joined: Oct 12, 2008
Posts: 1369
    
    1

Hi,
I am new to web service and have a doubt.

I am invoking a web service by call the exposed method on the stub. Something like,

The service implementation of this method(the WebSservice) throws exceptions(which are, say, uncaught at the impl-end).

My Question is: When i print the stack trace(above), is it possible that i could get a stack dump or atleast an exception message in client code(InBoundFaults)?


[List of FAQs] | [Android FAQ] | [Samuh Varta]
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 42594
    
  65
All server-side exceptions should result in a SOAPFault being delivered to the client, which at the least includes an error message. I don't think a server-side exception can be delivered to the client, unless you programmed that into the service. (Also remember that web services are platform- and language-neutral, and the concept of exceptions and stack traces may not apply to the server-side implementation.)


Ping & DNS - my free Android networking tools app
Monu Tripathi
Rancher

Joined: Oct 12, 2008
Posts: 1369
    
    1

firstly, many thanks for your reply..


I don't think a server-side exception can be delivered to the client, unless you programmed that into the service.


The Web service that i am calling is implemented in Java,and it does send custom exceptions as SOAPFaults(as specified in WSDL).But the exception that i got was not the one specified in WSDL but(more general) something like:


The point to note is "com.arin.pojo.Logging.java" is not the file that is in the client application.But, is on the server side.

I am finding it hard to believe that this could be a client side error.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 42594
    
  65
No, it does not sound like a client-side exception. It sounds more like a server configuration problem than anything that's to do with the service itself. You should investigate what this message means, and under which circumstances it can occur.
Monu Tripathi
Rancher

Joined: Oct 12, 2008
Posts: 1369
    
    1

Will do thanks again Ulf
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Exceptions in Web Service consumption