Cheat Sheets / Architecture & System Design

Architectural Thinking cheat sheet

53 commands from every lesson of Architectural Thinking — Forces, Scenarios & Trade-offs, on one page.

01 · What architects actually decide

Is it architectural?

Reversal costHow many teams, services, migrations or contracts must change to undo it
ReachHow many quality attributes the decision affects
Time lock-inDoes it get more expensive every month you run on it?
Architecturally significant requirementA requirement that forces an expensive-to-reverse decision

Requirement kinds

FunctionalWhat the system does
Quality attributeHow well it does it, with a measure
ConstraintA decision already made for you: respect it, don't optimise it

Forces

Conway's lawSystem structure mirrors the organisation's communication structure
Inverse Conway manoeuvreShape teams to match the architecture you want
Accidental architectureThe sum of local decisions nobody made deliberately

02 · From brief to quality-attribute scenarios

Six-part scenario

SourceWho or what causes the event
StimulusWhat happens
ArtifactWhich part of the system is hit
EnvironmentSystem state: normal, peak, degraded, during deploy
ResponseWhat the system should do
Response measureThe number that proves it: percentiles, seconds, counts

ATAM vocabulary

Utility treeAttributes → refinements → scenarios, rated (importance, difficulty)
Sensitivity pointA property that strongly affects one attribute
Trade-off pointA property that moves two or more attributes in opposite directions
RiskA decision that may cause an undesirable outcome against a scenario

03 · Estimation and capacity math

Load

users x active share x actions / 86,400Average requests per second
average x peak factorPeak rps: state the factor as an assumption
bytes x events/day x replicas x retentionStored data

Concurrency and queueing

L = λ x W (Little's law)Items in flight = arrival rate x time in system
max rate = pool size / hold timeThroughput ceiling of a connection pool
W = S / (1 − ρ) (M/M/1)Response time explodes as utilisation ρ approaches 1
1 − (1 − p)^nChance a fan-out of n calls hits at least one slow call

Headroom

3 zones, survive 1Each zone carries peak/2, total 1.5x peak
2 zones, survive 1Each zone carries full peak, total 2x
Target utilisation60-75% for latency-sensitive services

04 · SLOs as design inputs

Definitions

SLIgood events / valid events, measured near the user
SLOTarget for an SLI over a window (e.g. 99.9% in 30 days)
SLAContract with consequences; looser than the SLO
Error budget(1 − SLO) x window; the policy says what happens when it's spent

Arithmetic

Serial (hard deps)A = a1 x a2 x ... x an
Parallel, independentA = 1 − (1 − a)^2
Parallel, shared fraction cunavailability ≈ c(1 − a) + ((1 − c)(1 − a))^2
30-day budget at 99.9%43.2 minutes
30-day budget at 99.99%4.3 minutes

Alerting

Burn rateBudget consumption speed relative to exactly spending it in the window
Pagee.g. burn rate 14.4 over 1 h (2% of a 30-day budget), confirmed on a short window

05 · Trade-offs, reversibility and ADRs

Reversibility

One-way door (Type 1)Consequential, hard to reverse: decide slowly, with care
Two-way door (Type 2)Reversible: decide fast, in small groups
Two-way conversionInterfaces, routers, versioned formats that keep options open
Last responsible momentDecide when waiting would remove an important option

Trade-off statement

GainIn quality-attribute scenario terms
Give upIn the same terms
ConditionsWhen the loss starts to matter
DetectionHow we'd notice, and what we'd do

ADR fields

StatusProposed, accepted, superseded by ADR-N
Context / Decision / ConsequencesNygard's core structure
AlternativesWhat was rejected and why
Revisit whenThe trigger to check the decision again