Blog

Filter posts by Category Or Tag of the Blog section!

CAP theorem

Saturday, 28 November 2020

The CAP theorem, also known as Brewer's theorem, is a concept in computer science that describes the limitations of distributed systems. The theorem states that in any distributed system, it is impossible to simultaneously provide all three of the following guarantees:

 

  1. Consistency: All nodes in the system see the same data at the same time.
  2. Availability: Every request made to the system gets a response, without a guarantee that it contains the most recent version of the information.
  3. Partition tolerance: The system continues to function even when network partitions occur.

 

The CAP theorem helps designers and developers of distributed systems to make trade-offs between these three guarantees, as they must choose which two to prioritize over the third. This is because a distributed system can only guarantee two out of three properties at a time.

 

 

For example, if a distributed system prioritizes consistency and partition tolerance, it might limit availability during network partitions. Similarly, a system that prioritizes availability and partition tolerance may accept inconsistent data in order to ensure high availability during network partitions.

 

comments powered by Disqus