Friday, March 31, 2006

There is no silver bullet...

If you care about software engineering as a practice, and you care about being a g{ood,reat} software engineer then you have probably read Fred Brooks' seminal article on solving the essence of software engineering problems. This article was written in 1987 and as I was reading it over again this afternoon it was as fresh to me as when I read it in college (thanks Professor Werner) in 2001, and still as fresh as it must have been in 1987. To put this into perspective, in 1987 I was 6 years old and Microsoft released Windows 2.0.

That being said, the reason I was re-reading this article is because the other night I finally got a chance to spend some real time with Ruby on Rails. I, as most people I have talked to, was blown away when I "got it." Rails makes writing database backed web applications simple, straightforward, and alot of fun. I hope it stays this way. In my opinion the worst thing that could happen to Rails is for people to start looking at it as a hammer and every project they get put on a nail because, as Fred Brooks has pointed out, there is no silver bullet and there isn't likely to be one anytime soon.

Rails can't/won't slay the Werewolf that is software projects but it is pretty adept at slaying one particular kind of beast. Rails is not the "silver bullet" but for database backed web applications (with AJAX, I might add) it is golden. Writing software is more like taking on every mythical beast known to man than it is like slaying a werewolf. So we could say that DB backed web apps are vampires, and Rails is the wooden stake that we can drive into its heart. I think that's a fitting analogy for Rails because it does go straight to the heart of the problem you're trying to solve. It's a little peice of our software engineering arsenal to be used in specific situations. Kind of like how nearly every boss monster in nearly every single video game I played growing up, and I played quite a few, had a particular weakness that I could exploit to achieve victory.

As software engineers the sooner we stop looking at all software engineering projects the same way the better off we'll be. I'm not the first one to say these things. We have to be actively on the lookout for more wooden stakes. More weapons for our arsenal. As creators we need to identify the applications we build time and time again and create frameworks like Rails to help us slay those beasts because if you've used Rails you know that when your project falls into the Rails sweet spot you've got a good opportunity to knock it out of the park EVERY SINGLE TIME. The reason for this is that the less code we write, the more time we can spend on solving the essence of software systems as pointed out by Fred Brooks. Now to quote from the article a bit

There you have it, straight from the horse's mouth. To get back to how Rails fits into this lets look at what it does for the above issues:
3 out of 4 ain't bad!

What is the single most important thing that we can take with us from Rails when we have to do something other than database driven web applications? Find more weapons! Build your arsenal!! As Dave Thomas of the Pragmatic Programmers has pointed out in his talks and books "Build your knowledge portfolio." And as you do, be on the lookout for wooden stakes, clubs (to smash zombies heads w/), silver bullets (for when we DO run into werewolves), water (for the wicked witches), and whatever other mythical weapons you can find for solving the task at hand.

Comments:
The MVC model transforms a complex problem into a clearly defined one. Remember those nightmares with PHP scripts where you were calling the database, reading from it, interpreting the data, studying the cookies and POSTS and GETS and deciding the show off all at once (until you learned to put a couple of lines apart in a different file, but all and all it was still the same thing just a little enlighted)?

So here we have clear and distinct programming wires and schemas. And whether your model would not be well defined, it would immediately show up along the programming and testing processes. That is not a full merit of Rails, but it gets benefitted from the full use of that paradigm.

No more invisibility. So I bet that's 4 on 4!
 
Post a Comment

Subscribe to Post Comments [Atom]



Links to this post:

Create a Link



<< Home

This page is powered by Blogger. Isn't yours?

Subscribe to Posts [Atom]