Evolutionary ArchitectureCD-02 · theory

Source · Ford, Parsons, Kua & Sadalage, Building Evolutionary Architectures 2e (O'Reilly)

Why this matters

Ford, Parsons, Kua & Sadalage, Building Evolutionary Architectures 2e, Ch. 1

Every architecture decays. Requirements shift, teams change, dependencies rot, and a design that was clean at launch slowly accumulates violations nobody notices until it is expensive. The traditional response — big up-front design plus periodic manual review — cannot keep pace with continuous delivery.

Evolutionary architecture reframes the goal: instead of predicting the future, build an architecture that can change safely and continuously. The key insight is that if you can measure the qualities you care about, you can guard them automatically as the system evolves.

The concept

Building Evolutionary Architectures 2e, Ch. 2 (Fitness Functions)

The book defines an evolutionary architecture as one that supports guided, incremental change across multiple dimensions.

Guided means change is steered toward desired characteristics rather than left to chance. The steering mechanism is the fitness function: any objective, executable check of how far the architecture meets a required characteristic — performance, coupling, security, scalability, and so on. A fitness function can be a unit test, a metrics threshold, a chaos experiment, or a monitoring alert.

Incremental means the system can be built and deployed in small steps, which requires strong engineering practices — a robust deployment pipeline, testing, and the ability to release safely.

Across multiple dimensions acknowledges that architecture is more than code structure: it spans data, security, operability, and the domain. Fitness functions can be atomic (one dimension, run in isolation, e.g. a cyclomatic-complexity check) or holistic (several dimensions together, e.g. security under load). They can run as triggered checks in a pipeline or continuous monitors in production.

Worked scenario

Building Evolutionary Architectures 2e, Ch. 2 & Ch. 6 (Governance)

A team wants to keep its layered architecture from decaying into a big ball of mud where any layer calls any other. They encode the rule 'the presentation layer may not directly access the persistence layer' as an architecture-test fitness function using a tool like ArchUnit. It runs on every commit in the deployment pipeline — a triggered, atomic fitness function.

They also care that the 99th-percentile checkout latency stays under a threshold. That cannot be proven by a static test, so they add a continuous, holistic fitness function: a production monitor that alerts and can fail a deployment when latency regresses.

Together these functions form the architecture's automated governance: the rules are executable, versioned alongside the code, and enforced on every change instead of during an occasional review board.

How it connects

Building Evolutionary Architectures 2e, Ch. 6-7

Fitness functions turn the metrics from the Architecture Metrics topic — coupling, cohesion, cyclomatic complexity — into automated guardrails. They also enforce the boundaries that DDD's bounded contexts define.

Evolutionary architecture is the discipline that makes The Hard Parts' decompositions safe over time: as you split services and data, fitness functions catch regressions in the very qualities (coupling, contracts, latency) those decompositions put at risk. Governance shifts from committees to code.

Common traps
  • Thinking a fitness function must be a test. It is any objective measure of an architectural characteristic — a metric threshold, a monitor, a chaos experiment, or a manual check — not only unit tests.
  • Confusing atomic with triggered. Atomic vs holistic describes how many dimensions are measured; triggered vs continuous describes when the check runs. A function has one value on each axis.
  • Believing evolutionary architecture means no planning or no design. It requires strong engineering discipline (pipelines, testing) and deliberate characteristics; it replaces guesswork, not thought.
Key takeaways
  • An evolutionary architecture supports guided, incremental change across multiple dimensions.
  • Fitness functions are objective, executable checks of architectural characteristics — atomic vs holistic (scope) and triggered vs continuous (timing).
  • Governance becomes automated: architectural rules are encoded as code and enforced on every change rather than in periodic manual reviews.