codereview介绍[通俗易懂]

codereview介绍[通俗易懂]1.定义:Codereviewissystematicexamination(oftenknownaspeerreview)ofcomputersourcecode.Itis

大家好,又见面了,我是你们的朋友全栈君。如果您正在找激活码,请点击查看最新教程,关注关注公众号 “全栈程序员社区” 获取激活教程,可能之前旧版本教程已经失效.最新Idea2022.1教程亲测有效,一键激活。

Jetbrains全系列IDE使用 1年只要46元 售后保障 童叟无欺

1. 定义:

Code review is systematic examination (often known as peer review) of computer source code. It is intended to find and fix mistakes overlooked in the initial development phase, improving both the overall quality of software and the developers’ skills. Reviews are done in various forms such as pair programming, informal walkthroughs, and formal inspections

2. 介绍

Code reviews can often find and remove common vulnerabilities such as format string exploitsrace conditionsmemory leaks and buffer overflows, thereby improving software security. Online software repositories based on Subversion (with Redmine or Trac), MercurialGit or others allow groups of individuals to collaboratively review code. Additionally, specific tools for collaborative code review can facilitate the code review process.

Automated code reviewing software lessens the task of reviewing large chunks of code on the developer by systematically checking source code for known vulnerabilities. A 2012 study by VDC Research reports that 17.6% of the embedded software engineers surveyed currently use automated tools for peer code review and 23.7% expect to use them within 2 years.[2]

Capers Jones’ ongoing analysis of over 12,000 software development projects showed that the latent defect discovery rate of formal inspection is in the 60-65% range.[ambiguous] For informal inspection, the figure is less than 50%.[citation needed] The latent defect discovery rate for most forms of testing is about 30%.[3]

Typical code review rates are about 150 lines of code per hour. Inspecting and reviewing more than a few hundred lines of code per hour for critical software (such as safety critical embedded software) may be too fast to find errors.[4][5] Industry data indicates that code reviews can accomplish at most an 85% defect removal rate with an average rate of about 65%.[6]

The types of defects detected in code reviews have also been studied. Based on empirical evidence it seems that up to 75% of code review defects affect software evolvability rather than functionality making code reviews an excellent tool for software companies with long product or system life cycles

3.分类:

Code review practices fall into three main categories: pair programming, formal code review and lightweight code review.[1]

Formal code review, such as a Fagan inspection, involves a careful and detailed process with multiple participants and multiple phases. Formal code reviews are the traditional method of review, in which software developers attend a series of meetings and review code line by line, usually using printed copies of the material. Formal inspections are extremely thorough and have been proven effective at finding defects in the code under review.[citation needed]

Lightweight code review typically requires less overhead than formal code inspections, though it can be equally effective when done properly.[citation needed]Lightweight reviews are often conducted as part of the normal development process:

  • Over-the-shoulder – One developer looks over the author’s shoulder as the latter walks through the code.
  • Email pass-around – Source code management system emails code to reviewers automatically after checkin is made.
  • Pair Programming – Two authors develop code together at the same workstation, such is common in Extreme Programming.
  • Tool-assisted code review – Authors and reviewers use specialized tools designed for peer code review.

Some of these may also be labeled a “Walkthrough” (informal) or “Critique” (fast and informal).

Many teams that eschew traditional, formal code review use one of the above forms of lightweight review as part of their normal development process. A code review case study published in the book Best Kept Secrets of Peer Code Review found that lightweight reviews uncovered as many bugs as formal reviews, but were faster and more cost-effective.

4.常见的code-review tool

开源软件:

比较:

Software Maintainer Development status License VCS supported Platforms supported Workflow Cost
Differential (Phabricator) phabricator.org actively developed Apache v2 Subversion, Git, Mercurial PHP pre-commit, post-commit Free
Gerrit Shawn Pearce actively developed Apache v2 Git Java EE pre-commit Free
Review Board reviewboard.org actively developed MIT CVS, Subversion, Git, Mercurial, Bazaar, Perforce, ClearCase, Plastic SCM Python mainly pre-commit Free
Rietveld Guido van Rossum actively developed Apache v2 Git, Subversion Python pre-commit Free

reference:

http://en.wikipedia.org/wiki/Code_review

http://en.wikipedia.org/wiki/List_of_tools_for_code_review

版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请联系我们举报,一经查实,本站将立刻删除。

发布者:全栈程序员-站长,转载请注明出处:https://javaforall.net/167312.html原文链接:https://javaforall.net

(0)
全栈程序员-站长的头像全栈程序员-站长


相关推荐

  • 用xp系统的rundll32进行锁屏!!!!!劲爆!!!!!

    用xp系统的rundll32进行锁屏!!!!!劲爆!!!!!http://hi.baidu.com/joleincn/blog/item/d1dfb7d939c69fe177c638b0.html通常,正在忙一些事情,可是又有急事要走开,又不想让别人看自己的东西,动自己的东西,怎么办呢?在网上下一大堆锁屏工具又不美观,这时,可以用系统自带的来进行锁屏!!!方法:在桌面上新建一个快捷方式,在弹出对话框中输入

    2022年7月21日
    19
  • java实现贪吃蛇小游戏(源码+注释)

    java实现贪吃蛇小游戏(源码+注释)一.工程文件二.Main.javapackagecom.company;importjavax.swing.*;publicclassMain{publicstaticvoidmain(String[]args){//创建窗体对象JFrameframe=newJFrame();//创建窗体参数()frame.setBounds(10,10,900,720);//设置

    2022年5月25日
    36
  • gamma校正什么意思_串联滞后校正对系统性能的影响

    gamma校正什么意思_串联滞后校正对系统性能的影响【Gamma的由来】首先,要区分照度和亮度,照度是一个客观的量,亮度是一个主观的量,不同的人看相同照度的物体所感受到的亮度是不一样的。对于照度线性变化的物体,人眼感受到的亮度不是线性的。人眼对于低照度的物体更敏感,这意味着对于照度为2、3、4的三个物体,人眼能够区分,而对于照度为222、223、224的三个物体,人眼不能区分。其次,我们存储颜色的空间是有限的,常用的RGBA32格式,每个颜色通道只有8位,最多能表示256种照度,而现实世界中的照度远超256。基于人眼对照度的感知特点,我们不能线性的去

    2022年9月22日
    2
  • 用匿名函数定义函数_c语言最先执行的函数是

    用匿名函数定义函数_c语言最先执行的函数是深入理解 函数、匿名函数、自执行匿名函数

    2022年4月21日
    148
  • centos7安装方法_ad9安装及激活成功教程教程

    centos7安装方法_ad9安装及激活成功教程教程本文超详细的将CentOS7的安装过程做了详细的记录,从下载镜像文件到安装CentOS再到最后的配置,手把手教学,保证能够顺利的将CentOS安装好、配置好。

    2022年10月4日
    3
  • Linux 防火墙开放特定端口 (iptables)

    Linux 防火墙开放特定端口 (iptables)查看状态:iptables-L-n下面添加对特定端口开放的方法:使用iptables开放如下端口/sbin/iptables-IINPUT-ptcp–dport8000-jACCEPT保存/etc/rc.d/init.d/iptablessave重启服务serviceiptablesrestart查看需要打开的端口是否生效?/etc/init.d/iptablesstatus法2:或直接编辑/etc/sysconfig/iptables-AINPUT

    2022年10月19日
    1

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注

关注全栈程序员社区公众号