Advanced
12 min forge

Distributed Systems Basics

Understanding the foundational concepts of distributed systems: transparency, openness, and scalability.

🌐 Distributed Systems: The Foundations

A distributed system is a collection of independent computers that appear to its users as a single coherent system.

1. Why Distributed Systems?

  • Resource Sharing: Sharing storage, computational power, or data.
  • Reliability: If one node fails, others can take its place.
  • Scalability: Add more nodes to handle more load.

2. Key Characteristics

  • Transparency: The user shouldn't know they are interacting with multiple machines.
  • Concurrency: Components execute in parallel.
  • No Global Clock: Each node has its own timing; ordering events is a challenge (see Lamport timestamps).
  • Independent Failures: Parts of the system may fail while others continue to work.

3. Communication Models

  • Remote Procedure Call (RPC): Making a function call on a remote server as if it were local (e.g., gRPC, Thrift).
  • Message Passing: Sending asynchronous messages (e.g., RabbitMQ, Kafka).

4. Challenges

  • Network Partitions: The "split-brain" scenario where nodes cannot see each other.
  • Data Consistency: Synchronization across multiple physical locations.
  • Latency: Communication over a network is orders of magnitude slower than local memory access.