All Questions
Cassandra hard

Cassandra uses Last-Write-Wins (LWW) based on microsecond timestamps. If two distinct clients write conflicting values to the same cell with the *exact* same timestamp, how is state convergence achieved?

  1. A The database keeps both versions and marks the row as 'Conflicted'.
  2. B The conflict remains forever; half of the nodes will see Value A and half will see Value B.
  3. C Deterministic Lexicographical Tie-breaker: If timestamps are identical, Cassandra compares the bytes of the values themselves. The value that is larger (in a byte-by-byte comparison) is chosen as the winner on all nodes.
  4. D The node with the lowest IP address is the final authority.

One system design question a day, with spaced repetition so the ones you miss come back.

Get the app

Related questions