Wednesday 17 November 2010

configure an external Tomcat 7 server in GWT 2.1 eclipse plugin

So the official information for this matter mostly comes from this location:
http://code.google.com/eclipse/docs/faq.html#gwt_in_eclipse_for_java_ee

First, you need to have Java EE IDE (Eclipse for Java EE) installed and configured WTP server adapter for tomcat (Window --> Preferences --> Server --> Runtime Environment)

Second, instead of creating a GWT web application, you need to create a dynamic web application, then goto to property page of the project, select google-webtoolkit, check "use GWT", then go to google-web application, change the directory name to "war" (make it similar to a GWT web application layout), uncheck "launch and deploy from this directory". Now add the project to your server by left-clicking the "servers" and publish your web app., i.e. write to the "yourworkspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps".

Third, When creating a new Web Application launch configuration, make sure you input the right URL on the GWT tab by including the project name in the URL path (e.g. http://localhost:8080/projectName/theFrontPage.html)

No comments:

Post a Comment