Stackbook Logo
scalingestablished · high operational burden

Multi-Region Active-Active

Also known as: active-active, multi-master-regions

Intent

Serve traffic and accept writes in several regions simultaneously for low latency and regional fault tolerance.

Problem

A single region is a failure domain and is far from some users. Active-passive failover wastes standby capacity and often fails when first exercised.

Forces

  • •Users need low latency worldwide
  • •Region outages must not take the service down
  • •Cross-region replication has latency and conflict risk
  • •Cost and complexity multiply with each region

Solution

Overview

In active-active, every region serves production traffic and can accept writes. Capacity is shared, and losing a region means redirecting its users rather than activating a cold site.

Data is the hard part. Options include a globally distributed database with tunable consistency, per-entity home regions with routed writes, and conflict-free replicated data types for counters and sets. Each shifts the trade-off between latency, consistency, and operational complexity.

How it works

Global routing sends users to the nearest healthy region; data replicates asynchronously between regions.

            Global DNS / anycast (latency + health)
           /                \
    Region A (EU)  <==async==>  Region B (US)
    app + DB writes             app + DB writes
Rule: each entity has a home region, or merge via CRDT / LWW

Plan capacity for the failure case. With three regions, each should carry at most about sixty-six percent of its capacity in steady state to absorb a lost neighbor. Test failover with game days that shift traffic and verify that autoscaling, quotas, and caches keep up.

Pitfalls

  • Provisioning each region at only half the needed capacity, so one failure overloads the other
  • Using last-writer-wins on data where lost updates matter, such as balances
  • Shared global dependencies like a single auth database that remain single-region
  • Never drilling region evacuation until a real incident

Key takeaways

  • Decide conflict handling before writing code
  • Size each region to survive the loss of another
  • Eliminate hidden single-region dependencies
  • Practice regional drains routinely

✓ When to Use

  • •Global user base with tight latency targets
  • •Availability goals exceed single-region capability
  • •Data residency requires regional processing

✗ When Not to Use

  • •Strong global consistency is mandatory on all writes
  • •Traffic is regional and a warm standby suffices
  • •Team lacks capacity for multi-region operations

Pros

  • +Survives full regional outages
  • +Reduces latency for distributed users
  • +No idle standby capacity

Cons

  • −Conflict handling complicates the data model
  • −Infrastructure cost grows with regions
  • −Testing and debugging span regions

Cost Profile

Infrastructure

High - duplicated stacks and replication traffic

Operational

High

Cognitive

High

Failure Modes

  • Replication lag causes stale reads or conflicting writes

  • Surviving regions lack capacity to absorb a failed region

  • Failover logic itself untested and fails when needed

Real-World Examples

Alternatives

    Related Patterns

    • replication
    • disaster-recovery

    Competency Domains

    reliability opsdata state