More OT-ness, sorry Rick... I also find many (but far from all) things in Ruby/Rails follow the Principle of Least Surprise. As for Scaffolding, I actually don't use it a lot. Since we do Test-Driven Development, I often just start from scratch. Unless you are doing straight-up CRUD or REST scaffolds, there often isn't a lot of useful stuff in the scaffold; you end up deleting more than you use. The standard-generated tests certainly suck, and are worse than none at all in some cases, IMHO, because they give people the idea that minimal, cookie-cutter tests are OK. Maybe that's what Venkat was talking about.
Rails still has a lot of warts, and is downright buggy in a lot of areas, but the power of Ruby lets you fix these fairly elegantly [1] in many cases. Warts aside, Rails got a lot of things right. Migrations is one of these, as well as Capistrano. The ActiveRecord implementation is another - it's very powerful, flexible, and succinct, as illustrated here: [2]. I'm not sure what Grails is doing different that is "class-first", or why AR would be considered "table-first" in contrast? Do you have to explicitly define all columns in Grails model classes? I'd consider that a downside. Regardless, once you start "getting" ActiveRecord and Embrace the Conventions, it feels nice and cohesive. There are numerious gotchas of course, but once you know your way around (which I'm still working on), you can quickly, easily, and elegantly do all sorts of useful stuff in your Model layer. You even start doing crazy things like pushing everything you can down into your Model [3]. It works out well, especially in RESTful architectures. As a pre-emptive strike against the performance naysayers, I can point to real world evidence [4] that with creative caching [5], you can make the interpreted-language slowness a relative non-issue for many sites. Rails isn't for anyone, it would be nice if it didn't have warts, and I can't conceive of attempting to write real Rails apps without a disciplined and sophisticated testing approach, but I certainly like it. YMMV. -- Chad [1] http://viewvc.rubyforge.mmmultiworks.com/cgi/viewvc.cgi/desert/trunk/lib/desert/rails/?root=pivotalrb [2] http://www.pivotalblabs.com/articles/2007/08/08/advanced-proxy-usage-part-i [3] http://www.pivotalblabs.com/articles/2007/07/26/access-control-permissions-in-rails-access-control-permissions-in-rails [4] http://www.pivotalblabs.com/articles/2007/06/27/rails-slashdotted-no-problem [5] http://www.pivotalblabs.com/articles/2007/08/08/cacheable-flash On 8/10/07, William H. Mitchell <[EMAIL PROTECTED]> wrote: > I can't recall the name of the Rails adjunct that provided > Grails-like scaffolding. > > I have to say that I like Grails' class-first approach better than > Rails' table-first approach but it'll be interesting to see what the > Grails guys come up with for migrations. (At NFJS Jeff Brown said > they're working on it...) > > A little OT...I've been working through "Groovy in Action" and hardly > a session with Groovy goes by without an unpleasant surprise or > two. When learning Ruby there were numerous times when my intuition > was correct about how two pieces would fit together. With Groovy it > seems like I'm constantly out of step. > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
