ScyllaDB: Shard-per-Core Architecture and Low-Latency Engineering
Cassandra's data model on a C++ shared-nothing engine - where the shard, not the node, is the unit you reason about.
ScyllaDB is a reimplementation of Cassandra's data model and protocols in C++ on the **Seastar** framework, and the reason it exists is a specific architectural claim: that a database should not share state between CPU cores. Where Cassandra runs a thread pool over shared memory on the JVM, ScyllaDB runs **one shard per core**, each with its own slice of the data, its own memory, its own scheduler and its own event loop. Cores do not take locks against each other; they pass messages.
Overview
The CQL compatibility is genuine and it is also the thing to be careful about. The data model, the wire protocol, the drivers and most of the operational vocabulary carry over - so **this course assumes the Cassandra course and spends its time on what differs**. What differs: the architecture and its metrics, the tuning surface (ScyllaDB tunes itself far more aggressively and has fewer knobs you should touch), workload prioritisation, the Manager and Monitoring tooling, and the migration path - including the compatibility tests you must run before trusting "it is CQL-compatible" with production data.
Seven modules, about 85 hours. The capstone is a low-latency game event store with a p99 benchmark and a node failure drill.
Introduction
For a sandbox, `docker run --name scylla -d scylladb/scylla:6.0 --smp 2 --memory 2G --overprovisioned 1` works, and the flags matter. **`--overprovisioned 1` is essential in Docker or on a laptop**, because ScyllaDB's default assumption is that it owns the machine: it pins threads to cores, uses polling rather than interrupts, and will otherwise fight your other processes for CPU. `--smp` sets the number of shards. For the cluster laboratories, three nodes with `--smp 2` each.
Use **`cqlsh`** as before, and add two tools from the start: **`nodetool`** (the same commands, mostly) and the **ScyllaDB Monitoring Stack** (Prometheus and Grafana with ScyllaDB's own dashboards). That last one is not optional for this course - the per-shard dashboards are where most of the content in Module 4 becomes visible, and there is no substitute for seeing one shard's queue grow while the others idle.
One framing to carry through. In Cassandra you think about nodes. Here you think about **shards**, and almost every performance question becomes "which shard, and why that one?"
What you will be able to do
- Explain the Seastar shared-nothing model and the shard-per-core design
- State what ScyllaDB's CQL compatibility covers and where it stops
- Run and configure a cluster, including the flags that matter on shared hardware
- Design partition and clustering keys for bounded partitions, as in Cassandra
- Use TTL and collections, and state the costs
- Evaluate materialized views and secondary indexes honestly in this engine
- Choose consistency levels, and apply R + W > RF
- Use lightweight transactions, and state their cost here
- Configure shard-aware and token-aware routing, and verify it is working
- Explain per-shard metrics and why node averages mislead
- Diagnose a hot partition as a saturated shard rather than a saturated node
- Read latency histograms and reason about tail latency without GC pauses
- Choose a compaction strategy, and explain incremental compaction
- Use workload prioritisation to protect a latency-sensitive workload
- Configure replication, repair and multi-datacentre topology
- Use ScyllaDB Manager for scheduled repair and backup
- Replace a node, and record a measured RPO and RTO
- Implement roles, TLS and least privilege
- Run migration compatibility tests before trusting compatibility
- Produce a deployment, sizing and cost checklist
What each level covers
5 levels · 7 lessons
-
Beginner - Foundations
The shared-nothing engine and where compatibility stops; then the modelling that carries over and the view decisions that do not.
2 lessons 15 min of reading
Start with Seastar, Shards and the Compatibility Boundary → -
Intermediate - Application Behaviour
Consistency as in Cassandra, and the routing and retry behaviour that is specific here.
1 lesson 7 min of reading
Start with Consistency, LWT, Retries and Shard-Aware Routing → -
Advanced - Performance and Reliability
Per-shard performance engineering and workload prioritisation; then repair, backup and node replacement with the Manager.
2 lessons 14 min of reading
Start with Seastar Internals, Compaction, Cache and Shard Utilisation → -
Expert - Security and Production Architecture
Roles and TLS, monitoring that is per-shard, sizing, and the migration compatibility tests.
1 lesson 10 min of reading
Start with Roles, TLS, Monitoring, Sizing and Migration Testing → -
Capstone
One low-latency event store, defended on per-shard evidence, a measured p99 and a survived node loss.
1 lesson 3 min of reading
Start with Capstone - Low-Latency Game Event Store →
Guides and articles
Longer reading about this subject, written alongside the course.
Before you start
- ScyllaDB 6.0 or later, as a three-node cluster
- The Apache Cassandra course, as a prerequisite
- cqlsh, nodetool, and the ScyllaDB Monitoring Stack
- One programming language with a shard-aware driver
- The programme's shared foundations
Common questions
- What does the ScyllaDB: Shard-per-Core Architecture and Low-Latency Engineering course cover?
- It is 5 levels and 7 lessons: Beginner - Foundations; Intermediate - Application Behaviour; Advanced - Performance and Reliability; Expert - Security and Production Architecture; Capstone. Each level ends with a quiz, and the last one is an exam over the whole course.
- How long does it take?
- About 49 minutes of reading and exercises - roughly 0.8 hours. It is self-paced with no cohort and no start date, so you can leave and come back and the site remembers where you were.
- What do I need to know first?
- ScyllaDB 6.0 or later, as a three-node cluster. The Apache Cassandra course, as a prerequisite. cqlsh, nodetool, and the ScyllaDB Monitoring Stack. One programming language with a shard-aware driver. The programme's shared foundations.
- Is it free?
- Yes. Every lesson, example and quiz in this course is free to read, and you do not need an account to read them. Signing in only adds progress tracking and quiz results.
- What will I be able to do afterwards?
- Explain the Seastar shared-nothing model and the shard-per-core design. State what ScyllaDB's CQL compatibility covers and where it stops. Run and configure a cluster, including the flags that matter on shared hardware. Design partition and clustering keys for bounded partitions, as in Cassandra. Use TTL and collections, and state the costs. Evaluate materialized views and secondary indexes honestly in this engine. Choose consistency levels, and apply R + W > RF. Use lightweight transactions, and state their cost here. Configure shard-aware and token-aware routing, and verify it is working. Explain per-shard metrics and why node averages mislead. Diagnose a hot partition as a saturated shard rather than a saturated node. Read latency histograms and reason about tail latency without GC pauses. Choose a compaction strategy, and explain incremental compaction. Use workload prioritisation to protect a latency-sensitive workload. Configure replication, repair and multi-datacentre topology. Use ScyllaDB Manager for scheduled repair and backup. Replace a node, and record a measured RPO and RTO. Implement roles, TLS and least privilege. Run migration compatibility tests before trusting compatibility. Produce a deployment, sizing and cost checklist.