What are SSTables?

What are SSTables and how are they used?

A Sorted Strings Table (SSTable) is a persistent file format of key-value string pairs that are sorted by the keys. They are used by Apache Cassandra, ScyllaDB, Bigtable, and some other NoSQL databases. SSTables are immutable, meaning they are never modified.

SSTables are a main building block for the way ScyllaDB writes data, which follows the well-known Log Structured Merge (LSM) design described by Patrick O’Neil.

Writes in ScyllaDB are very fast and are immediately available for reads. Data is written to a memory table (MemTable), and when that becomes too big, it is flushed to a new file. This file is sorted to make it easy to search and later merge. This is why the tables are known as Sorted String Tables or SSTables.

SSTables are merged into new SSTables or deleted in a process called Compaction.