AFAIK in your current situation you do not need to worry about specific
exceptions. Just throw all the business exceptions that you need and do
not care for whether the client is using RMI or SOAP. AFAIK @WebServices
is wrapping any business exception sufficiently, so when using JAX-WS on
the client side, you will catch exactly the same Java Exception again --
while beeing *transported* by SOAP. You do not need to throw SOAP or RMI
specific exceptions. Just throw a FooException.
I can remember I tried out months ago and it worked well, but I am no
SOAP guru. Just give it a try and let us know whether it works. :-)
Regards
Markus
From: Mohammad Shamsi [mailto:m.h.shams_at_gmail.com]
Sent: Montag, 26. Mai 2008 08:50
To: users_at_glassfish.dev.java.net
Subject: Re: exception handling in EJB3 Stateless and JAX -WS. guide
tutorial example...
Hi Markus,
In Java EE 5 we can one code for both Session Bean and Web Service.
@WebService
@Stateless
public class FooImpl implements Foo {
public void dofoo() {
}
}
clients can call dofoo method, either via RMI (as a Session Bean) or
SOAP/HTTP (as a web method)
for web service clients i can throw just a SOAPFaultException and for
RMI clients i can throw any exception.
i have to know that how to handle and throw exception from this method
that both clients can use it.
On Mon, May 26, 2008 at 9:57 AM, Markus Karg <karg_at_quipsy.de> wrote:
What exactly do you want to know?
Regards
Markus
From: Mohammad Shamsi [mailto:m.h.shams_at_gmail.com]
Sent: Samstag, 24. Mai 2008 12:33
To: users_at_glassfish.dev.java.net
Subject: exception handling in EJB3 Stateless and JAX -WS. guide
tutorial example...
hi all,
im looking for guides and examples for Exception Handling in EJB3
Stateless Session Bean and JAX WS
any resources ? idea ?
--
sincerely yours
M. H. Shamsi
--
sincerely yours
M. H. Shamsi