Transactions Motivation

Concept. A transaction groups related database operations into one all-or-nothing unit.

Intuition. When millions of Taylor Swift fans hit Ticketmaster at once, each purchase (check the seat, charge the card, mark it sold) must complete entirely or not at all, so no two fans get the same seat. The required guarantees are no duplicate seat sale and no charge without a seat. Under heavy load, queues stalled, sales were delayed, and fans encountered errors. The hard problem is keeping transactions correct and fast under that crush.

Case Study: Taylor Swift’s Eras Tour

Alice clicks Buy; that one click is a single transaction wrapping three steps (check the seat, charge the card, record the sale) that either all commit or all abort, run about ten thousand times per second.

Figure 1. One fan's Buy click is a single transaction: check the seat is open, charge the card, record the sale, bundled so either all three commit or none do, never a charge without a seat and never the same seat to two fans. Multiply by the on-sale crush, every fan racing for the same seats, and you have the problem this module solves.

The Scale of the Problem

The on-sale by the numbers: 52 show dates, 3.5 million fans pre-registered, over 2 million tickets sold on Ticketmaster in a single day, and 3.5 billion system requests in a few hours.

What Went Wrong?

Ticketmaster reported 3.5 billion system requests, four times its previous peak. Sales were slowed or postponed, and validation errors caused fans to lose carted tickets. The database still has to enforce two guarantees: no seat sold twice and no charge without a seat.

Heavy demand disrupted availability. Correct transactions must prevent duplicate seat sales and completed charges without a seat.

Figure 2. Ticketmaster reported 3.5 million registrations and 3.5 billion system requests, four times its prior traffic peak. Sales were delayed and fans encountered errors. The transaction guarantees are simple: no seat sold twice and no charge without a seat. Keeping those guarantees while staying responsive under load is the problem this module addresses.

How That Compares

Visa reports capacity above 65,000 transaction messages per second. DynamoDB peaked at 105.2 million requests per second during Prime Day 2022. Ticketmaster reported four times its prior traffic peak.

Figure 3. Visa reports capacity above 65,000 transaction messages per second. During Prime Day 2022, Amazon DynamoDB peaked at 105.2 million requests per second with single-digit millisecond responses. Ticketmaster reported four times its previous traffic peak. These are different workloads and metrics, but all require deliberate engineering for concurrency and availability.


Growing concurrency

More clients create more overlapping work. Hardware, storage, and indexing choices change with the workload; the requirement to keep each transaction correct remains.

Three illustrative write-throughput tiers: classic retail systems in the 1990s and 2000s at about 10,000 writes per second; cloud services such as Gmail and Roblox in the 2010s and 2020s at millions; agent workloads from 2025 onward targeting tens of millions, with NVMe and distributed compute. Rates describe illustrative tiers rather than measured service benchmarks.

Figure 4. Classic retail systems such as Walmart, cloud services such as Gmail and Roblox, and agent workloads from 2025 onward illustrate increasing write demand: about 10,000 writes per second, millions, and a target of tens of millions. These are illustrative scale tiers, not measured rates for the named services. Hardware progresses from disks and a few cores to SSDs and many cores, then NVMe with distributed compute; every tier still needs correct transactions.


What We'll Learn

The four guarantees that make this safe under load, atomicity, consistency, isolation, and durability, are ACID. They start on the next page.

Sources