In your RPC Servlet, override the doUnexpectedFailure(Throwable t) method
and log the stack trace over there. GWT calls this method whenever there is
a server side exception.
@Override
protected void doUnexpectedFailure(Throwable e) {
LOGGER.error("Unexpected error while processing RPC", e);
super.doUnexpectedFailure(e);
}
--Sri
On 14 April 2010 14:10, dgiscool <[email protected]> wrote:
> Hi,
>
> How can I see the exception trace thrown out of the callback method
> code ? When the web service returns, it throws an exception and
> onFailure() method is invoked with the exception but how and where can
> I see the exception trace? I am running this on tomcat, I can't run it
> on dev hosted mode due to same origin policy restrictions. See the
> code below:
>
> userResource.store(id, new Result<User>() {
>
> public void onFailure(Throwable caught) {
> System.out.println("Error in submission ");
> GWT.log(caught.getMessage(), caught);
> caught.printStackTrace();
>
> }
>
> public void onSuccess(User v) {
> System.out.println("Success = " +
> v.getName() );
>
> }
> });
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected]<google-web-toolkit%[email protected]>
> .
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>
>
--
You received this message because you are subscribed to the Google Groups
"Google Web Toolkit" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/google-web-toolkit?hl=en.