Pebellslearn by building
0%
RoadmapsMatrixCoursesSandboxSign in
Introduction to System Design  ›  Lesson

What Is System Design?

What is System Design? 12 minSystem design is deciding which parts a software system has, how they talk to each other, and how the whole keeps working as load grows and parts fail.

What Is System Design?

Writing a function that turns a long web address into a short code takes an afternoon. Keeping that shortener answering in a few milliseconds for millions of people, while machines crash and traffic spikes, is a different job. That second job is system design.

The rule

Design decides the parts, the paths between them, and the plan for failure.

A system design answers three questions:

  • The parts. Which pieces exist? Browsers and apps (clients), application servers that run your code, databases that remember things, and later caches, queues and load balancers.
  • The paths. How does a request travel between them, and what data moves along the way?
  • The plan for failure. What happens when a part is slow, full, or gone?

Meet Hop, the link shortener we will grow through this whole course. Version one is tiny:

browser  ->  Hop server  ->  database (short_code -> long_url)

A visitor opens hop.example/x7Kp. The server looks up x7Kp, finds the long address, and replies "go there instead". That is a complete system: parts, a path, and — so far — no plan for failure at all.

Code-level design asks "how should this function be written?" System design zooms out: it asks where each function runs, how many copies run, and what they share. Nobody gets it right once and forever. A design fits a size: what suits a thousand clicks a day is wrong for a billion, and the reverse is just as true.

The shortcut

When you meet any system, draw it as boxes and arrows, then point at each box and ask: "What if this one disappears?"

Stress-testing Hop version oneStep 1 of 4
  1. Draw the boxes

    Browser, Hop server, database. Three boxes, two arrows.

The trap is designing for a scale you do not have. Hop at a hundred clicks a day does not need twelve services. Good design fits today's size and leaves room for the next one.

Drills

Answer fast — trust the rule.

quick drill

Which question is a system design question rather than a code-level one?

quick drill

In Hop version one, what is a single point of failure?

quick drill

What does Hop's server do when someone opens hop.example/x7Kp?

quick drill

Hop gets 100 clicks a day. What is the best design choice right now?

Remember

  • Design decides the parts, the paths between them, and the plan for failure.
  • Shortcut: draw boxes and arrows, then ask "what if this one disappears?"
  • Trap: designing for a scale you do not have yet.

Practice — level up

0/1 solved

Write your answer, then compare it with a rubric and a model answer.

ExplainDescribe Hop's first design

Hop turns a long web address into a short one like hop.example/x7Kp and sends visitors onward when they click it. Describe a first design for Hop in plain words: name its parts, say how a click flows through them, and name one thing that would break first if Hop became popular.