Roedy Green published a great article on something most of us in health IT deal with regularly: code that’s difficult to manage and maintain. He says you can ensure a job for life if you learn How To Write Unmaintainable Code.
From his introduction:
In the interests of creating employment opportunities in the Java programming field, I am passing on these tips from the masters on how to write code that is so difficult to maintain, that the people who come after you will take years to make even the simplest changes. Further, if you follow all these rules religiously, you will even guarantee yourself a lifetime of employment, since no one but you has a hope in hell of maintaining the code. Then again, if you followed all these rules religiously, even you wouldn’t be able to maintain the code!
Although it’s amusing, it’s dead serious at the same time. If you manage a group of engineers like I do, you owe it to yourself to make sure your engineers aren’t following any of the techniques that help create unmaintainable code.
If you find that your engineers (or gasp even you) are creating code that you feel might not be maintainable a document like this is a good training document: often times anti-patterns (or things not to do) are a better way of teaching people the right thing to do instead of just a bunch of general guidelines. If you’re interested in improving your ability to maintain already old or unmaintable code, check out these three decent books on the subject: