GWT migration
We’re using GWT 2.0.3 on one of our projects. Today we’ve noticed a very strange defect in IE8 and decided to upgrade to the latest version which is now 2.2.0.
So initially we’ve got three modules with four languages specified. All this stuff was referencing GWT 2.0.3 and gwt-maven-plugin of version 1.2 was used for compilation.
During upgrade the following changes were done:
- Referenced GWT version was changed to 2.2.0
- gwt-maven-plugin version was changed to 2.1.0-1
- Scope of the com.google.gwt.gwt-dev was changed from test to compile otherwise I was getting “java.lang.NoClassDefFoundError: com/google/gwt/core/ext/GeneratorExt”
- Refactored module inheritence slightly otherwise I was getting: “Element ‘property-provider’ beginning on line 75 contains unexpected attribute ‘generator'”
So the migration ran pretty smoothly and I haven’t noticed any new problems in the application itself. But this migration has brought a huge benefit in compilation time.
Module | 2.0.3 compilation (in seconds) |
2.2.0 compilation (in seconds) |
Difference |
---|---|---|---|
Module 1 | 611 | 390 | -36% |
Module 2 | 703 | 394 | -44% |
Module 3 | 118 | 142 | +20% |
Total | 1617 | 1064 | -34% |
GWT compilation speed is the major factor which affects build time on our project. And this upgrade reduces the whole compilation time by 34%. You definitely should consider upgrading taking into account new tasty features of GWT 2.2.0.
Greetings. <br /><br />Thanks very much for posting this. <br /><br />I am having the very same "Line 75" problem in my project as you mention above, having just upgraded to GWT 2.2.0. You allude to "Refactored module inheritance slightly" as your 'cure'. Can you please specify exactly what you did?<br /><br />Many Thanks.<br /><br />jgenoese john@
So I've got the following structure:<br /><br />BaseModule -> (Module 1, Module 2, Module 3)<br />Each of the inherited modules specified the following set of inherited modules:<br /><br /> <br /> <br /> <br /><br /> <br /> <br /> <br /> <br /><br />So I just left , moved all of the inherits instructions into the base one.<br /><br />Also I've changed the order
Hell, it has eaten all of the tags.<br /><br />BaseModule -> (Module 1, Module 2, Module 3)<br />Each of the inherited modules specified the following set of inherited modules:<br /><br /><inherits name='com.google.gwt.user.theme.standard.Standard'/><br /> <br /><inherits name="com.google.gwt.i18n.I18N"/><br /><br /><inherits name='
Thanks much for replying. <br /><br />My original .gwt.xml was very simple, inheriting only …user.User and …themes.Standard in that order. After reading your post, I added I18N at the very top. <br /><br />Unfortunately for me, I get the same failure. <br /><br />I should point out that this is a Mavenized Eclipse project, and the Maven build is working. It is the Eclipse WindowBuilder(GWT
The issue I was having had to do with installing Eclipse plugins that apparently conflicted with one another. There are some hoops to jump through as well in terms of setting the Eclipse project up, having to to with Ordering and Exporting the Java Build Path. <br /><br />Thanks once more.
Hello together, I have the same problem and I already ordered the inheritance in my gwt.xml:<br /><br /><br /><br /> <br /> <br /><br /> <br /><br /> <br /> <br /> <br /> <br /><br /><br />@John: How do you solve your problem? Which part of the build path must be refactored?
Have you put I18N module at the top?<br /><inherits name="com.google.gwt.i18n.I18N"/>