What's CAP Theorem in distributed system.

이민석's avatar
Mar 19, 2024
What's CAP Theorem in distributed system.

Introduction

Thank you for clicking through to my arcticle. I've been a DevOps engineer for 2 years in dev-team of 7 engineers.

My name is MINSEOK, LEE, but I use Unchaptered as an alias on the interenet. So, you can call me anythings "MINSEOK, LEE" or "Unchaptered" to ask something.

CAP Theorem

  1. Consistence
    To access distributed system, all clients always get same data in any nodes.

  2. Availability
    If partial node have some error, all clients can receive the response.

  3. Partition Tolerance
    The partition means some network communication trouble is occured between two nodes.
    If network partition is occured, entire system must work.
     

  1. CP (Consistence and Partition Tolerance)

    A CP database delivers consistency and partition tolerance at the expense of availability. When a partition occurs between any two nodes, the system has to shut down the non-consistent node (i.e., make it unavailable) until the partition is resolved.

  2. AP (Availability and Partition Tolerance)

    An AP database delivers availability and partition tolerance at the expense of consistency. When a partition occurs, all nodes remain available but those at the wrong end of a partition might return an older version of data than others. (When the partition is resolved, the AP databases typically resync the nodes to repair all inconsistencies in the system.)

  3. CA (Consistence and Availability)
    A CA database delivers consistency and availability across all nodes. It can’t do this if there is a partition between any two nodes in the system, however, and therefore can’t deliver fault tolerance.

And more datas in here.

References

  1. IBM Technology (Youtube) | What is the CAP Theorem?

  2. IBM Technology (Blog) | What is the CAP Theorem?

Share article
RSSPowered by inblog