BolEnglishLearn · Play · Win
Login

⚖️ System Design · System Building Blocks

⚖️

Load Balancing

Building BlockCoreModule 3

Distribute traffic across multiple servers.

One server should not receive all requests when several can share the work.

💡 In practice

A load balancer sends users across three application servers.

🖼️ CONCEPT PICTURE
A picture to help remember Load Balancing
A load balancer sends users across three application servers.

💡 Like a supermarket opening more checkout lanes at rush hour so no single queue gets huge.

💡 Learn🛠️ Apply🎯 Check

💡 Why it matters

A single server has limits, and when it is overwhelmed everyone's requests slow down or fail. A load balancer spreads requests so the system can handle more users and keep working if one server dies. It is the simple move that turns one fragile machine into a resilient group.

🛠️ How to achieve it

1
Put a balancer in front
Route all incoming requests through a load balancer that forwards them to a pool of servers.
2
Check server health
Have the balancer stop sending traffic to a server that is failing its health checks.
3
Keep servers interchangeable
Design servers so any of them can handle any request, which pairs with stateless design.
4
Plan to scale out
Add more servers behind the balancer as traffic grows instead of buying one huge machine.

⚠️ Signs of trouble

  • •All traffic hits one server while others sit idle.
  • •The whole system goes down when a single server fails.
  • •Response times spike sharply during busy periods.
  • •Adding capacity means replacing one machine with a bigger one.
⚠️ Common mistake: Routing traffic to servers that store session state locally, so a user breaks when sent to a different server. Keep servers stateless so any of them can serve any request.

🎯 Quick check

Score: 0/3

Three questions to test the idea.

  1. 1. What does a load balancer do?

    Answer: Spreads requests across several servers

    A load balancer distributes incoming traffic so no single server is overwhelmed.

  2. 2. Why do balanced servers need to be stateless?

    Answer: So any server can handle any request without breaking the user

    If state lives on one server, a user sent to a different server loses it; stateless servers are interchangeable.

  3. 3. How should you add capacity behind a load balancer?

    Answer: Add more servers to the pool (scale out)

    Scaling out adds interchangeable servers so the balancer has more capacity to share load across.

🔑 Key terms

Load balancer
A component that spreads requests across several servers.
Health check
A test the balancer uses to see if a server is working.
Scale out
Adding more servers to share the load.
Server pool
The group of interchangeable servers behind the balancer.

✅ Review checklist

📊 Your progress

0%
Mark this topic learned to track it.
Saved in this browser.
🚀 Got it?
Mark it learned and move to the next topic.
Next topic →