Maybe we have it easy

When we need to refactor something, it’s usually fairly straightforward. We determine what the code should look like, we write some tests to make sure our changes maintain the same functionality, and then we change the code.

It’s not as easy in the real world. I just ran across this piece on the history of American railroads. As trade between the North and South intensified in the late 19th century, it became apparent that the rail systems would have to be integrated. The different systems used different gauges (the distance between the rails) for a number of reasons, and it was becoming cost-prohibitive to unload and reload trains on different track widths.

In late May of 1886, all of the track in the South had its gauge changed. 11,500 miles of track. In 36 hours. As well, all of the trains in the South were refitted to be able to run on the new track width at the same time. I promise not to complain about a tight deadline ever again. Well, not really, but it was an impressive feat.

(Maybe this doesn’t have much to do with refactoring. But I thought it was a neat story. See also Sweden’s switch to right-hand driving and the Great Renaming of Usenet. I got the original article via Metafilter.)

It's only fair to share...
Share on FacebookGoogle+Tweet about this on TwitterShare on LinkedIn

Leave a Reply