Grails 0.4 – “rock your socks off”

Posted by: on Feb 1, 2007 | One Comment

(apologies to Tenacious D) Graeme Rocher announced yesterday the public 0.4 release of Grails. We’ve put a lot of effort into this release and it’s been some time coming but what we, in particular Graeme, have achieved in this time is amazing. This new version takes away the pain of HTML escaping, URL encoding, issues where SQL schemas weren’t coherent with the constraints, and makes unit testing of artifacts much easier. For example unit testing GSP taglibs can be done like this:

class YourTagLibTests extends GroovyTestCase {
void testTagWithAttribs() {
def taglib = new YourTagLib()
final StringWriter sw = new StringWriter();
taglib.out = new PrintWriter(sw)
taglib.tagNameHere([attrib1:'value1', attrib2:'value2'])
assert 'expected output' == sw.toString()

How easy is that?! Controllers also no longer need the "def params = [:]" to enable unit testing. Using grails 0.4 snapshots and now the final release I have put a high profil commercial site live ( last week, and there are more to follow very soon. It’s a testament to the web agency enotions that they had the confidence in my enthusiasm for Grails to take it on board for our high-end sites for some major UK consumer goods brands. Starting from something close to Grails 0.3 and moving towards 0.4 during this development we solved many of the common issues related to deploying high quality sites with the framework. Without the work required to hit the pain points, log issues and in some cases contribute the fixes, I am confident that Grails slashed our site code development process down to a few days. Graeme and the other Grails developers were always patient and helpful, which was much appreciated with our tight deadline! I haven’t had to touch an SQL Schema, and I get trivial back-end "admin" interfaces for free from scaffolding! I’m really looking forward to 0.5 :)

1 Comment

  1. Sebastian
    February 4, 2007

    I cannot count the number of times I’ve had to say to you “I DO trust you Marc, I just don’t GET it yet” – but I am glad to say that I am now a Groovy/Grails convert and I look forward to learning the ins and outs!