Theory of Intelligence
BACKEND ENGINEERING•Linux And Networking•Real Time And Edge•3.3 Load Balancers, Proxies & Gateways

3.3.1 Load Balancing

Subtopics: Load Balancing, Reverse Proxies and API Gateways.

3.3.1 Load Balancing

A load balancer sits in front of a pool of app instances and picks one for each request. Algorithms include round-robin, least connections, and consistent hashing.

Why it matters

One process cannot serve all users. Balancing lets you add machines and survive a single instance dying.

How it is used

Health checks remove bad instances from the pool. Sticky sessions are a last resort — prefer stateless apps and shared stores (Redis, DB) so any instance can handle any user.

Discuss theoretical concepts, mathematical formulas, and architectural foundations.

Supports inline code with `backticks`
No comments yet. Be the first to start the discussion!