Blog driven development and why you should avoid it
“Blog Driven Development” is my name for when you hear about some new idea or technique, get excited, and start using it in your codebase straight away. You repeatedly do this over several years, only rarely updating earlier code with the new ideas.
When I did this the codebase ended up with four different testing frameworks, several different patterns for “presenter” style logic, and multiple ways of doing the admin screens we used internally. You could date when I read a particular article by when that pattern appeared in the codebase.
This is an almost textbook example of adding technical debt for no real benefit. The drawbacks included:
- It was harder for me and others to maintain the codebase.
- The base knowledge required to make a change depended on where you were in the system.
- A bigger dependency footprint meant more things to keep up to date.
Looking back, often the authors of the posts I read were short-term consultants so they never had to deal with the long term consequences of what they were talking about. Before leaving that codebase I spent a good amount of time making everything more consistent for the next developers. I didn’t get to spend that time adding value but at least I made it easier for that to happen in the future.
Some things to think about I took away from that period include:
- When evaluating something new, think about how much effort it might take to update your existing code to the new concept? Is the payoff worth that amount of effort?
- How well does the new idea work in the rest of the system? Does it only fit in the area you’re working on right now?
- How many concepts will you now need to remember when you come back to this code? Will you have to special case this area when onboarding a new developer?
- If you solve the problem using the pattern you have in your codebase already are you adding to technical debt or increasing the ROI?
- If you introduce this new idea are you turning the rest of the codebase into new technical debt?
Getting excited about new things is good. It is always worth allowing new ideas to sit for a while and see if they still seem as good in a few weeks once the initial shine has passed. Asking the questions above can help you decide if the new idea is worth the effort.