System Design Patterns: From Fundamentals to Real Systems
Vote

0% completed

​

Course Introduction

What a System Design Pattern Is

The Store

The Course Map

How the Lessons Are Built

Using the Course for an Interview

How to Start

System Design Patterns Course Introduction: What the Course Covers, Who It Is For, and How Each Lesson Works (Video)
Course Introduction
Course Introduction

Before you start, here is what this course promises, and what it does not.

What the course promises:

  • You will learn more than 60 system design patterns. For each one, you will learn the problem it solves, how it works, and what it costs.
  • Every pattern is shown on one online store, with real numbers like requests per second and milliseconds.
  • You will learn a fixed order of questions. Starting from a blank whiteboard, these questions lead you to a first design in a few minutes.
  • You will practice combining patterns into complete systems, because real designs use many patterns together.

What the course does not promise:

  • It does not teach any one product. Products like Redis (an in-memory data store), Kafka (a message log), and cloud services appear as examples, but the patterns work without them.
  • It does not give you a finished design to memorize for each interview question. It teaches you to build one.
  • It covers the patterns that appear again and again in real systems and interviews, not every pattern ever named.

This lesson introduces the store, maps the 12 modules of the course, explains how the lessons are built, and shows how to use the course to prepare for an interview.

What a System Design Pattern Is

A system design pattern is a known solution to a problem that appears in many systems, described together with its cost. "Put a fast copy of popular data in memory" is a pattern, and so is "hold work in a list until a worker is free to do it." Each pattern has a name, so engineers can discuss a design in a few words.

This course treats every pattern as three parts: the problem, the solution, and the cost. The next lesson, Thinking in Patterns, explains why the cost matters as much as the solution.

The Store

The whole course follows one online store. Buyers browse products, add them to a cart, and tap Place order. On a normal day, the store takes 200 orders per second.

The store is built from several services. A service is a program that does one job and that other programs call over the network. When a buyer places an order, the checkout service calls four other services, one after another:

  1. Inventory reserves the item (30 milliseconds, or ms).
  2. Payment charges the card (150 ms).
  3. The orders database saves the order (20 ms).
  4. Fulfillment schedules the shipping (50 ms).

This sequence of four calls is the checkout chain. The buyer waits for all four calls, so one order takes 30 + 150 + 20 + 50 = 250 ms.

The checkout chain
The checkout chain

Follow the numbers 1 to 4. Checkout waits for each call to return before it makes the next one. The bar at the bottom shows the result: one order takes 250 ms, and payment uses 150 ms of it, more than half.

This chain works on a normal day. However, the store grows across the course. A flash sale (a short sale with large discounts) brings far more orders than the chain can finish. The database receives more reads than it can serve. Later, the store grows toward 100 million users.

Each module starts from one of these problems and teaches the patterns that solve it.

The Course Map

The course has 12 modules. Module 1 teaches the method, Modules 2 to 11 teach the patterns, and Module 12 combines them into complete designs.

The course map
The course map

Look at the tags on the cards. Modules 2 to 10 are grouped around five questions: flow, storage, speed, failure, and growth. The lesson The Five Questions teaches those questions in that order, so each question leads you to the modules that answer it.

