Rapid Red

Your rapid development experts

Ruby on Rails by proven experts.

The snake in the road

I’ve been training for a marathon (which will also be my first running race of any kind). In Texas over the summer, that means I run in the wee hours of the morning. A couple of days ago, I almost stepped on an object in the road. There’s construction in the area, so there are often little bits of trash on the road. At the last minute, I saw the object and stepped around it. Based on a little intuition, I went back to take a look. It was a copperhead, and a young one too. The young ones are dangerous because they don’t know how to control their venom yet, and tend to give you all they’ve got. This was one day when a little awareness and a split decision went in my favor.

As I’m applying Ruby on Rails to my first few applications, I’m always looking for snakes in the road. Where are the limitations in the framework, or in my experience, that are likely to sneak up and bite me? I’ve found a few. Inheritance mapping, when you’re not doing single-table inheritance, is problematic. The testing philosophy is different, and you can wind up fighting it if you’re not careful. For example, I thought I could simulate multi-table inheritance through the clever usage of database views, combined with some SQL magic. In development mode, I got exactly the behavior I was looking for. But in testing mode, the Rails testing environment didn’t treat the views the way I expected it to. Rather than fight the framework, I decided to forgo the beautiful mapping and work with polymorphic associations instead.

I’ve also found situations where a given client does not have the skills to pull Rails off, and is reluctant to get adequate training. I usually walk away from those types of deals, or redirect the client to a more appropriate technology.

All things considered, though, I can’t be too concerned about stepping on a copperhead while I run in the near darkness. That’s not the biggest danger. In Texas, the bigger dangers are dehydration, and an excessive heat that can beat you down over time. My dangers are overtraining, and making poor decisions with injuries. I need to be concerned with drinking enough water, taking care of my knees with good shoes, and asking for help when I need it, because there’s a lot that I don’t know.

So I think we’ve been thinking about the little snakes in the road: a programming language that might not make the big time; the performance of interpreted languages versus virtual machines; the availability of object-relational mappers for pet store applications; frameworks over business problems. The real risks are poor productivity that wears a company out over time, eroding faith and prompting desperate actions like offshoring; distractions from real business problems, leading to million dollar integration projects that do not deliver a single business object; a morass of code that takes us further and further from our customers; a process that can’t keep up with customer requirements.

Don’t worry about the potential copperhead in the road. Worry about the python that’s been around your neck for ten years, slowly choking the life out of you. It may be your process, your programming language, your vendor, or even your pet frameworks.