Is there room for both Rails and Grails in a company?
For the last week, I've been knee deep learning more about Rails and Grails. The reason is because I think developers (and companies) are going to have a hard time deciding which framework is best for them. The real question is: do they both do the same thing or are their different applications for each? Is "Grails vs. JRuby on Rails" a "Struts 2 vs. Spring MVC vs. Stripes" argument - where they're all so similar it probably doesn't really matter which one you choose?
Of course, the Stripes folks will object, but I really don't think it's that much better than Spring MVC 2.5 or Struts 2.1. Sorry guys.
If it is a Spring MVC vs. Struts 2 type of argument, then it seems to make sense for a company to standardize on one -- don't you agree? Does it make sense to allow both frameworks in a company if they're so similar?
Google has had much success in restricting its allowed programming languages to C++, Java, Python, and JavaScript. Shouldn't other companies do something similar? It seems like a good idea to restrict allowed web frameworks to a few as well. For companies with successful Java infrastructures, it seems logic to allow one Java-based web framework and Rails or Grails for getting things done as fast as possible.
Here's the sticking point: Ask any Rails developers and they'll say Rails wins hands down. Ask any Grails developers and they'll say Grails is the easy choice because it builds on top of Java's strong open source projects. Blah, blah, blah - where's the objective voice that's identified the "sweet spot" for each?
The Relevance guys, particularly Stuart Halloway, has a post about How to pick a platform. The logic in this post seems to imply that both frameworks do solve the same problem - just in different ways. Stu seems to recommend Rails for most applications, because Ruby is a better language. He says Grails might win if you have "an established team of Spring ninjas".
I know Stu and believe he does know his stuff (in both Java and Ruby). So is this the definitive guide on which framework to choose? If you have a staff full of Java developers, they should start learning/using Rails rather than doing the easier transition to Groovy, which they pretty much already know?
I don't know what the answer is, but that's what everyone seems to be saying. The problems is, the authorities on this matter (Rails vs. Grails) are often "head honchos" in companies that have a vested interest in seeing their respective framework/platform succeed. Since the Relevance team employs some Grails developers, it seems they're less biased. But who knows.
Is Rails really head and shoulders better than Grails? I don't think so, but I've only been programming with both for a week.
Posted by DanielHonig on January 30, 2008 at 07:13 PM MST #
Posted by Karsten Voges on January 30, 2008 at 08:32 PM MST #
I'm in the same boat as far as Grails is concerned, as I have only been developing with it for less than a week. But I have been developing Rails for about a year now, and thus far haven't encountered any stability issues in my production application environment. Furthermore, the development process of my Rails app has been and continues to be a much more pleasant one than the last WebSphere/Struts/Hibernate project I worked on.
But Rails as a framework starts to suffer when you take it out of its niche and start trying to make it work with legacy codebases and schemas. That's why Grails has piqued my interest - RAD goodness with the power of Spring and Hibernate hiding under the covers? That sounds like your classic "have your cake and eat it too" situation. If Grails offers a similar experience to Rails (which is a positive one), then Grails might just be a better mousetrap.
Posted by Kevin Whinnery on January 30, 2008 at 09:25 PM MST #
I was assigned a project to build rather quickly the two weeks ago. I am a Java developer and found that while rails was great I needed to System Admin to get a test application going since to install a GEM was requiring access to /usr/local. I was a bit miffed by it and downloaded grails
ran grails create-app, created domain classes and was up and running without even needing a database since HSQLDB is set up to go by default. After 2 days with rails I switched to Grails and felt a WHOLE lot more comfortable. No need to futz about with SQL statements creating tables first etc. Just define classes and you're off No real need for RAILS going forward for my needs There basically isn't anything that RAILS does that GRAILS does not do.
As for the legacy application support I am not sure what exactly you are referring to because Grails handles Legacy just fine so please put the FUD Porridge gun down. Grails works just fine and is great if you are already working with Java. I dont see what the problem is Download them both and test out for yourself you will see that Grails has come out as good as rails if not better since it learned from Django, Raiils and turboGears etc...
Posted by SM on January 30, 2008 at 09:45 PM MST #
Posted by 71.75.148.242 on January 30, 2008 at 10:14 PM MST #
Posted by Sakuraba on January 30, 2008 at 10:27 PM MST #
We have no Spring or Hibernate "ninjas" here but any Java EE developer will be able to get up and running with Grails pretty quickly, as I'm sure Matt will see as he continues his investigation.
Posted by Dave Klein on January 30, 2008 at 10:51 PM MST #
Posted by John Mark on January 31, 2008 at 02:54 AM MST #
Posted by Debasish Ghosh on January 31, 2008 at 04:49 AM MST #
They both work fine. I think Grails is a more complex system than Rails, since it is dependent on other huge projects (spring, hibernate, servlets) for it's capabilities. The Rails stack flows together naturally, while the the Grails stack is a really clever layer over top of the other stuff. That said- one of my favorite Ruby libraries, Builder, is a copy of the XML building technique of Groovy.
Overall- Ruby core libraries are more full featured than than Groovy or Java, and the Rails extensions result in a very intuitive way of building applications. In many cases, I am able to sit down with a business user in front of one of the large Rails applications I work on and actually have her watch and understand most of the code I am writing to implement a feature she wants. Very cool.
I still see room for a simpler Java framework- something with Servlets as controllers, ActiveRecord equivalent for models and something like GSP for views?
Posted by matt m on January 31, 2008 at 05:36 AM MST #
Posted by Stuart Halloway on February 04, 2008 at 06:06 PM MST #