Friday, January 4, 2008

Major GWT Pain: Translating and reusing Objects for over the wire transport.

I had my brush with first major pain using GWT today - translating and transporting Objects over the wire.

After reading numerous posts on the gwt groups, I decided to try to reuse and transport the model entities over wire using a GWT 1.5 build. I ran into my first pain point - need to have model entity sources on the classpath, and have a GWT module specified for them. Since my project is broken up into separate modules (and Eclipse projects) this was not as straight forward. I finally ended up adding 'Model.gwt.xml' to my web-module itself and 'installing' (Maven speak!) sources for model classes to the local repository.

Tried running the GWT compiler again, and it complains about javax.persistence.* imports. Fixed that by including Geronimo sources JAR; tried again, and now its a bunch of Guice and Commons Loggin imports :-(