ModuleWhat it teachesThe store's problem
1. Thinking in Patterns (Foundations)What a pattern is, the five questions, and quick estimatesNo pattern is added yet, so the store is measured first
2. Moving Data (Communication)How services send data: wait for an answer, queue a job, or publish an eventA flash sale sends 5,000 orders per second to a chain that can finish only 400
3. Storing Data (Storage and Replication)Keeping copies of data and splitting it across machinesOne database machine holds every product and order
4. Serving Data Fast (Caching)Fast copies of data that is read oftenProduct pages send more reads than the database can serve
5. Surviving Failure (Reliability)Timeouts, retries, and limits on how far one failure spreadsThe payment provider slows down or stops answering
6. Growing Under Load (Scaling)Bigger machines, more machines, and spreading traffic across themTraffic grows past what one server can handle
7. Keeping Data Consistent (Distributed Consistency)How several machines agree on one changeAn order touches inventory, payment, and fulfillment, each with its own data
8. The Entry Point (API and Edge)What sits between the buyer and the store's servicesA buyer in Sydney waits for every request to reach a distant server
9. Operating in Production (Observability and Delivery)Seeing what the system does and changing it safelyA bad deploy can stop checkout for every buyer
10. Data-Intensive Systems (Batch and Streaming)Processing large amounts of data in batches and as streamsEvery click must reach a report and a live dashboard
11. AI-Era Systems (LLM and ML <span style="white-space:nowrap">Infrastructure</span>)Serving machine learning models and language modelsA fraud model and a shopping assistant need GPUs (graphics processors that run models) and new kinds of caching
12. Capstones (Composing Everything)Four complete designs, then a review of every patternNew systems, designed from requirements to the final diagram

Modules 2 to 11 each end with a mini-capstone: a lesson that builds one system from the patterns of its module. For example, the Moving Data module ends by designing a notification system. A mini-capstone shows the module's patterns working together, and it is the best place to check what you learned.

How the Lessons Are Built

The course has three kinds of lessons, each built for a different job.

Pattern lessons teach one pattern each. A pattern lesson starts from a problem at the store, with numbers. It then builds the pattern step by step and states its cost with the same numbers. Layouts differ by topic, but every pattern lesson ends the same way:

  • Check Yourself: three questions with answers that stay hidden until you open them. The third question describes an incident at the store: a failure that you explain and fix.
  • In the interview: a short answer that you could say aloud, and the follow-up question an interviewer is likely to ask.
  • Key takeaway: the lesson in a few sentences.

Module introductions open Modules 2 to 12. Each one states the module's central question, defines the terms its lessons share, and lists its lessons in order. It ends with three questions that you can ask about a system you already know.

Capstones start with a short problem brief that has numbers. The design is then built one decision at a time. At two or three points, a "Pause and decide" box asks you to choose before you read the answer.

Every pattern lesson comes with flashcards: short questions with short answers that help you remember the main facts. Pattern lessons and capstones also have a quiz of 25 questions. Try the quiz a day after the lesson, because remembering after a pause shows what you really learned.

Using the Course for an Interview

A system design interview asks you to design a system aloud in about 45 minutes. The interviewer judges how you choose parts and explain their costs. Three parts of the course prepare you for this.

First, Module 1 gives you a method that works for any design. Its three lessons are listed at the end of this lesson.

Second, each pattern lesson ends with an "In the interview" box. It gives a short spoken answer that names the problem, the pattern, and its cost. Practice saying these answers aloud, not only reading them.

Third, Module 12 is interview practice. Its four complete designs are a news feed, ride-sharing dispatch, a payment platform, and an AI copilot. A review of every pattern and its cost follows them.

If your interview is soon, follow this order. Read Module 1 in full. Then read Modules 2, 4, and 5, which cover the patterns that appear in most designs. Then practice the four designs of Module 12. Return to the other modules when a design needs a pattern you have not learned yet.

How to Start

Read the Module 1 lessons in order, because each one uses the one before.

  1. Thinking in Patterns explains what a pattern is, why every pattern has a cost, and why the hardest decisions happen where patterns meet.
  2. The Five Questions gives a fixed order of questions for any design, starting from a blank whiteboard.
  3. Back-of-the-Envelope Math turns the store's numbers into the estimates that decide which patterns it needs.

This lesson showed you the course map. It did not yet explain what makes a solution a pattern. "Add Redis" and "use cache-aside, with a copy up to 60 seconds old" can describe the same system. However, only the second one names a pattern and its cost, so only the second one can be reviewed. Start with Thinking in Patterns to see why.

Reading Progress

0%


Vote for new content

On This Page

What a System Design Pattern Is

The Store

The Course Map

How the Lessons Are Built

Using the Course for an Interview

How to Start