tags:

views:

151

answers:

2

I'm coming across references to 'Grails' and 'Groovy' quite often these days.. mostly on how great a productivity booster it is as opposed to standard J2EE, or things like JSF, Struts etc.. And there's also an impressive set of case studies in support of this on their web site too. So I just thought I would explore some of it..

As I start off on this, I was curious if there was any material (link, blog, article, paper..) that explains what are the special features in Grails+Groovy (and not found elsewhere, in the J2EE world) that makes it a more productive environment to work in?

Thanks!

+5  A: 

The Wikipedia Grails page provides a basic explanation:

Grails has three properties which attempt to increase productivity when compared to traditional Java web frameworks:

  • No XML configuration
  • Ready-to-use development environment
  • Functionality available through mixins

The first point should really be "less configuration" as a result of RoR-popularized configuration-by-convention: the framework addresses development of a certain class of applications and provides sensible defaults in that context.

The second point is also valuable: a hello world application can be both developed and deployed in a couple of grails commands. This reduces the barrier to entry, increases mind-share and makes for a more streamlined development experience compared to pure Java development.

I'll use an example from the Grails GORM page to illustrate the 3rd point. Grails allows you to write this kind of code to retrieve a book by its title from the "book" table without having to set much of anything up:

Book.findByTitle("Groovy in Action")

Of course, it's the result of a much more general property of Groovy: its dynamic nature.

For more practical productivity increase reports, see e.g. the Sky report.

Tomislav Nakic-Alfirevic
+1  A: 

A framework becomes useful when it minimize effort to do something. That's why C became more successful than Assembly, C++ improved on C, and Java on C++.

Although not strictly listed in pro and cons, I like the discussion of the subject in a blogpost by one of the early Groovy developers. Furthermore, I also like the discussion on another modern database-backed-webapplication framework by Martin Fowler, one of the leading architects in the JEE world.

I also came across Groovy first, while testing Java applications. You will come in touch with work of Dirk Koenig, e.g.short Groovy presentation. By the way, if you want to develop "cloud" related applications, then Ruby opens up a bunch of doors as well.

poseid