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)
全栈程序员-站长的头像全栈程序员-站长


相关推荐

  • open 函数[通俗易懂]

    open 函数[通俗易懂]open函数用来打开一个文件open返回值为一个文件句柄,从操作系统托付给你的python程序,一旦处理完文件,需要归还句柄,只有这样你的程序不会超过一次能打开的文件句柄的数量上限withopen(‘photo.jpg’,’r+’)asf: jpgdata=f.read()open的第⼀个参数是⽂件名。第⼆个(mode打开模式)决定了这个⽂件如何被打开。如果你想读…

    2022年5月25日
    42
  • java代码 软件_适合新手的java代码编写软件有哪些?

    java代码 软件_适合新手的java代码编写软件有哪些?适合新手的java代码编写软件有哪些?发布时间:2020-05-1816:39:11来源:亿速云阅读:196作者:Leah适合新手的java代码编写软件有哪些?相信很多人对java代码编写软件的了解处于一知半解状态,小编给大家总结了以下内容。如下资料是关于java代码编写软件的内容。1、eclipseEclipse是一个开放源代码的、基于Java的可扩展开发平台。就其本身而言,它只是一个框架和…

    2022年9月23日
    2
  • MySQL基础–数据库管理+数据表管理

    MySQL基础–数据库管理+数据表管理数据库的管理+数据表管理+Python操作MySQL数据库

    2022年8月11日
    7
  • rebar3使用介绍(六)用户自定义文件配置

    rebar3使用介绍(六)用户自定义文件配置rebar3 使用介绍 五 用户自定义文件配置例子选项合并算法依赖和配置文件依赖永远按照 prod 模式对应的 profile 进行编译 不会有其他 当然不包括 default 任何东西会被额外的套用上来 即使它们是为 prod 依赖项配置的 仍然会将其提取到其声明的配置文件的配置文件目录中 例如 顶层的依赖关系 deps 将放在 build default lib 下 test 将放在 build test li

    2025年7月13日
    5
  • 修改群晖mac 及 sn「建议收藏」

    修改群晖mac 及 sn「建议收藏」开启ROOT权限参见之前文章:群晖开启root权限及修复Moments的AI人像服务挂载启动分区root账号下,执行以下命令:root@data_backup:~#mkdir-p/tmp/boot##在/tmp目录下创建一个临时目录root@data_backup:~#ll/dev/sda*##看下引导盘在哪个分区brw——-1rootroot8,0May3022:29/dev/sdabrw——-1rootroot.

    2022年6月5日
    721
  • 呕心沥血整理的的嵌入式学习路线[通俗易懂]

    呕心沥血整理的的嵌入式学习路线[通俗易懂]曾经是某见的教学总监,我带出来的学生也有大几千了,基本都从事linux相关工作。网上看了很多的嵌入式学习路线,有的还凑活,有的纯粹是打广告卖板子,有的东拼西凑,简直是嵌入式劝退指南。大致给你梳理一下我从事的一个嵌入式的课程培训体系吧。基础1.linux基本操作:个人建议只要会一些基本的操作就行了,不需要太深入的学习每一个命令,用到的时候会去搜索就行了。需要掌握的知识如下:环境的搭建;Linux目录结构;文件类型;基本目录操作,文件操作,vim,ifconfig,ping,cd,cp,m

    2022年6月7日
    28

发表回复

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

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