Covers what an ADR is, the Nygard format (context, decision, status, consequences), which decisions warrant one, where to store them, superseding instead of editing, and keeping them discoverable and current.
An architecture decision record (ADR) is a short document capturing one significant decision: the context, the decision, its status and its consequences, including the options you rejected.
The trade-off: an ADR costs an hour to write but saves weeks of re-arguing or reverse-engineering a decision. Writing them for trivial choices kills the habit.
"An ADR is a short, dated record of one architecturally significant decision. I use Michael Nygard's format: a title, a status (proposed, accepted, deprecated or superseded), the context that forced the decision, the decision itself in active voice, and the consequences, good and bad. I also add the options we considered and why we rejected them, because 'why didn't we just use X?' is the question that comes up two years later when everyone who was in the room has left.
The test I use for which decisions need one: is it hard or expensive to reverse, does it cut across modules or teams, or is it a choice someone will reasonably challenge later? Choosing Azure Service Bus over Event Grid for order events, deciding to use a single database with row-level tenancy, or adopting the outbox pattern all qualify. Choosing a logging library's sink or a variable name doesn't. I keep ADRs as Markdown in the repo under
docs/adr, numbered, and I raise them as a pull request so the decision gets the same review as code, and the PR thread becomes part of the record.To keep them useful, I treat accepted ADRs as immutable. If we change our mind, we write ADR 0023 that supersedes 0007 and mark 0007 as superseded with a link, so the history stays honest. I keep each one to a page or two, link them from the README and from the code that implements them, and revisit them when an assumption in the context changes, like traffic growing ten times. The mistake I see is writing ADRs after the fact to justify a decision, or writing so many trivial ones that nobody reads any of them."
| Section | What goes in it |
|---|---|
| Title | 0012 – Use Azure Service Bus for order events |
| Status | Proposed, Accepted, Deprecated, Superseded by 0023 |
| Context | Forces at play: requirements, constraints, scale, team skills |
| Decision | "We will…" in active voice |
| Consequences | What becomes easier and harder; follow-up work; risks |
| Options considered (common addition) | Each option with pros, cons and why it lost |
| Signal | Example | ADR? |
|---|---|---|
| Hard to reverse | Database engine, tenancy model | Yes |
| Cross-cutting | Auth approach, API versioning scheme | Yes |
| Likely to be challenged | Not using microservices | Yes |
| Local and cheap to change | Private method structure | No |
| Covered by a team convention | Naming, formatting | No (that's a style guide) |
| ADR | Design document | |
|---|---|---|
| Scope | One decision | One feature or system change |
| Length | 1–2 pages | Several pages |
| Lifetime | Permanent, immutable | Working document, then archived |
| Written | When the decision is made | Before building, to get feedback |
On a payments platform, new joiners kept proposing to replace the outbox table with direct publishing to Service Bus. After we wrote ADR 0009 explaining the dual-write problem, the incident it caused and the options rejected, the same debate stopped coming up in design reviews, and onboarding questions about messaging dropped noticeably. When we later moved to a managed CDC approach, ADR 0021 superseded 0009 and both stayed in the log.
Checks whether the candidate documents decisions so they outlive the people who made them, and knows when documentation is worth the cost.
Green flags
Red flags
Code shows what was built, not why. Decisions live in meetings, chat threads and people's heads, and they leave with those people. Without a record, teams either blindly follow old decisions they don't understand or reverse them without knowing the original constraint, sometimes recreating the problem the decision solved.
Michael Nygard proposed ADRs in 2011 as lightweight, version-controlled records. Variants include MADR (Markdown ADR, with explicit options and decision drivers) and Y-statements ("In the context of X, facing Y, we decided Z, to achieve A, accepting B").
docs/adr/
0001-record-architecture-decisions.md
0007-use-outbox-for-integration-events.md (Superseded by 0021)
0012-use-azure-service-bus.md
0021-use-cdc-for-integration-events.md
README.md <- index: number, title, status
Proposed --(PR approved)--> Accepted --(new ADR)--> Superseded
\--(no longer relevant)--> Deprecated
Immutability keeps the log honest: you can see what was believed at the time and why it changed.
The context is the most valuable part. Capture the forces: functional needs, quality attributes (latency, availability, data residency in Azure Australia East), constraints (budget, team skills, licensing), and assumptions ("we expect under 50 messages per second"). When an assumption breaks, it signals the ADR needs revisiting.
An honest ADR lists downsides: "We accept eventual consistency between orders and invoicing", "Developers need local Service Bus emulation". This protects against the decision looking naive later.
// See ADR 0012 at the composition root.adr-tools or dotnet-adr and generate a superseding ADR.An ADR in the MADR-style format, stored in the repository and reviewed in a PR.
# 0012. Use Azure Service Bus for order integration events
- Status: Accepted (2026-03-14)
- Deciders: [team names]
- Supersedes: none
## Context
Order, Invoicing and Fulfilment need order events. We need ordered delivery per order,
dead-lettering, and at-least-once delivery. Expected peak: ~200 msg/s. Hosted in
Azure Australia East; data must stay in Australia.
## Options considered
1. Azure Service Bus (topics + sessions): ordering per session, DLQ, managed.
2. Azure Event Grid: cheap push model, but no FIFO ordering guarantees.
3. Self-hosted RabbitMQ on AKS: flexible, but we operate it ourselves.
## Decision
We will use Azure Service Bus Standard topics, with the order id as the session id.
## Consequences
+ Ordered per order, built-in DLQ and retries.
- Consumers must be idempotent (at-least-once delivery).
- Local development needs the Service Bus emulator.
- Revisit if throughput passes ~1,000 msg/s (Premium tier cost).
An architecture test that enforces a decision and points back to its ADR:
namespace Orders.ArchitectureTests;
using NetArchTest.Rules;
public sealed class LayeringTests
{
// ADR 0004: the domain layer has no dependency on infrastructure or EF Core.
[Fact]
public void Domain_does_not_depend_on_infrastructure()
{
var result = Types.InAssembly(typeof(Orders.Domain.Order).Assembly)
.ShouldNot()
.HaveDependencyOnAny("Orders.Infrastructure", "Microsoft.EntityFrameworkCore")
.GetResult();
Assert.True(result.IsSuccessful, string.Join(", ", result.FailingTypeNames ?? []));
}
}
ADRs are a tool for organisational memory and for making decisions explicit enough to argue about. The senior move is to use the Proposed status to get disagreement out early, and to record the assumptions that would make the decision wrong, so the team knows when to revisit it rather than defending it forever.
| Option | When it fits | Cost | When not to |
|---|---|---|---|
| ADR in repo | Code-level architecture decisions | Low | Org-wide policy across many repos |
| Central ADR repo | Platform decisions shared by many teams | Discoverability effort | Single-team service |
| Design document | Large feature needing exploration | Several days | A single clear choice |
| Team convention doc | Style and naming | Low | Real trade-off decisions |
A useful health check: can a new joiner find out why the system uses its message broker in under five minutes?
I treat a large refactoring as a series of small, behaviour-preserving steps merged to main continuously, not a big-bang branch. First I pin current behaviour with characterisation tests. Then I pick a technique: strangler fig to route traffic piece by piece to a new implementation, branch by abstraction to put an interface in front of the old code and swap implementations behind it, or parallel change (expand, migrate, contract) for APIs and database schemas. Feature flags and shadow comparisons let old and new paths run side by side. I prioritise hotspots (code that changes often and hurts), keep refactoring commits separate from feature commits, and define an end state so it does not drag on forever.
Technical debt is the future cost of a shortcut, and the interest is the extra effort or risk it adds every time we work near it. I make it visible in a debt register with each item's impact, how often we pay its interest (change frequency, incidents, delays) and a rough cost to fix. I prioritise by interest, not by how ugly the code is: debt in a hotspot that slows every feature beats a messy module nobody touches. I get time by explaining it in business terms (lead time, incident risk, cost), by reserving a steady share of capacity, and by pairing debt fixes with features that touch the same area.
A design document is worth writing when a change is big, cross-team, hard to reverse or has genuinely different options: a new service, a data migration, a change to an API contract other teams use. A ticket and PR are enough for everything else.
A good one has: context, goals and non-goals, the proposal, alternatives considered, risks (security, privacy, operability), rollout and testing, and open questions, in two to six pages with a diagram.
Review it time-boxed: name the reviewers, set a deadline of a few days, resolve comments, and hold a short decision meeting only for what's still open. Key decisions then become ADRs.
The trade-off: a design doc costs a few days up front, but catching a wrong approach on paper is far cheaper than catching it in code review or production.
How to tell it (STAR)
**S:** At [company] our order platform used an outbox for events, but the people who chose it had left, and every few months someone proposed removing it. **T:** I wanted to stop re-arguing a decision nobody could explain and make sure it was still right. **A:** I dug the original reasoning out of an old incident report, checked whether the constraint still applied, and wrote it up as an ADR with the rejected options and downsides. I raised it as a PR so the team could challenge it, linked it from the code, and added an architecture test so the rule was enforced. **R:** The debate stopped coming up in design reviews, a risky PR was blocked automatically [number] times, and when we later moved to CDC we wrote a superseding ADR in [time] instead of starting from scratch.
Last updated 23 Nov 2026.