Part 1
Written summary
- Chapter 1: The Million-Dollar Mistake...--The pager went off at 2:47 AM on Cyber Monday.
- He had done everything “right.”
- Cloud databases are not magically better versions of on-premise databases.
Read along — the full text
Chapter 1: The Million-Dollar Mistake...--The pager went off at 2:47 AM on Cyber Monday. Sarah, the lead database engineer for a mid-sized e-commerce company, groggily reached for her phone. By 2:49 AM, she was fully awake. By 2:52 AM, she was watching her company’s revenue projection drop by 50,000perminute.By3:15AM,thenumberwas50,000 per minute. By 3:15 AM, the number was 50,000perminute.By3:15AM,thenumberwas1.2 million—gone. Not stolen. Not missing. Simply evaporated because the database couldn’t keep up.The post-mortem revealed the culprit: a senior developer had moved the company’s PostgreSQL database from an on-premise server to AWS RDS six months earlier.
He had done everything “right.” He launched an instance, pointed the application at the new endpoint, and celebrated a successful migration. But he had treated the cloud like a rented data center. The application’s connection pool was configured for a static number of users. The retry logic assumed the database would never disappear. The queries assumed network latency was zero. On the busiest shopping day of the year, under legitimate peak load—not a DDoS attack, not a configuration error, just more customers than usual—the database fell over and refused to get back up.This chapter exists because Sarah’s story repeats itself thousands of times every year.
Cloud databases are not magically better versions of on-premise databases. They are fundamentally different systems that require different thinking, different coding patterns, and a different understanding of what “reliable” even means.1.1 What This Book Is (And What It Is Not)Before we write a single line of SQL or provision a single instance, we need to establish a shared mental model. This is not a reference manual. You will not find exhaustive lists of every AWS RDS instance type or every Azure SQL pricing tier. Those documents exist already, they are well-written, and they change too fast for any book to keep up.This book is a practitioner’s guide to thinking like a cloud database developer.