Open Source as a Roadside Picnic
August 28, 2008
One of the many changes that Jessamyn suggested for MyKidsLibrary is that the URLs should be comprised of meaningful text rather than just numbers. In addition to being more human-friendly, it is, apparently, an important search engine optimization technique.
Ruby on Rails likes to construct URLs that end with a numeric identifier that is used to look up a specific record in the database. It is an efficient, effective solution, and the software engineer side of me never considered why you'd have it be otherwise. I have come to think of URLs as being things that are as effectively meaningless and worthless to my brain as printouts of UNIX coredumps. I click on links, I bookmark pages, I never pay the slightest attention to URLs. I use tools -- browsers, bookmarking services -- to work with URLs just as I use tools to write software.
Once I decided to go about making the change, I set out to find who else had already done this work. The Rails ecosystem is vast and densely populated; I knew that there was but a very tiny chance that I'd actually have to start from scratch. Sure enough, a little work on Google revealed that there were many candidate solutions. I picked one that looked solid and set about integrating it into my project.
I'm not new to this; I have been a working, salary-earning software engineer for nearly two decades, so I should have been prepared for the documentation to suck. The documentation always sucks. The last time that I read really good, comprehensive documentation was when I was writing code for a VMS system, and I sat right next to the big orange wall. At least, I remember it being good; it's all so long ago that I might be remembering it in a somewhat nostalgic light.
I had to figure out a lot of things that weren't mentioned in the documentation, and while that's not the worst thing, it is still frustrating to see a useful, well-put-together package that stops just short of being perfect. And, really, they all do.
Open Source is invaluable, but in many respects, it reminds me of a Roadside Picnic.
And just to prove that I'm not a hypocritical dick, my next post will include extensive, failproof instructions for configuring and using the wonderful Rails plugin acts_as_urlnameable.