Upgrade to Pro — share decks privately, control downloads, hide ads and more …

The Surprising Similarities Between Renovating ...

Avatar for Richard Richard
September 30, 2025

The Surprising Similarities Between Renovating your House and your Code Base (v1.5) 🇬🇧 @CTO Craft Con Berlin 2025

Code and buildings have nothing in common. One is a malleable construct of our minds, while the other is an observable object, constructed of brick and mortar, amongst other things. Given that code and buildings have no similarities it is clear that we cannot apply metaphors from constructing a building to "constructing" a code base. Or so I thought.

Last year I bought a house and started renovating it, while at the same time my team was renovating a legacy code base. It turns out that while construction of code and buildings is very different, renovating them has some surprising similarities.

In this experience report I'll show lots of pictures from our house renovation - full of torn down walls, replaced floors and the like - and draw analogies to our legacy code renovation. I'll share helpful tips for code renovation that can be understood by anyone due to the building analogies and hopefully entertain you along the way. By the end I hope to have convinced you that renovating a legacy code base is a much nicer task than renovating a house, where each torn down wall can lead to brick and mortar raining down on your malleable head.

Avatar for Richard

Richard

September 30, 2025
Tweet

More Decks by Richard

Other Decks in Programming

Transcript

  1. > A t a l e b y Professional Software

    Renovator Richard Head of Software Archeology Jan Principle Agile Coach
  2. > A t a l e b y Baby-House-Renovator Richard

    Foot in his mouth Jan Principle Dreamer
  3. What exactly did I inherit? The first step in any

    renovation is to take stock of the current situation. This also involves understanding the past. SOME THINGS ARE OBVIOUS, OTHERS LESS SO
  4. W h a t e x a c t l

    y d i d I i n h e r i t ? A Web App… SOME THINGS ARE OBVIOUS, OTHERS LESS SO The first step in any renovation is to take stock.
  5. W h a t e x a c t l

    y d i d I i n h e r i t ? Very low test coverage? Lines of Code Coverage (0 < 40 < 80) Cycl. Complexity
  6. W h a t e x a c t l

    y d i d I i n h e r i t ? Only changes in the frontend? Lines of Code Changes (low < med < high) Cycl. Complexity
  7. W h a t e x a c t l

    y d i d I i n h e r i t ? With a lot of knowledge silos? Lines of Code #Authors (1 < 2 < 3) Cycl. Complexity
  8. What exactly did I inherit? Legacy Code is code that’s

    too scary to update and too profitable to delete. Dylan Beattie @dylanbeattie
  9. P l a n n i n g Colorize based

    on predictability Maps 2/n ✗ Enforced component bounds (f.ex. via Arch-Unit tests) ✓ Characterization tests coverage 100% ✗ Component unit testable ✗ … ✓ … ✗ … ✗ Criteria n Quality Views Based-on https://blog.colinbreck.com/using-quality-views-to-communicate-software-quality-and-evolution/ Increasing predictability
  10. P l a n n i n g Prefer to

    work Smarter, with a sharper saw1 1 Image by Henrik Kniberg
  11. P l a n n i n g Sharpen the

    Saw while you use it 0% 10% 20% 30% 40% 50% 60% 70% 80% 90% 100% Legacy Intermediate Normal Team Work Innovation Sharpening the Saw Unplanned Work + Rework 1 Loosely based on Accelerate – State of DevOps 2018
  12. > F i r s t R e n o

    v a t i o n S t e p s Details are important Small Details can have a LARGEimpact on the renovation measures. Some things you only find by getting started.
  13. > F i r s t R e n o

    v a t i o n S t e p s Details are important Small Details can have a LARGEimpact on the renovation measures. Some things you only find by getting started.
  14. > F i r s t R e n o

    v a t i o n S t e p s Details stay important Small Details can have a VERY LARGE impact on the renovation measures. Some things you only find by getting started.
  15. > H A N D L I N G I

    N V E N T O R Y You inherit much more than you think
  16. > H A N D L I N G I

    N V E N T O R Y You inherit much more than you think
  17. > P E R S P E K T I

    V E Bugs are often trivial to fix, but finding them requires perspective WHAT DOES THE CUSTOMER VALUE?
  18. > I t e r a t i v e

    a d a p t i o n First attempts rarely turn out well
  19. > I t e r a t i v e

    a d a p t i o n First attempts rarely turn out well
  20. > I t e r a t i v e

    a d a p t i o n In software, you can iteratively move forward and backward
  21. > L e a r n c o l l

    e c t i v e l y Experts are experts because they can deal with the “unhappy path.”
  22. > E x p e r t K n o

    w l e d g e Experts are experts because they have the important tools.
  23. > E x p e r t K n o

    w l e d g e Good tools don't have to be expensive
  24. Make the desired behavior … Obvious • Define Principles together

    • Shared purpose Attractive • Reduce (time) pressure • (Refactoring) score Easy • Tech-coach • Reduce friction Satisfying • Pair up • Never break the chain (twice)
  25. Lines of Code Number of lines of code reduced by

    4000 (green: less code to maintain) New features added nonetheless (blue) Release in hours instead of days 0 2000 4000 6000 8000 10000 12000 14000 16000 18000 20000 Unsecure Libraries Sonar Issues ES Lint Issues Unsecure Libraries Sonar Issues ES Lint Issues 2021 2022 Start 1 year later We have significantly reduced the number of quality and dependency issues.
  26. > M E T H O D O L O

    G Y Sustainable renovation relies on four levels Easy Hard Automation Architecture Process Mindset