code review
A teammate reading a proposed change before it is merged, to understand it, catch mistakes and share knowledge.
In more detail
A good review checks that the change solves the problem and has tests, and keeps feedback specific and respectful. On hosting services such as GitHub it happens on a pull request, where reviewers comment on lines and approve or request changes.
Examples
Review is a weak control on its own under deadline pressure, which is why the course prefers safe defaults and automated gates.In Terraform: For Terraform the reviewer reads both the code change and the plan it produces, paying most attention to deletions and replacements. Review is also the main defence against an accidental destroy of production. Plans saved as artifacts let the reviewer see exactly what will be applied.In this course: Automation should check repeatable facts such as formatting, types and tests, leaving people to judge whether the requirement is met, the failure modes are acceptable and the design will be understandable. A good review comment names a risk, points to evidence and gives a concrete next action.Related terms
- pull request — A request on a hosting service such as GitHub to merge one branch into another, with a page for review, discussion and automated checks.
- GitOps — Operating a system by keeping its desired state in Git and letting a controller continuously make the live system match it.
- diff — A listing of the differences between two versions of something, such as two files, two commits or two screenshots.
- branch protection rule — A setting on a hosting service that stops changes reaching a branch, usually main, unless conditions such as an approved review and passing checks are met.
- cardinality — The number of distinct values a metric label can take, which multiplies how many separate series a metric creates.
- terraform plan — The command that compares configuration, state and reality and prints the actions needed to make them match, without changing anything.
- saved plan — A plan written to a file with -out, which terraform apply can later carry out exactly as reviewed.
- quality gate — A check, or set of checks, that a change must pass before it can move on, such as being merged or promoted to the next pipeline stage.
- linter — A tool that reads code or configuration without running it and flags likely mistakes and style problems.
Taught in
- What Is a Pipeline? — Continuous Integration & Continuous Delivery Pipelines
- What is GitOps? — Continuous Integration & Continuous Delivery Pipelines
- Repository Layout for Environments — Continuous Integration & Continuous Delivery Pipelines
- Directory.Build.props, global.json and Central Packages — Modern .NET Core, C# & Enterprise Microservices
- Code Quality: .editorconfig and Roslyn Analyzers — Modern .NET Core, C# & Enterprise Microservices
- Entity Framework Core: Code First and Migrations — Modern .NET Core, C# & Enterprise Microservices
- Source-Generated Mapping with Mapperly — Modern .NET Core, C# & Enterprise Microservices
- The Pull Request, And Branch Naming — Advanced Git Internals & Distributed Workflows
- Reviewing Code Well — Advanced Git Internals & Distributed Workflows
- Log Levels Done Properly — Full-Stack Observability: Metrics, Tracing & Logging
- Cardinality And How It Bankrupts You — Full-Stack Observability: Metrics, Tracing & Logging
- Secure Defaults — Application Security & Threat Modeling for Engineers
- Why Secrets Leak — Application Security & Threat Modeling for Engineers
- Dependency Risk And Typosquatting — Application Security & Threat Modeling for Engineers
- Tearing It Down With Destroy — Infrastructure as Code with Terraform
- The Terraform Registry And Public Modules — Infrastructure as Code with Terraform
- Running Terraform In CI — Infrastructure as Code with Terraform
- Code Review As A Quality Gate — Automated Testing, TDD & Quality Engineering
- What To Look For In A Review — Automated Testing, TDD & Quality Engineering
- What To Automate Away — Automated Testing, TDD & Quality Engineering
- Writing Actionable Review Comments — Automated Testing, TDD & Quality Engineering
- The Plan That Wanted To Destroy Production — HashiCorp Terraform Associate (004) Exam Prep
- Infrastructure As Code, And One Workflow For Every Platform — HashiCorp Terraform Associate (004) Exam Prep
- Reading A Plan, Saving It, Applying It — HashiCorp Terraform Associate (004) Exam Prep
- Module Versions: Pin, Upgrade, Re-Initialise — HashiCorp Terraform Associate (004) Exam Prep
- Importing What Terraform Did Not Build — HashiCorp Terraform Associate (004) Exam Prep
- Moved And Removed Blocks: Refactoring Without Rebuilding — HashiCorp Terraform Associate (004) Exam Prep
- VCS, CLI And API Workflows: Speculative Plans And Run Triggers — HashiCorp Terraform Associate (004) Exam Prep
- The Full Mock: Sixty Minutes, Eight Areas, One Plan For The Last Week — HashiCorp Terraform Associate (004) Exam Prep
References
- GitHub Docs: Pull requests
- GitHub Docs: about pull request reviews
- Google engineering practices: code review
- Google engineering practices: how to do a code review