On 9/23/05, hal helms <[EMAIL PROTECTED]> wrote:
> Oh, diggity: I could get seduced back into using Smalltalk...although I hear
> Ruby is pretty sweet. I'll have to check Rails out: I know too little to do
> more than voice an uninformed opinion.

Actually, Ruby owes a lot of it's idioms to Smalltalk -- there's a
definite thread of connection.

And I'll take the opportunity to point out that I'm talking about this
exact subject at the Fusebox and Frameworks conference next week.
Maybe we need to add a BOF? Here's a quick synopsis

"And while you can't build your ColdFusion application in Rails
(yet!), there's still a lot that can be learned from the framework and
the Rails approach to application architecture. Come learn about the
framework that's having Java, PHP, and even .NET developers thinking
about running Ruby on Rails for their next application"

Sounds like it's going to turn into more of an open forum :) :)

But seriously, the big thing about Rails isn't that it's got ORM,
AJAX, or any of the other specific features. The key thing about Rails
is that the framework embodies many of the key best practices of the
Agile methodologies and bakes them right into the framework.

For example:
  + MVC design is required
  + conventional configuration is automatic
  + dev/test/production is built into the framework (you change an
environment var, not code)
  + testing's built in (functional, unit, and even performance).
  + you can directly interact with the running application from the
command line (e.g. dump out an object from the *production*
application, while it's running).

etc, etc. Fundamentally, it makes things easy unless they need to be
hard -- and then all of the basic assumptions can be overridden
without massive code changes.

More importantly, Rails makes it *really* hard to write bad code :)

One quick example, David HH (the Rails creator) likes plural database
table names and underscore, so Rails ASSUMES that the the LineItem
object is stored in the database table line_items. If you're ok with
that, you're Ruby code is

class LineItem < ActiveRecord::Base
end

But if you'd rather name the database table in the singular and
without underscores, your code becomes

class LineItem < ActiveRecord::Base
  set_table_name "lineItem"
end

So follow the convention, no problem. Have your own convention, no big deal.

As an aside, the pluralizer in Rails is pretty basic -- it understads
that Person should be people and that Datum should be data in the db,
but it doesn't understand that Sheep is not sheeps... so

class Sheep < ActiveRecord::Base
  set_table_name "sheep"
end

The Pragmatic Programmers (Dave Thomas/Andy Hunt) are some of the best
methodology guys around, and they are smitten w/ Ruby in general and
Rails in specific. And the open source community (esp the Java folks)
are jumping on board -- I had dinner with Dave Thomas, David HH
(rails' creator), James Duncan Davidson, Erik Hatcher, and a few
others at OSCON just as the book on Rails was being released. The
interest is *phenomenal* -- and extremely serious.

The rails book from the Pragmatic Programmers is probably the best
serious source for learning rails, other than the rubyonrails.org
site.

The reason this should be important to you as a CF developer is twofold:

1) Frameworks build on the improvements of other frameworks. For
example, Tapestry is lots more flexible than Struts for many Java
apps, but there are many ideas from Tapestry that are informing the
design of Struts 2.0 (aka Shale).

2) Rails is the first serious new contender in the web dev world
that's object-oriented and RAD. Interestingly, many of the arguments
against it are similar to those against CF ("It can't scale". "What's
that weird langauge -- it's not .NET or Java", etc). CF's always had
the advantage over the other platforms in speed of development, easy
of use, etc. Rails certainly can complete on those terms. I think in
the coming 12-18 months, lots of proposals that might have gone to CF
shops may go to RoR since the Agile java folks are heading that
direction. My 2c.

--
John Paul Ashenfelter
CTO/Transitionpoint
(blog) http://www.ashenfelter.com
(email) [EMAIL PROTECTED]


----------------------------------------------------------
You are subscribed to cfcdev. To unsubscribe, send an email to 
[email protected] with the words 'unsubscribe cfcdev' as the subject of the 
email.

CFCDev is run by CFCZone (www.cfczone.org) and supported by CFXHosting 
(www.cfxhosting.com).

CFCDev is supported by New Atlanta, makers of BlueDragon
http://www.newatlanta.com/products/bluedragon/index.cfm

An archive of the CFCDev list is available at 
www.mail-archive.com/[email protected]


Reply via email to