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

Non-Blocking Continuous Code Reviews - a Case S...

Non-Blocking Continuous Code Reviews - a Case Study

The problem with the current most common way of implementing code reviews using Pull Requests is that they have the nasty habit of blocking the flow of delivery.

The usual way to achieve fast Continuous Code Reviews without disrupting the flow of delivery is through Pair Programming or Team Programming. But not all teams or individuals are open to this for various good reasons.

In this session, I’ll explain how, in 2012, a novice team practising trunk-based development found an efficient uncommon way to implement continuous code reviews on mainline without ever blocking the flow of delivery.

Avatar for Thierry de Pauw

Thierry de Pauw

February 06, 2024

More Decks by Thierry de Pauw

Other Decks in Technology

Transcript

  1. 2021 Ghent lightening festival Kunsthal Gent Lange Steenstraat shy speaker

    Non-Blocking Continuous Code Reviews Trunk-Based Thierry (they/them) @[email protected] thinkinglabs.io
  2. But few teams have made a conscious decision about what

    they want to achieve with their code reviews. – Pia Fåk Sunnanbo, I Hate Pull Requests
  3. Our reasons … • Mentoring, learning • Knowledge sharing •

    Check on readability and maintainability • Maintain consistency in design (that was a mistake, should have been a design workshop)
  4. 4-eyes principle Killer argument to slow everything down and drive

    down quality. Pair Programming or Team Programming + Continuous Delivery are more effective
  5. “Sense” of security. I don’t trust my code. Dilution of

    responsibility. -> won’t be fixed by a process
  6. • Exercise power • By seniors missing mentoring skills •

    Vary in content based on the author • Blaming or harming • A miserable experience • Gatekeeping • A must
  7. If we commit changes directly to the remote mainline, we

    have unreviewed code alongside reviewed code.
  8. low quality code ≠ a bug !! => automated and

    exploratory tests catch bugs
  9. If it takes 10 min to make a change, the

    change is blocked until it is reviewed and it takes 2 hours to get a review … 92% wait time 😳 High cost of code review! => ask less often for a review 🤷
  10. To get something out sooner … need to reduce the

    transaction cost! Minimise the cost of code review.
  11. With Non-Blocking Code Reviews no new work is started before

    finishing. => less Work in Progress => because Little’s Law: less delays
  12. It might not work for regulated industries. => Pair Programming

    or Team Programming are the better solution
  13. Pair Programming or Team Programming are still a superior delivery

    option. However, it can be a cultural stretch.
  14. Non-Blocking Review strategies are significantly better than any of the

    alternatives. • No gating • Deliver faster without delays • Less WIP • No context switching • No urgency to fix quality issues • Features grow incrementally, commit by commit • Encourages refactoring
  15. 2024 Ghent lightening festival Portus Ganda picture by Camille de

    Pauw, daughter of Hello, I am Thierry de Pauw Acknowledgments: Stefan De Moerloose for having been that incredible team manager open to try out all of our crazy ideas. Dave Farley for nudging me to write this down and then turning it into that lovely video. Giovanni Asproni for poking me to turn this into a positive story. Lanette Creamer, Wouter Lagerwije, Diane Gombart, Falk Kühnel and Steve Berczuk for reviewing the slide deck. The Article: https://thinkinglabs.io/articles/2023/05/02/non-blocking-continuous-code-reviews-a-case-study.html @[email protected] thinkinglabs.io
  16. Resources Optimizing the Software development process for continuous integration and

    flow of work, Martin Mortensen The Article: Non-Blocking Continuous Code Reviews, a Case Study, Thierry de Pauw Code Complete, Steve McConnell Facts and Fallacies of Software Engineering, Robert Glass Accelerate, Nicole Forsgren, PhD et al. Joel on Software, Joel Spolsky What is the purpose of Code Reviews, Thierry de Pauw, a discussion on LinkedIn Gender bias in open source: Pull request acceptance of women versus men, C. Rainear at al., 2016 I’ve found something better than PRs, the video from Dave Farley on the topic From Async Code Reviews to Co-Creation Patterns, Dragan Stepanović I Hate Pull Requests, Pia Fåk Sunnanbo Problems with Pull Requests and How to Fix Them, Gregory Szorc On the Evilness of Feature Branching - But Compliance, Thierry de Pauw How to make sure tests are of quality, Thierry de Pauw, a discussion on LinkedIn