Debug GWT Application with Tomcat (Eclipse)
Asked Answered
S

2

3

I have tried to deploy the application with tomcat and I am succeeded. Now instead of internal GWT server I need to set tomcat as default inbuilt server and debug my application with it. The problem here I am facing is I am able to upload file into hosted mode successfully but when I tried to deploy my application to tomcat it gives me error to Struts interceptor.

ERROR ParametersInterceptor.setParameters():242 - ParametersInterceptor - [setParameters]: Unexpected Exception caught setting 'fileUploadContentType' on 'class com.example.server.actions.FileUploadAction: Error setting expression 'fileUploadContentType' with value '[Ljava.lang.String;@12569b8'
ERROR ParametersInterceptor.setParameters():242 - ParametersInterceptor - [setParameters]: Unexpected Exception caught setting 'fileUploadFileName' on 'class com.example.server.actions.FileUploadAction: Error setting expression 'fileUploadFileName' with value '[Ljava.lang.String;@13fb1ab'

I request you suggest me the solution to this issue or redirect me on how to debug with tomcat in eclipse (GWT).

Can anybody redirect me on this issue...

Any help is much appreciated.

Thanking you,

Regards

Sanitation answered 31/1, 2011 at 6:29 Comment(1)
Are you using the eclipse plugin?Ablaze
A
7

It's really easy, just follow these steps:

  1. Get google plugin for eclipse
  2. The in eclipse, right click on your project and choose Debug as -> Web Application (running on external server)
  3. Enter URL of your web app on tomcat (like http://localhost:8080/YourApp/YourApp.html and eclipse will give you new one - it will add stuff like ?gwt.codesvr=127.0.0.1:9997

And that's it. Just set up your breakpoints and debug!

Aday answered 1/2, 2011 at 0:17 Comment(2)
Thankx for the answer... But i dont have an option like Debug as an external server... ! :(Sanitation
You will have once you install google plugin and restart eclipse, I believeAday
B
0

Have you tried to configure your struts.xml file to exclude parameters that seem to cause problem?

<interceptor-stack name="defaultStack">
   <interceptor-ref name="params">
      <param name="excludeParams">fileUploadContentType,fileUploadFileName</param>
   </interceptor-ref>
</interceptor-stack>
Bonitabonito answered 31/1, 2011 at 15:17 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.