All Questions
Scaling Writes hard

Why do Log-Structured Merge (LSM) Trees (used in Cassandra/RocksDB) offer significantly higher write throughput than B-Trees (used in PostgreSQL)?

  1. A They transform random database updates into sequential writes (Append-Only) in memory and on disk, deferring the expensive sorting/merging to a background process.
  2. B They do not use a transaction log.
  3. C They compress the data before writing.
  4. D B-Trees require locking the entire table for every insert.

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

Get the app

Related questions