Wipe out code review roadblocks with Upsource
Do you practice code review in your team? Considering it? Tried it before but quit for some reason? One way or another, you know what code review is. The jury is still out on how much exactly code review increases code quality and whether it can help catch enough subtle issues that static code analysis and unit tests won’t detect. All too often it is perceived as an obsolete practice full of bureaucracy that only slows down the development lifecycle. Still, many people, including us at JetBrains, seem to agree that code review helps spread knowledge, enrich team collaboration and communication, and build up collective code ownership. Finding issues and potential problems comes as a pleasant bonus.
We’ve looked at some roadblocks that developers encounter while making code reviews work. We’ve also imagined what might stop us from doing code reviews at JetBrains. Putting two and two together, we figured out that this problem, like many others, can be solved by using an appropriate tool. So we created this kind of tool—for ourselves and for those who’re not happy with the current state of code reviews. We’ve wiped out the roadblocks, and by using Upsource so can you.
Roadblock #1: Code reviews bring a lot of bureaucracy.
The Upsource solution: Who said you need to tighten the screws?
Code reviews date to the times when some of us weren’t even born yet. Back then developers would gather in a conference room and discuss someone’s code projected on a screen. Later, they used email threads. Now the market is full of software tools that let you perform code reviews. But while technology has evolved, one thing seems to persist in many outfits and teams: bureaucracy, with its dull, hard-to-follow procedures, which often nip in the bud any kind of collaboration.
It doesn’t have to be like that. Code review workflow can be as easy and relaxed as you make it. Upsource, for example, doesn’t impose any strict workflow, leaving your team a large room of choices for your code review policy.
- You can leave a comment on a line of code that looks weird to you, or a symbol, or even any selection (saves time to explain what exactly you mean). The code author(s) are automatically notified of your comment. No strings attached. No cumbersome code review created.
- If you comment on a whole revision, the author will see your comment.
- If you want to get more formal, create a review, either from one or multiple revisions. Upsource will help you assign reviewers by taking into account the file history and the history of past reviews.
- If your team uses feature branches, you can even create a branch review that will track future revisions until the branch is merged.
In short, Upsource is flexible. If you don’t need or want bureaucracy, no one will force it on you. If you do, well, more power to your elbow!
Roadblock #2: Code reviews slow my work down, I have to wait for feedback.
The Upsource solution: Everything happens in real time!
As soon as there is any activity that concerns you—like a code review assigned to you, a comment on a change you’ve made, a mention of you, and so forth—you see it instantly in your News Feed, much like in a social network. You can also choose to receive nicely formatted email notifications, or even be alerted right in your IDE.
Then, get back to what you were doing while Upsource tracks which revisions have already been seen and approved. When any new revisions are added to the code review, a reviewer will only see the diff of those revisions, without having to inspect previous changes once again.
Roadblock #3: Complex changes are difficult to understand outside of their context, so reviewers typically provide only general feedback.
The Upsource solution: Here’s all the context you need, and more!
Since code doesn’t mean much outside of its context, Upsource helps you discover it. Similar to how you do it in your IDE, you can search for symbol usages, navigate to a declaration, or view inheritance hierarchy. Upsource comes with unique Java code insight that you’re not likely to see anywhere else. Except, of course, IntelliJ IDEA.
Roadblock #4: Code review means another tool, and switching makes me lose focus.
The Upsource solution: Plug-in and play!
Most of us would rather not leave our IDE unless absolutely necessary. To help you stay in your comfort zone, Upsource 2.0 introduces a new code review plugin for IntelliJ IDEA and other JetBrains IDEs. Go ahead and discuss code without leaving your IDE!
Check out this video introducing the Upsource plugin for IntelliJ IDEA-based IDEs:
Having the roadblocks removed we are now able to practice efficient, transparent and intuitive code reviews, and have real-time straightforward discussions with our teammates about one thing we have in common – solving problems by writing better code.
To download and install your own Upsource instance, go to www.jetbrains.com/upsource/download/.
Note that it comes at no cost for small teams with 10 users or less.
Review code with pleasure!