« The first catch | Main | Deja speech »

Failing gracefully

I’ve talked about degrading gracefully here, in regards to the appearance of web pages and offering cascading alternatives for browsers which don’t support certain features.

This morning, though, I’m concentrating on failing gracefully. I’m figuring out what to do with the dozen or so browsers each day which send requests for pages which no longer exist, or never existed. For a while, I harbored dreams of using mod_rewrite to somehow redirect all such requests to the proper new page, but I’m coming to see that it would require a pretty massive line-by-line mapping of old pages to new.

Instead, I’m trying to take the information I can find in the old URLs and query the new database for pages which might match. I’m not trying to be definitive; instead, I’m settling for helpful. Instead of, Oh, that old one’s not it, you want this one, I’m offering, We’re out of that, perhaps one of these would suit?

This sort of thinking is embedded in the structure of the internet. From the beginning, the network was designed to detect damage and route around it. A blank “no” is not the way of the internet; an alternate route is. I like that philosophy, and I enjoy applying and implementing it. And the nature of this particular bit of code is that it forces me to look very carefully at the question that was asked, determine how much information the server can easily extract from it, and see how far we can get with that data. It’s thinking a different way about the data structure that I’ve built, and it’s one of the more fascinating things I’ve done to this site in a few weeks.

Now Playing: 3 Strange Days from School Of Fish by School Of Fish

Post a comment