10 Things Ebook
10 Things Ebook
Content
Intoduction
10
11
12
14
15
16
18
Anyone who leads a development team wants business processes that help their team members (as well
as managers) to evaluate the work in-progress, improve its quality, and learn from one another so everybody does better next time. Doing a code review
whether thats as simple as an over-the-shoulder
glance at a software module or a formalize process
is a great way to accomplish that.
But code review works well only when it is implemented in a way that encourages the team to embrace the
process. Thats where you, the manager or team lead,
come in. Part of your role is to set standards, create the
team culture, and establish a workflow that encourages
team members to do their best.
studying to do, just to figure out what it was all about! she
concluded.
Theres all sorts of team value in having everybody understand the codebase, but the shared knowledge also protects
the company. If only one developer knows one part of the
code, the organization is at risk, especially if the developer
might be in a car accident or hit by a bus. Or he might leave
the company to take another job. You can lose the Wise One
for any number of reasons, but they all can result in panic
when the developers code needs attention.
This isnt a matter of whether any given developers
code (the senior developer with tenure or otherwise) is
well-written. Does it have enough comments to explain
how the software works where enough is a judgment
call by the reader, not the person who wrote the documentation? If someone needs to go back to that software
in six years,do the comments make sense? Do they reflect how the code currently works, not the way it operated when it was written six years ago (and much-maintained since then)?
Code review gives developers a reason and opportunity to
explain what they did why they did it. This alone can have
And that, of course, leads to documenting the explanations when theyre unusual. During the code review, another developers comment that the solution
is elegant but confusing may encourage clarity of
documentation and that can save time later on. Annotating code lets the next programmer who touches the code better understand how things connect.
Especially since that next programmer might be you,
in three years from now.
10
We sometimes hear hesitation from application development managers and reluctant programmers
expressing the sentiment that the reviewers do not
understand the problems the programmer had to deal
with, with the result that much of the reviewers advice
is not very useful. If you encounter that attitude, then
its your job as manager to ensure those team
members do understand the problems. After all, one of
those reviewers might be the developer modifying the
code the next time.
11
trol systems, such as Git, prevent code from being committed until its been reviewed. Younger developers who
got their early experience writing open-source software
expect their code to be reviewed sooner rather than later.
12
13
14
We encourage you to consider using a tool-based peer review. Using a tool during code reviews allows developers to
log in from their desk, add a comment where they want
to, and sign off. Developers can get back to work, without
having to wait their turn.
15
16
Ask, dont judge. Why did you make this choice? not
This is the wrong way. The developers choice might
turn out to be better than your own, after all.
Speak in I terms, not you. Back up each assertion.
Instead of saying, You should never use recursion
here, say, I would do it this way instead, for these
reasons.
17
THINGSDEVELOPERS
DEVELOPERSWISHT
WISHTTHEIR
THEIRBOSSES
BOSSESUNDERSTOOD
UNDERSTOODABOUT
ABOUTCODE
CODEREVIEW
REVIEW18
1010THINGS
18
19
25K+
3M+
users
194
countries
organizations
API
TESTING
RE AD I NE S S
PERFORMANCE
CODE
MONITOR I N G
COL L ABORAT I ON
Functional testing,
performance testing and test
management
SEE TESTING
PRODUCTS
SEE MONITORING
PRODUCTS
SEE COLLABORATION
PRODUCTS
20
21