ActorDB is a distributed relational SQL database, which is strongly consistent, massively concurrent, and horizontally scalable. It supports no single point of failure and uses no global read or write locks. To achieve the features provided, ActorDB uses Raft distributed consensus algorithm on top of an existing stable SQL database engine. ActorDB splits the dataset into small independent chunks, which is inspired by the "Actor Model". The database is designed for microservices, saas solutions, and (mobile) app backends.
Started with the project "Emit Cloud", which is a file synchronization application like Dropbox, the developers at Biokoda found problems in achieving no single point of failure and horizontal scalability. To solve the problem, developers at Biokoda extended SQLite's WAL format to implement Raft consensus algorighm. In the later versions, LMDB is used as the storage engine for ActorDB. ActorDB was first launched in 2014.
Using LMDB as the storage engine, ActorDB stores pages in an append-only style. It replaces SQLite's WAL implementation, and checkpoints are replaced with cleanups that free up space.
Pages are compressed in ActorDB using LZ4, which is a general-purpose algorithm.
Multi-version Concurrency Control (MVCC) Not Supported
Although ActorDB is concurrent on the database level, it is not on each actor. The storage engine LMDB employs MVCC.
ActorDB is a distributed relational database. But it also supports the scalability of a Key-Value(KV) store by introducing a KV data type, which is a SQL table that is partitioned across all servers.
Foreign keys are enabled by default in ActorDB.
ActorDB uses SQLite as the query engine, which uses B-Tree for its default indexing data structure.
Every actor is an SQLite database, where all transactions are serializable.
Each actor runs SQLite as the query engine, which uses Nested Loop Join.
ActorDB uses Raft protocol to replicate actors. The protocol is extended on SQLite WAL module and requires a write log to operate.
ActorDB uses SQLite as its query engine, which uses Volcano-style query processing.
ActorDB doesn't need any special drivers, as developers can use MySQL driver of the language of choice. ActorDB is connectable over the MySQL protocol. It is also connectable to the thrift interface, which supports languages including C++, Java, Python, PHP, Ruby, Erlang, Perl, Haskell, C#, and so on.
ActorDB uses LMDB as its storage engine. Each actor is stored within an LMDB file. LMDB uses mmap to achieve in memory storage.
As the storage engine being used, LMDB uses a memory-map to store the database with copy-on-write semantics, hence no specific storage model.
ActorDB has clusters that have 1, 3, or 5 nodes, each of which contains ~4 shards. The nodes act as independent actors who share no common memory or storage.