Today, Grails 1.1.1. was released with support for deploying applications on the Google App Engine. Here are five reasons why I think Flex Developers will fall in love with a Grails / GAE backend.
- Configuration-free BlazeDS and GraniteDS.
BlazeDS and alternative GraniteDS provide powerful AMF and remote procedure calls from the server to the client. They are also incredibly convoluted to set up, involving reams of XML configuration files and often animal sacrifices. Grails takes away most of the configuration pain and provides nice convenience methods to automatically generate your as3 files and hook them up conveniently.
GraniteDS has much better support, and is available to Grails via the GraniteDS plugin. This is as close to a dream plugin you can get. Check out all the features -> AS file generation, lazy child loading, the ability to annotate services and domain classes – It’s got it all.
BlazeDS is lagging behind right now with the Flex Plugin and Flex Scaffolding Plugins. But with the strong effort put in by Spring ( owners of Grails ) in it’s BlazeDS integration project, this support is guaranteed to get better very soon. Somebody needs to just sit down with Marcel Overdijk and offer him a gigantic suitcase full of money to make this work.
- Get rid of Pesky Security Exceptions
Grails uses Groovy – a much simpler and more powerful version of Java that allows you to solve common Flex problems with few lines of code. Don’t believe me? Check out my post yesterday where I build a Proxy service for third party pages with just one line of code...
- Bend Data
Grails takes a lot of powerful Java libraries and wraps them into easy to use Plugins. With Grails, you are able to provide navigation and HTML integration of Flex services easily and effectively. Need a rules engine, no problem. Output data in PDF? RSS? iPhone view? Captchas? In fact, there is probably a great Grails plugin for most any business and backend need that might arise. This makes Grails the perfect Glue language for your server side needs.
- Rock solid performance and new tools:
The App Engine is hosted by Google, not some unknown PHP hosting provider with a rack of servers in his basement. And it offers some nifty new Services, like a memcached and an image transformation service. Integrating these into Grails simply involve adding the jar file and calling the service. Grails also simplifies the guesswork in developing for the app-engine, by providing scripts for generating Google App Engine friendly domain objects and CRUD functionality via the app-engine plugin.
- 10 Gigabyte transfer. Per Day. Each Way. FREE
I know you might be snickering, “thanks, that’s great, but I get this with Ruby on Rails or PHP too, why would I bother learning a whole new way of doing my work”.
Here is perhaps the biggest reason you should consider the App Engine – it offers you 10 Gigs of data transfer per day. Each way. And it’s free! Best of all, you can create up to 10 applications with the Google App Engine.
( This changes after May to 1 gig a day – but how often do you really use 1 gigabyte per day? )
If you want to harness the power of Google App Engine for Java without having to deal with the hassle and pain of Java, give Grails a try. It comes well integrated with Java IDEs like Netbeans, uses a dynamic language called Groovy that gets rid of all the stupidity in Java, and is built around solid MVC principles. I’ve used Grails consistently for the last year in my Flex development, and it has allowed me to build very powerful applications very quickly. Try it out, you won’t regret it.
SHAMELESS PLUG: If you liked this post, check out Empora.com – a new website that allows you to find items via visual fashion search technology.