Grails: Absolutely pure productivity.

April 30, 2010

Your IDE can do more.

Recently, I decided I had a need to build a quick web service to back an AJAX application for iPhone that I’m developing. jQTouch is making the front-end work pretty simple, but I just wanted a super fast way to get a web service up and running that would be maintainable and easy to scale. I considered Spring with Tomcat/Hibernate, but I didn’t want to spend a week configuring XML. I’ve attempted to Ruby/Rails in the past, but I always missed being off the JVM. Then, I came upon Grails. It’s fast, it’s easy, and it’s Java (…ish), so in that sense there’s little to no learning curve aside from that of the Grails framework itself.

To begin my quest to utilize Grails, I attempted to setup Eclipse with the grails plugin. After a pound of headache, I just gave up. Then, I came upon Netbeans grails integration.

Check this out.

  1. Create a project.
    Step 1
  2. Let grails do its magic.

    Step 2

  3. Click the magic run arrow.
    Step 3
  4. Watch Grails start automagically under Jetty.
    Step 4
  5. Create a Domain class.
    Step 5
  6. Step 6

Now, any changes you make in the IDE to the controllers, services, or domain classes gets picked up immediately by the running webserver. In one click, you can deploy your entire application. After that one click, everything just works. This is how all IDEs should handle server deployment. Aside from this ridiculously easy setup, grails gives you dependency management off the bat with Ivy, which can be configured to use the maven2 repositories.

Check it out.

Dependency management

FURTHERMORE, grails deploys WARs for your application, so there’s no trickery to get your web application running. Develop under grails, then drop your WAR in your application container and be done with it.

Use Grails. It’s awesome.

tags: , ,
posted in prog by Stefan Kendall

Follow comments via the RSS Feed | Leave a comment | Trackback URL

Leave Your Comment

 
Powered by Wordpress and MySQL. Theme by Shlomi Noach, openark.org