On Mon, May 21, 2012 at 11:04 PM, Tharindu Mathew <[email protected]> wrote:

> When I execute, e.getMessage() at the Front end after catching the
> exception, I only get the Exception class. At the BE, the exception is
> thrown properly.
>
> ex: GadgetGenAdminServiceGadgetGenException
>
> What is the proper way of propagating the faut message from the BE to the
> FE?
>

is this an in only or in out operation?

This is what need to happen

you need to write the Admin service method like this,

public String testMethod() throws TestException

Now you should see a fualt message declared in the corresponding operation
of wsdl.

When you generate the code you will see this exception in the stub method.
(Actually that is an ADB generated code for that fault message)

So you can catch that exception in your client.

if you want to pass some attributes you need to add them to TestException
class

eg.

TestException {
     private String message;
}

thanks,
Amila.

> --
> Regards,
>
> Tharindu
>
> blog: http://mackiemathew.com/
> M: +94777759908
>
>
> _______________________________________________
> Dev mailing list
> [email protected]
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
*Amila Suriarachchi*

Software Architect
WSO2 Inc. ; http://wso2.com
lean . enterprise . middleware

phone : +94 71 3082805
_______________________________________________
Dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to