Sara,
First let me say that you've come to the right place. Any list of this
nature has it's pros and cons, but overall I've had a great experience
with this group.
Now a little bit about me. I've run the gambit of development projects
from small local clients to large, dare I say HUGE, multi-year,
enterprise applications using the heaviest sledge-hammer development
toolkits you'd ever hope to find.
In fact I'm currently waist deep in Oracle ADF/FACES. If you're not
familiar with that, think .NET x 10 in complexity and size. Apparently
Oracle couldn't decide what camp to go with: Struts, Spring,
Hibernate, Java Server FACES, etc, etc... So they just decided to
throw all of those into their environment, along with their own
framework they call ADF (their implementation of FACES components).
Here is my personal take on Oracle ADF: If you could imagine a group
of relational database system engineers that set out to build a
development environment with the goal of supporting the development
workflow of systems like Oracle FORMS. That is what ADF is.
Now take ActiveRecord (Rails model object). A common thing you might
want to do with a database table would be to find all the records in
it right? So how do you do that with ActiveRecord? Ok say you have a
Person class. Since this would be a sub-class of ActiveRecord. You
could do the following:
@people = Person.find(:all)
But, there's NO WAY it can be that simple right? Well actually it is
that simple in Rails.
So how does that compare to Oracle ADF. Well first of all, don't even
think about sending a find message to a single object and have it do
the logical thing of returning you the rows of the database table.
First you would need to get an instance of the ApplicationModule that
connects to your database. With that object in hand you can search
within that module to get an instance of a ViewObject, which acts very
much like a database view. This in turn has an XML configuration file
that links things back to an EntityObject, which represents a database
table, again configured using another XML configuration file used to
map object attributes to database columns.
Ok after all this setup you can then ask the ViewObject to get the
rows of the table right? Wrong! You also need a DBTransaction object,
a ResultSet object, a ResultSetIterator object so you can walk though
and collect objects from the ResultSet. I may be leaving out a few
steps here (read "a lot of steps"), but you get the general idea.
Then don't forget to release your ApplicationModule or things get
really screwed up. Now keep in mind that you get to repeat this entire
process every time you want something from the database.
But, what if you don't want all of the records in the table? In Rails
you would do the logical thing, as follows:
@people = Person.find(:all, :conditions => { "fist_name = ? and age
< ?", [ "Bob", 18 ] }) // find all the under age 18 Bobs
And now for the Oracle ADF version...... Hell, let's not even go
there! But, it has something to do with ViewCriteria objects..... AHHG!
@!
P.S. In case you only wanted the first under 18 Bob. Just do this:
@person = Person.find(:first, conditions => { "fist_name = ? and age
< ?", [ "Bob", 18 ] }) // find the first under age 18 Bob
This is only a tiny, tiny morsel of what Rails is all about, but I
hope it wets you appetite for more.
All that in mind, can anyone point me in some direction as to whether
it's worth it to me to learn Ruby vs. sticking to some PHP framework?
P.P.S. As a developer you don't even need to ask this question. The
more you know, the more valuable you are, and the more choices you
have. Studying how other tools solve really tough problems will give
you insight into everything you do. As a developer you need to be a
sponge. Soak up every last bit of knowledge your brain can hold. I've
been a practicing software developer for 15+ years professionally and
close to 25 years personally. I learn something new every day. What
I've come to really appreciate is the younger people just getting into
programming. These guys, and gals, amaze me. I think that's because
they haven't been corrupted by years of programming. Someone new to
the game will try anything. Since they don't realize that it's
impossible, they just go ahead and do it!
My current favorite comment to a blog post I read recently:
"You less-code fanatics! Soon you will be writing so much less code
that it will converge on 0 lines proving that your so-called
productivity is an illusion. It takes lots of code to implement proper
BPEL/WS-*/EJB/MVC/J2EE/*** applications that leverage every pattern in
the book! That's the goal. If you happen to produce a working
application as a side effect, you can always re-factor it out."
Enterprisey Architecty, May 9, 2006 12:33 AM