FlashKeepers

Databases · College · College and University

Distributed Databases: CAP, Consensus and Consistency

CAP theorem, PACELC, replication models, quorum, Raft and Paxos, sharding strategies and consistency models.

About this set

41 basic cards for College Databases. It opens with "What does the CAP theorem state a distributed system can guarantee?" and "In CAP, what does consistency mean?". Study it alongside the other College sets below.

41 cards · basic cards · AI-written, checked twice. Edit anything.

Study this set free Look inside first Get FlashKeepers for iPhone

Opens in your browser, no account. Get the iPhone and iPad app · Android app

What does the CAP theorem state a distributed system can guarantee?
Show answerAt most two of three: consistency, availability, or partition tolerance
In CAP, what does consistency mean?
Show answerAll nodes see the same data at the same time
In CAP, what does availability mean?
Show answerEvery request receives a response, though it may not be the most recent data
In CAP, what does partition tolerance mean?
Show answerThe system continues operating even when network partitions split nodes
Why can a distributed system not have all three CAP properties?
Show answerDuring a partition, nodes cannot communicate, so you must sacrifice either consistency or availability
What does PACELC extend about the CAP theorem?
Show answerIt addresses both partition scenarios: if partition, choose PA; else, choose between latency and consistency
What trade-off does PACELC introduce in non-partition scenarios?
Show answerLatency vs consistency: lower latency requires accepting eventual consistency
Name a distributed system that chooses availability during partitions.
Show answerAmazon Dynamo or Cassandra, which use eventually consistent replication
What is eventual consistency?
Show answerAll replicas converge to the same state eventually, but may be inconsistent temporarily
What is strong consistency, also called linearizability?
Show answerReads always reflect all acknowledged writes, as if data resided on a single server
What is causal consistency?
Show answerCausally related writes are seen in the same order by all processes
What is session consistency?
Show answerWithin a single client session, reads and writes are mutually consistent
What is read-after-write consistency?
Show answerAfter a write, the same client always reads the value it wrote
What is monotonic read consistency?
Show answerOnce a client reads a value, subsequent reads return the same or a newer value
What is monotonic write consistency?
Show answerWrites from the same process are visible to all others in the order they were performed

26 more cards in the app

Study this set free