• CAP theorem states that a distributed system can only guarantee two out of three:
    1. Consistency – Every read returns the latest write.
    2. Availability – Every request gets a response (even if it’s not the latest).
    3. Partition Tolerance – System works even if there’s a network failure between nodes.
  • You must sacrifice one in the presence of a network partition.
  • Common trade-offs:
    • CP: Consistency + Partition Tolerance (e.g., HBase)
    • AP: Availability + Partition Tolerance (e.g., Cassandra)
    • CA is not possible in distributed systems with partitions.