Engineering Ardor
“Science is the study of what is. Engineering builds what will be.” — Theodore von Karman

Archive for the ‘Crafting Software’ Category

The Wrong Tool for Every Job

Saturday, May 5th, 2007

I spent several of my last few days on my last job tidying up design documentation, javadoc, and header comments before leaving. Some parts of the header comment template were useless. How many hours was it worth to have me go through and label each file with its file name, author, and creation date? I doubt that in the year 3007, the historians of that time will be browsing millenium-old source code header comments to gain insight into our life and times. And if I’m wrong, they’ll probably do what we do now and check the repository change history. As it happens, a good CM system will keep track of who checked something in and when. Most astonishing of all, it’s quite easy to figure out the file name by… I dunno… looking at the name of the file on the file system? Believe me, I’m all for sensibly applied engineering rigor, but sometimes the wrong tool for the job just ought to be put back in the tool box.

Why My Broken Air Conditioner Poses Challenges for Reputation Systems

Sunday, March 25th, 2007

Over this past summer, our air conditioner failed. It wasn’t a quiet failure of the compressor. The outflow line for the condensation water blocked up and sent water down over and through the oil furnace below. In looking at the state of the HVAC system, particularly the oil furnace, it became apparent that they had been poorly maintained for a lengthy period of time, despite our service contract with our oil company. Getting recommendations from neighbors and friends is one way to help avoid this kind of abuse of trust. Many sites on Teh Intarwebs use reputation systems as well, but most are oriented around transactions with short durations. Many industries, including health care, HVAC maintenance, accounting, and investment work over considerably longer periods.
(more…)

Another Toe Tagged Project

Wednesday, November 1st, 2006

I was recently asked to go take a look at a web site project. Ordinarily, my answer to requests for a critique like this is, “Are you willing to pay my ‘I don’t want to do this,’ rate?” This person, however, I owed. Big. I almost asked, “Would you be willing to take an internal organ instead? I have a spare kidney!” I don’t think she would’ve taken it. She wanted the web site reviewed. And so I began my foray into a text book case of all that can go wrong in web development.
(more…)

Test-wide Setup and Tear Down of JUnit Tests

Thursday, August 17th, 2006

JUnit 4.0 introduces the @BeforeClass annotation, providing a way to run a class-wide setup method before any of the tests in that class are run. The analogous @AfterClass annotation allows for tear down of those fixtures. I work on a project that hasn’t yet upgraded to JUnit 4.0, and although less widely publicized, it is possible to accomplish the same thing with 3.8.x.

Think before doing this. Tests should be independent of one another. If your tests share fixtures, side effects from one test could affect the results of others. Sometimes, however, a test fixture is just too expensive to set up and tear down with every test. In my case, I needed to set up a database and import a substantial quantity of data. Doing this for every test would’ve made the suite prohibitively slow.
(more…)

A Plea for Configuration Management Sanity

Saturday, August 12th, 2006

I’ve taken configuration management and revision control for granted. I first lost work because I wasn’t using a repository system early in life, and I resolved that such a thing would not happen again. During my senior year in college, I was working on a project with a randomly assigned classmate. When we started, I explained I’d set up a CVS repository for the code and gave him the directory for CVSROOT. Next time we met, he told me he didn’t have any trouble finding the code, but asked why the file names had commas and a couple random letters at the end of them. In retrospect, it was wrong of me to laugh, but I honestly thought he was making a joke with a deadpan delivery. When I walk onto a project, I can make an educated guess about how it’s going to go based on how much work it takes to get up and running with the SCM and build system.
(more…)