One-Way vs Two-Way Door Decisions in Software Architecture
Classify architecture decisions by reversibility: analyse one-way doors carefully, make two-way doors fast, and learn to turn one into the other.
Published November 27, 2026
Not every decision deserves the same amount of debate. Amazon popularised a simple heuristic: some decisions are one-way doors, consequential and nearly impossible to reverse, while most are two-way doors you can walk back through if they turn out wrong. Treating every decision as a one-way door makes teams slow; treating one-way doors casually makes them fragile. Knowing the difference is a core architecture skill.
The concept
A two-way door decision is cheap to reverse: choosing a logging library, an internal API shape behind a feature flag, a caching strategy, a CI tool. The right move is to decide quickly with reasonable judgement, observe, and change course if needed. Spending weeks on analysis costs more than occasionally being wrong.
A one-way door decision is expensive or impossible to undo: a public API contract that customers integrate with, a database whose data model everything depends on, a data residency commitment in a contract, deleting data, or splitting a team's codebase into services owned by different groups. These deserve deliberate analysis, prototypes, wider review and a written record.
Triage every decision
Typical examples
| Usually two-way doors | Usually one-way doors |
|---|---|
| Internal library choice (behind an interface) | Public API contracts and URLs |
| UI component framework for one page | Primary database and core data model |
| Cache TTLs, feature flags, config values | Deleting or irreversibly transforming data |
| CI/CD tooling | Contractual SLAs and data residency promises |
| Internal service-to-service API (versioned) | Pricing model and billing semantics |
| Monitoring vendor | Security/encryption scheme for stored data |
Making doors swing both ways
- Hide the choice behind an interface or adapter
- Release behind a feature flag or to a small cohort first
- Keep the old path running until the new one is proven (parallel run)
- Version APIs and data formats from day one
- Make migrations reversible (expand → migrate → contract)
Expand and contract: a reversible migration
Changing a database column in place is a one-way door. Splitting the change into expand (add the new column and write to both), migrate (backfill and switch reads), and contract (remove the old column once everything is verified) keeps a way back at every step until the final, small, well-tested contraction.
-- 1. Expand: add new column, app writes both
ALTER TABLE users ADD COLUMN full_name text;
-- 2. Migrate: backfill, then switch reads to full_name (feature flag)
UPDATE users SET full_name = first_name || ' ' || last_name WHERE full_name IS NULL;
-- 3. Contract (weeks later, after verification): stop writing old columns, then drop
ALTER TABLE users DROP COLUMN first_name, DROP COLUMN last_name;Practical examples
Feature flag for a risky architectural switch
Route a percentage of traffic to the new path and roll back instantly.
if (flags.isEnabled('orders-v2-storage', { userId })) {
return ordersV2Repository.save(order)
}
return legacyOrdersRepository.save(order)API versioning keeps public contracts reversible
New behaviour goes to a new version; old clients keep working.
GET /api/v1/orders/123 → old shape, maintained until sunset date
GET /api/v2/orders/123 → new shape
Sunset: Tue, 30 Jun 2027 00:00:00 GMT (response header on v1)Decision log entry with reversibility noted
Recording the door type sets expectations for future reviewers.
ADR-0014: Adopt OpenSearch for product search
Door type: two-way (search index is derived from PostgreSQL; can rebuild elsewhere)
Review: after 3 months of production trafficCommon mistakes
- Running week-long debates over easily reversible choices.
- Making one-way door decisions in a single meeting without prototypes or written reasoning.
- Accidentally turning two-way doors into one-way doors, for example by exposing internal APIs publicly.
- Skipping the contract step forever, leaving dual-write code in place indefinitely.
- Deleting data as part of a migration before the new path is verified.
Key takeaways
- Classify decisions by how expensive they are to reverse.
- Decide two-way doors quickly; give one-way doors careful analysis.
- Interfaces, feature flags, versioning and expand-contract migrations add reversibility.
- Record the door type in your ADRs.
FAQ
Where does the one-way/two-way door idea come from?
Jeff Bezos described Type 1 (one-way) and Type 2 (two-way) decisions in Amazon's 2015 shareholder letter, arguing that large organisations often wrongly apply Type 1 process to Type 2 decisions.
Are microservices a one-way door?
Largely, once teams, data and deployments are split. Merging services back is possible but expensive, which is why starting with a modular monolith keeps options open.
Is choosing a cloud provider a one-way door?
It becomes harder to reverse the more proprietary managed services you depend on. Containers, open-source databases and infrastructure as code keep it closer to a two-way door.