Hawaiʻi's Technology Community

GWT: Finally A Java Web Framework That Doesn't Suck

Although Ikayzo does web development, I've personally been doing mostly desktop development for the past five years. I've worked with Swing, SWT, WinForms and WPF. Every time I was forced to work on web projects I cringed because the UI piece was so much uglier and less evolved than any of the aforementioned desktop frameworks. Recently Pat and I started work on a new business that requires web programming and we settled on GWT for the UI (with a Flex version to follow soon.) I briefly fiddled with the first release of GWT which was interesting but limited. For the past three days I've been diving in with GWT 1.5 and
GWT-EXT and I have to say, this toolkit is absolutely fantastic. I've fallen in love with web programming again. If you haven't heard of GWT, you can read all about it on the
GWT Google Code page. The first paragraph really says it all - "Google Web Toolkit (GWT) makes it easier to write high-performance AJAX applications. You write your front end in the Java programming language and GWT compiles your source into highly optimized JavaScript. Writing web apps today is a tedious and error-prone process. You spend 90% of your time working around browser quirks, and JavaScript's lack of modularity makes sharing, testing, and reusing AJAX components difficult and fragile. It doesn't have to be that way." The Java to Javascript compiler is an impressive feat of engineering. I'll probably go into this in a separate post. The fact that I can use the same language for all tiers of the application is a big win. The ease of use coupled with the quality of the components, GWT-EXT in particular, really puts this framework on a different level. The GWT-EXT components are fast, responsive and feature rich. Many components such as the tree and table have built in drag and drop capabilities with translucent drag images, visual feedback for drop targets, etc. If you are starting a new web project, I highly recommend you give GWT a try. Flex and GWT have finally made web programming as elegant and easy as desktop programming.
Ikayzo - Design • Build • Localize | Web • Desktop • Mobile

Views: 365


You need to be a member of TechHui to add comments!

Join TechHui

Comment by Daniel Leuck on August 18, 2008 at 12:40pm
Today we discovered an important distinction between GWT-Ext and Ext GWT. If you are considering going with GWT-Ext, don't. The GWT-Ext gallery showcases more widgets, and they look slick, but underneath they are basically thin wrappers around Javascript components. This makes them very hard to debug. Ext GWT is over 99% pure GWT Java with only a few JSNI calls in places where its unavoidable. This is clearly more in the spirit of GWT. Its definitely worth it to shell out a few hundred bucks for Ext GWT if you are working on a serious project.
Comment by Brooke Fujita on July 29, 2008 at 6:37pm
Ah, I love it when I am proven wrong...

One thing about the GWT is that is more of an all-Java or nothing affair, with respect to GWT-RPC.

Not true! On of my favorite blogsites on GWT, called, oddly enough, onGWT, had a recent posting on the porting of the RESTlet API to the GWT 1.5 release candidate.

The payoff? If you use GWT 1.5 and this RESTlet module, you are not limited to only GWT-RPC, but you should have access to any REST-based server-side resources. Sweet...
Comment by Daniel Leuck on July 14, 2008 at 1:42am
Hi Philip. Thank you for sharing your experience with GWT. Hopefully 1.5 addresses some of the issues you mentioned. I'm curious why unit testing was so painful. I would think the all-Java GWT approach would make unit testing easier, but obviously you have more experience with it than I do. Although we are just getting started, things look good so far.

I've heard great things about Wicket. From a quick examination I could see how it would be easier to, for example, subclass a component and make tweaks to the markup it generates. At the same time, I'd have a hard time giving up the rich GWT-EXT widgets that can be manipulated like Swing components. It is a bit weird to be so far away from the markup (if that makes sense.)
Comment by Philip Johnson on July 13, 2008 at 1:01pm
We were using GWT for about a year to build the user interface services for Hackystat. While we were initially quite impressed with GWT, we found it to have a very steep learning curve (there are lots of subtle ways to screw up with GWT) and, at least for our application, we found unit testing to be incredibly painful. Eventually, we started looking around to see if there might be something simpler that still provides the kind of interactiveness of GWT.

For the past six months, we've been using Wicket . While there's still a learning curve, we have found it to be significantly easier to learn, debug, and enhance than GWT, while still providing all the Ajaxy type stuff people want from modern webapps. The user discussion group is extremely active and helpful: I've gotten answers to all my questions within a day after posting.

There are many delighted users of GWT, and you may well turn out to be one of them, but FWIW our experience wasn't so rosy.

Comment by Daniel Leuck on July 12, 2008 at 8:45am
Hey Brooke - Thank you for the tips. The JavaWorld article was a good read.

Brooke: Out of curiosity, have you looked at OpenLaszlo?

I gave OpenLaszlo a spin a couple years back but I gave up on it once Adobe threw its weight behind Flex. At the time, Laszlo didn't do DHTML. I'll take another look.
Comment by Brooke Fujita on July 12, 2008 at 3:30am
The Google Web toolkit is definitely a powerful option to have in one's bag of tricks. While the article is a bit dated (April of last year is dated??), the recipes and pointers in this JavaWorld article could be of help for you as you proceed in your project. I especially found Tip 2: Debugging and Error Reporting to be very good.

One thing about the GWT is that is more of an all-Java or nothing affair, with respect to GWT-RPC. But if you've a team of people who are very strong at Java and Swing, but not so strong at "low-level" JavaScripting/CSS, then you can really do a lot with GWT. I found it pretty good when paired with Spring/Hibernate, in that I could really separate the logical layers (front-end, data access, value objects, etc.) cleanly.

Still, if you need to provide for SEO or make it so that pages can be spidered by search engines, then you could be out of luck as with the GWT there is still the limitation of one entry point, and all of the text rendered is generated by JavaScript and not static pages.

But, yeah, you can do some amazing front-end magic with GWT/GWT-EXT.

Out of curiosity, have you looked at OpenLaszlo? It's an open-source library that lets you generate Flash .swf and/or DHTML. It's like compiling XML. You could pair OpenLaszlo front-ends with a web service, which would offer quite a lot of flexibility, I think. If it's XML-RPC, then the back-end could be written in any language you choose.


web design, web development, localization

© 2024   Created by Daniel Leuck.   Powered by

Badges  |  Report an Issue  |  Terms of Service