Traditionally we performed code review before commit, I had an argument with my colleague today, who preferred code review after commit.
First, here's some background,
- We have some experienced developers and we also have new hires with almost zero programming experience.
- We'd like to perform fast and short iterations to release our product.
- All team members are located at the same site.
The advantages of code review before commit I've learned:
- Mentor new hires
- Try to prevent errors, failures, bad designs early in the development cycle
- Learn from others
- Knowledge backup if someone quits
But I've also had some bad experiences:
- Low efficiency, some changes may be reviewed over days
- Hard to balance speed and quality, especially for newbies
- One team member felt distrust
As to post-commit review, I know little about this, but the thing I'm most worried about is the risk of losing control due to lack of review. Any opinions?
- We're using Perforce for VCS
- We code and commit in the same branches (trunk or bug fixing branches)
- To improve efficiency, we've tried to split code into small changes. We've also tried some live dialog review, but not everyone followed the rule. This is another problem though.