Skip to main content
Version: 0.16

Overview

Stalwart supports several database and object-storage backends. The choice of backend depends primarily on the scale and topology of the deployment.

The following table summarises which backend is available for each store type:

Data storeBlob storeSearch storeIn-memory store
RocksDB
FoundationDB
PostgreSQL
MySQL / MariaDB
SQLite
S3/MinIO
Azure Blob Storage
Filesystem
ElasticSearch
Meilisearch
Redis

Backend support is compiled into the Stalwart binary. Switching to backends such as FoundationDB therefore requires running a different binary built with the corresponding feature enabled.

Each store (data, blob, search, in-memory) is configured through its own singleton object: DataStore, BlobStore, SearchStore, and InMemoryStore. These objects are multi-variant: changing backend means selecting a different variant on the corresponding object, without restructuring the rest of the configuration.

Note

Changing the storage backend after initial setup requires data migration. All existing data on the previous backend must be transferred to the new backend, which can be time-consuming depending on the volume and type of data involved. It is therefore advisable to choose the appropriate backend at the start of the deployment.