Well Im attempting the second approach. But with no success. Would I be right in thinking that AXIS is still not able to transport custom exceptions from the server to the client?
At present I am just getting an AxisFault exception on the client.
My exception dervives from Exception until I run the Java2WSDL and WSDL2Java tools and then it derives from AxisFault. So as the code is completely generated by AXIS I thought it would have worked.
Any thoughts? Stuart.
Stuart Barlow wrote:
If I have a Java interface that I am going to be turning into a web service (with AXIS and the Java2WSDL and WSDL2Java tools).
Should I define a hierarchy of exception classes that could be thrown from the server. e.g.
Exception <--- MyServiceException MyServiceException <---- InvalidOperationException InvalidOperationException <---- LogonFailure MyServiceException <---- InvalidKeyException
So I end up with a complex hierarchy of exceptions. But then AXIS will have to transport and de-derialize across the wire with all the complexities involved.
Or should I just have a single exception class (MyServiceException) containing error code information? This second approach sounds easier for AXIS.
Thanks for any advise, Stuart.
