-
Notifications
You must be signed in to change notification settings - Fork 3
HowtoUseHostedModeOfEclipseGwtPlugin
For increasing the productivity when working with GWT, it is recommended to work with the GWT Eclipse Plugin. This side will show you the tipps and tricks to get the hosted mode working with Eclipse.
Before you can create a new runtime configuration you need the following plugins be installed in Eclipse:
The most annoing thing when using Eclipse is the automatic exclusion of all resources from the build path. This generates the most of the errors when working the first time with GWT. This can be solved by simply opening the properties of the client project. Go there to the "Java Build Path" entry. Select the "source" tab, select under client/src/main/resources the "Excluded" entry and click on the "Remove" button. After this behind "Excluded" should now be written "(None)". Now you should also see that the resources are represented as a package structure.
Now you can enable the GWT Plugin support for the client project by going to the project properties. On the left side select "Google/Web Toolkit" and check the "Use Google Toolkit". Use as default SDK GWT 2.2.0 and control that the Entry point WiseUi is added to the list. When it is not add to the list, check the previous step!
When you try to run your client project as Web Application
you will get an error. But this can be solved by simply creating a Run Configuration manually. Then go to the Run Configurations...
Dialog and double click on Web Application
. In this new configuration go to the Main
tab. In the empty field for the Main class:
insert the following class:
com.google.gwt.dev.DevMode
Now go to the "Arguments" tab and enter the following:
-remoteUI "${gwt_remote_ui_server_port}:${unique_id}" -startupUrl WiseUi.html -logLevel INFO -port 8888 -war "<workspace>\wiseui\client\src\main\webapp" -codeServerPort 9997 eu.wisebed.wiseui.WiseUi
Replace the <workspace>
part with your path to the workspace.
Now you can click on "Apply" and run the WiseUi inside Eclipse.
The following error can occur when running WiseUi in Eclipse:
Caused by: org.springframework.beans.factory.parsing.BeanDefinitionParsingException: Configuration problem: Unable to locate Spring NamespaceHandler for XML schema namespace [http://www.springframework.org/schema/tx]
Offending resource: class path resource [persistence-spring-config.xml]
This error only occurs in Eclipse and relates to the Issue #45 in our bug tracker. The current solution for this problem is to extract the spring.handler
file from the spring persistence JAR and add this file to the META-INF directory of the persistence module.