Announcing ScyllaDB 6.0 — True Elastic Scale | Learn More

ScyllaDB Shard-per-Core Architecture

icon-mono-shardpercore

ScyllaDB’s revolutionary new approach to NoSQL database architecture is optimized for modern cloud infrastructure

ScyllaDB was built from the ground up in C++ with the full knowledge and experience of how to take advantage of modern multicore, multi-processor NUMA server hardware and fundamental features of the Linux operating system, the cornerstones of modern cloud infrastructure. ScyllaDB is a massively parallelized database engine that runs sharded on each core in your server across all the servers in a cluster. Its design enables ScyllaDB to predictably scale to millions of operations per second, sustaining sub-millisecond average latencies – even with regional and global replication. In a ScyllaDB cluster, every node operates on a peer-to-peer basis, eliminating the primary/replica model that often leads to bottlenecks and single points of failure.

ScyllaDB cluster architecture diagram

The cluster is partitioned into a range of tokens, and the data associated with the partitions is then distributed as shards based on the RF factor across the nodes. The data shards within each node are then mapped to vCPUs that are bound to specific cores.

CPU Shard Per Core Dedicated Resources
Each Virtual CPU (vCPU) is bound to a CPU core with a shard of data and has its own dedicated resources, including a separate cache, memtables, and SSTables in its own RAM and persistent storage. It also has dedicated networking I/O channels for efficient communication and data transfer.
seastar-logo-31

Modern Shared-Nothing Architecture

Based on its underlying Seastar framework, ScyllaDB utilizes a highly asynchronous, shared-nothing design. In this design, each shard-per-core has dedicated resources and its own custom schedulers for CPU and I/O processing. Using the Seastar framework, ScyllaDB runs one application thread per core and relies on explicit message passing instead of shared memory between threads. This design helps to avoid slow, unscalable lock primitives and cache bounces.

Any sharing of resources across cores must be explicitly handled. For instance, when two requests belong to the same session and are processed by two different CPUs, and they both depend on the same session state, one CPU must explicitly forward the request to the other. Either CPU may handle any response. While Seastar provides features that reduce the need for cross-core communication, when communication is unavoidable, it offers high-performance, non-blocking communication primitives to ensure that performance is not degraded.

Shared Nothing Architecture Diagram
ScyllaDB University Mascot

ScyllaDB University

Get started on the path to ScyllaDB expertise

ScyllaDB Cloud Mascot

ScyllaDB Cloud

It’s easy to get started with our NoSQL DBaaS