Grokking the System Design Interview, Volume II
Vote

0% completed

​

Anatomy of Cassandra's Write Operation

A client just sent a write to Cassandra. Let's follow that write and see each part it touches on its way to disk.

Cassandra keeps every write in two places at once, on disk and in memory. That combination is what gives it both speed and durability. Every write also carries a timestamp. That timestamp is what lets Cassandra later tell which version of a value is the newest.

The write path has four steps:

  1. Each write is appended to a commit log on disk.
  2. It is then written to the MemTable in memory.
  3. Periodically, MemTables are flushed to disk as SSTables. 4

.....

.....

.....

Like the course? Get enrolled and start learning!
A

Amey Naik

· 5 years ago

"Commit log stores all the writes in sequential order, with each new write appended to the end, whereas MemTable stores data in the sorted order of partition key and clustering columns."

Show 1 reply

Reading Progress

0%


Vote for new content