Friday, February 27, 2009

Threads are evil

Having a child is an exercise in chaos. If you're a software developer you will probably not even notice any change in your daily routine. It's basically all that's wrong with project management at your workplace. Late night refactorings, ever changing specs, volatile project scope, improbable deadlines and virtually no chance of success. Still you probably end up finishing every project no mater how mismanaged. Somehow things get done and the jumbled mess of incomprehensible code produces the desired output. On strings, prayer sand a roll of duck tape, you get through it and you live to fight another project.

That’s until you encounter concurrency computing.

If you’re a competent developer you know that threads are evil. But they pale in comparison with daily challenges of multi-offspring household. Having n > 1 children is a like developing a multithreaded application – with a few twists. In this case you’re the CPU processing the requests (this is where being married dual core pays off!), there’s no logging, exceptions are constant and unrelenting. Fixing a bug just means you’ve neglected to take care of something else. Being used to chaos you persevere – but invariably you burn out and fail.

It’s amazing how simple the problems you face at work seem to the veterans of n > 1 children families. Everything else is dead simple. Also you learn to appreciate your spouse. At the end of the day – she puts on her cape and turns into a superhero that saves the day. Barely being able to keep your eyes opened you gaze at the better half of your dynamic duo – she looks out of this world. You can finally close your eyes and take a nap. Her multitasking superpowers defeat the chaos. Your final thought before you daze into the never-land is: “She’d be an amazing programmer…”