Contents

Architecture & System Design › Architecture Styles

Architectural Trade-offs

Every architecture decision gives something up; naming what.

Also known as: architecture trade-offs, trade-offs in architecture, tradeoffs, it depends, architecture decisions trade-offs

There is no best architecture. Every significant design choice gives you something and takes something away, and the right choice depends on your context: your goals, constraints, team and what you’re optimizing. A senior engineer’s answer to “which should we use?” is rarely “X”. It’s “it depends on these factors, and here’s what we gain and lose with each.”

Qualities pull against each other

Systems are judged on qualities such as performance, scalability, availability, consistency, security, cost, simplicity, time to market and maintainability (quality attributes, non-functional requirements). Improving one often costs another:

ChoiceYou gainYou give up
CachingSpeed, lower loadFreshness, simplicity (invalidation)
MicroservicesIndependent deployment and scaling, team autonomyOperational complexity, consistency, debuggability
Strong consistencySimple reasoning, correct readsLatency and availability
DenormalizationFast readsWrite complexity, risk of inconsistency
Build vs buyControl and fit vs speed and lower maintenanceTime and cost, or flexibility
More abstraction/flexibilityAdaptabilitySimplicity, performance, readability
RedundancyAvailabilityCost, complexity
RewriteClean designRisk, time, lost features

Example: “We’ll use a message queue between checkout and email.” Gain: checkout isn’t slowed or broken by email problems. Cost: the email is delayed and the flow is harder to trace. For an email, worth it. For a payment confirmation the user waits on, maybe not.

How to reason about them

  • Name the trade-off explicitly. “We’re choosing availability over strict consistency here, accepting that a user might briefly see stale data.” Unstated trade-offs become surprises.
  • Know what actually matters here. Rank the qualities for this system: a trading platform and a marketing site differ.
  • Use numbers. Expected load, data size, latency targets and cost make “it scales” and “it’s fast enough” testable.
  • Consider reversibility: prefer cheap, reversible choices, and spend care on irreversible ones (one-way and two-way doors).
  • Consider the team: a technically elegant design that your team can’t operate is a bad trade.
  • Consider time. Today’s good-enough solution may be tomorrow’s constraint. Decide when you’ll revisit.
  • Compare real alternatives, including “do nothing” and “the simple version”.

Make it durable

Be wary of absolute claims (“always use X”, “never do Y”) and of trends. Good architecture is the discipline of making deliberate trade-offs, and being honest about what you gave up.