Lesson 02 of 5 · Requirements and numbers
From brief to quality-attribute scenarios
Turn vague words like "scalable" and "secure" into six-part quality-attribute scenarios that can be tested, rank them in a utility tree, and find the trade-off points and risks the way an architecture evaluation does. Includes the questions that surface the requirements nobody wrote down.
Forces
Briefs arrive in adjectives: fast, highly available, secure, scalable, easy to integrate. Each adjective hides a range of designs that differ by an order of magnitude in cost. "Highly available" can mean a single instance with a fast restart, or active-active across three regions. If the number is not agreed before the design, it is agreed after the first outage, by the person who is angriest.
The forces here are social as much as technical. Stakeholders don't know the cost of each "nine", engineers don't know which business events actually matter, and both sides are happy to leave the word vague because vagueness avoids an argument today. The architect's job is to have that argument early, with numbers.
First principles
The six-part scenario
The Software Architecture in Practice method (SEI) writes each quality requirement as a scenario with six parts:
| Part | Question it answers | Example (availability) |
|---|---|---|
| Source | Who or what causes the event? | Hardware in one availability zone |
| Stimulus | What happens? | The zone loses power |
| Artifact | What part of the system is hit? | The order API and its primary database |
| Environment | In what state is the system? | Normal operation, peak hour |
| Response | What should the system do? | Continue serving reads and writes from the other zones |
| Response measure | How do we know it did? | Error rate under 1% for at most 60 s; no acknowledged write lost |
The response measure is the part that matters. Without it the scenario can't be tested, so it isn't a requirement. Write one scenario per stimulus that matters; a quality attribute usually needs three to six.
Scenarios for other attributes follow the same shape:
Performance Source: 2,000 concurrent users. Stimulus: submit a search.
Environment: peak, 10M records per tenant. Response: results returned.
Measure: p99 < 400 ms, p50 < 120 ms, measured at the edge.
Security Source: an external attacker with one stolen session token.
Stimulus: replays it after the user logs out. Artifact: the API.
Response: request rejected. Measure: within 60 s of logout, 100% of replays fail;
the attempt appears in the audit log within 5 min.
Modifiability Source: a product team. Stimulus: add a new field to the tenant profile.
Environment: design time. Response: change made, tested, deployed.
Measure: one team, one service, under 2 days, no coordinated release.
Operability Source: the on-call engineer. Stimulus: the primary database fails at 03:00.
Response: failover completed. Measure: by one documented command,
under 5 min, without paging a second team.
Utility tree
A system has dozens of candidate scenarios; you can't optimise all of them. A utility tree ranks them: root "utility", then quality attributes, then refinements, then concrete scenarios. Each leaf gets two ratings, usually High/Medium/Low:
- Importance to the business (rated by stakeholders).
- Difficulty to achieve with the current or proposed architecture (rated by architects).
The (H, H) leaves are where architecture effort goes. (H, L) leaves are easy wins to protect. (L, H) leaves are candidates to negotiate down.
Utility
├── Availability
│ ├── Zone failure: no write loss, < 60 s errors ............ (H, H)
│ └── Region failure: read-only within 15 min ............... (M, H)
├── Performance
│ └── Search p99 < 400 ms at 10M records/tenant ............. (H, M)
├── Security
│ ├── Revocation enforced within 2 s globally ............... (H, H)
│ └── Stolen token unusable within 60 s of logout ........... (H, M)
└── Modifiability
└── New tenant attribute: one team, < 2 days .............. (M, L)
Sensitivity points, trade-off points, risks
The Architecture Tradeoff Analysis Method (ATAM) gives three words that make a review precise:
- A sensitivity point is a design property that strongly affects one quality attribute. Token lifetime is a sensitivity point for revocation latency.
- A trade-off point is a property that affects two or more attributes in opposite directions. Token lifetime is also a trade-off point: shorter tokens improve revocation but add load on the identity service and add latency on refresh.
- A risk is an architectural decision that may lead to an undesirable outcome given the scenarios. "Revocation relies on token expiry only, with 15-minute tokens" is a risk against the 2-second scenario.
When you present a design, list the trade-off points explicitly. That is most of what a senior reviewer is looking for.
Design space: finding the requirements nobody wrote
Stakeholders state functional needs. You have to ask for the rest. Questions that reliably surface hidden quality requirements:
| Area | Ask |
|---|---|
| Load shape | What does the busiest hour look like? Month-end? A customer onboarding 50,000 users at once? |
| Business events | Which single event, if lost, causes a support escalation or a regulatory report? |
| Failure tolerance | What can be read-only for an hour? What can't be down for one minute? |
| Data | Who may see this data, from where, for how long? What must be deleted, and when? |
| Customers | Does any customer have a contract clause about location, isolation, keys or uptime credits? |
| Integration | Who calls us, how often, with what retries? Who do we call, and what happens when they're slow? |
| Operations | Who is on call? At what hour is the team awake? What does a deploy require today? |
| Change | What is most likely to change in the next 18 months? What did the last three big changes cost? |
| Cost | What is the budget per tenant, per transaction, per month? What price are we selling at? |
Write each answer as a scenario, then ask the stakeholder to confirm the response measure. Confirmation in writing is the point: it turns a preference into a requirement someone owns.
Failure modes
- Adjectives in the spec. "Fast", "robust", "scalable": nothing to test, so nothing to design against.
- Averages instead of percentiles. "Average response 200 ms" allows 5% of users to wait 10 s.
- No environment part. A performance requirement that doesn't say "at peak" or "with 10M records" is met in a demo and missed in production.
- Only the happy path. No scenarios for degraded mode, deploys, or a dependency being slow.
- Every scenario marked High. Then nothing is prioritised, and the design optimises whatever the loudest stakeholder said last.
Published incident: HealthCare.gov launch, October 2013
The US federal health-insurance marketplace launched on 1 October 2013 and could not handle its first day. Reviews by the Government Accountability Office (2014) and the HHS Office of Inspector General (2016) found that requirements kept changing late, no single party owned end-to-end integration, and capacity and performance testing were inadequate. The system had not been designed or tested against a defined peak load, so the first real peak was the test. Only a few people managed to enrol on the first day. The rescue team set explicit performance and capacity targets, added monitoring, and fixed bottlenecks one by one. Lesson: a quality attribute without a response measure and an environment is not tested, and an untested attribute fails on launch day.
Lab (written exercise): from brief to utility tree
Brief: "We need a secure, highly available, fast platform for managing employee access across our customers' applications. It must scale as we grow."
- List every adjective in the brief. For each, write the questions you would ask (use the table above).
- Assume these answers: 6,000 customers in 18 months; largest customer 120,000 employees; access changes peak at 09:00 Monday at 20 times the daily average; a missed revocation is a reportable security incident; reviewers accept the dashboard being read-only for up to 30 minutes; 40 customers require EU data residency.
- Write at least eight six-part scenarios covering availability, performance, security, modifiability and operability.
- Build the utility tree. Rate importance as the business would and difficulty as you would.
- For the two (H, H) leaves, name at least one sensitivity point and one trade-off point each.
A worked scenario to start from:
Attribute Security / integrity
Source A customer administrator
Stimulus Revokes an employee's access to an application
Artifact Authorisation decision path (all regions)
Environment Peak: 09:00 Monday, 20x average change rate
Response All subsequent access checks for that grant are denied
Measure p99 propagation < 2 s, 100% of checks after that point deny; audit event written
Sensitivity Decision-cache TTL; replication lag of the grants store
Trade-off Cache TTL: shorter improves revocation, raises load on the decision store
Architect's lens
From the ten questions in What architects actually decide, this lesson turns purpose, scale, failure and security from questions into numbers. The rule for every design you present from now on: no quality attribute appears without at least one scenario with a response measure.
Design review
Brief. A payments-adjacent service lets merchants issue refunds. Product says it must be "always available, instant and safe". Today it handles 40 refunds per second at peak; finance expects 300 per second at year-end sales.
Produce: ten scenarios across at least five quality attributes; a utility tree with ratings; the three (H, H) leaves with their sensitivity and trade-off points; and the risks you would bring to the first review.
| Level | What the answer shows |
|---|---|
| Senior | Measurable scenarios with percentiles and environments |
| Staff | A ranked utility tree; idempotency and duplicate-refund scenarios found without prompting; trade-off points named |
| Principal | Negotiated targets (what "always" will cost, and the counter-proposal), degraded-mode scenarios, an operability scenario for year-end, and the evidence plan that will prove each measure |
Self-check
What is wrong with "the API responds in under 200 ms"?
No percentile, no environment and no measurement point. Write it as "p99 < 200 ms at the edge, at peak load of N rps, with the largest tenant's data set".
Token lifetime affects revocation speed and identity-service load. What ATAM term describes it?
A trade-off point: one property that moves two quality attributes in opposite directions.
A stakeholder rates every scenario High importance. What do you do?
Ask for forced ranking against cost: show what each scenario costs to achieve, and ask which they would give up first. If they can't choose, take it to whoever owns the budget.
References
- Bass, Clements and Kazman, Software Architecture in Practice, 4th edition, chapters 3-14 (scenario templates per attribute)
- Kazman, Klein and Clements, "ATAM: Method for Architecture Evaluation", SEI Technical Report CMU/SEI-2000-TR-004
- U.S. GAO, "HealthCare.gov: Ineffective Planning and Oversight Practices Underscore the Need for Improved Contract Management", GAO-14-694, 2014
- HHS OIG, "HealthCare.gov: CMS Management of the Federal Marketplace", OEI-06-14-00350, 2016
- Google, Site Reliability Engineering, chapter 4 "Service Level Objectives"
Related on this site
- Requirements → NFRs in Cluster Design
- Symptom-based monitoring in SRE & Incidents
This site is a public version of my personal engineering knowledge hub. It intentionally excludes confidential company information and internal operational details.