How to start recording architecture decisions in a project¶
This guide covers adding architecture decision records (ADRs) to a project that doesn't have them yet. Our boilerplates don't create ADRs for you, because each team records its own decisions. The explanation of ADRs says why.
Prerequisites¶
- Agreement within the team that you want to keep ADRs.
- Write access to the project's repository.
Create the decisions directory¶
Create docs/decisions/ at the root of the repository. MADR
recommends this location, and using it everywhere means people know where to look in any of our
projects.
If the repository already keeps ADRs somewhere else, such as docs/adr/, leave them where they are.
Moving them breaks links from issues, merge requests and other documentation.
In a boilerplate, put the directory outside the template directory, so that copier never copies it into generated projects.
Check the project's tooling¶
ADRs are Markdown, so they go through the project's markdownlint checks like any other page. The MADR templates have placeholder lines longer than our 100-character limit, which disappear once you replace them with your own text.
If the project publishes its documentation with MkDocs, add the decisions directory to the navigation, or exclude it if you don't want ADRs on the site.
Record your first decision¶
Write your first ADR by following
Propose an architecture decision. Accepted ADRs are numbered
from 0001, because 0000 is kept for open proposals.
Many projects make their first ADR the decision to keep ADRs at all. That is optional, but it gives the team a worked example to copy and records who agreed to the practice.
Link to them from the README¶
Add a short section to the project's README.md so people know where to look:
## Architecture decisions
We record significant technical decisions in [`docs/decisions/`](docs/decisions/). See the
[Guidebook](https://guidebook.devops.uis.cam.ac.uk/howtos/development/propose-an-architecture-decision/)
for how to propose one.