-- get a list of all configuration and runtime variables
SHOW CONFIG
{
"version": "0.0",
"uuid": "867638f7-380e-f20f-029f-51df1ff5b9c5",
"directory": "./storage",
"log": true,
"log_to_file": true,
"log_to_stdout": false,
"mm_page_size": 2097152,
"mm_limit": false,
"mm_limit_wm": 8589934592,
"mm_limit_behaviour": "block",
"mm_cache": 8589934592,
"wal": true,
"wal_rotate_wm": 104857600,
"wal_sync_on_rotate": true,
"wal_sync_on_write": false,
"wal_crc": false,
"serial": true,
"interval": 3000000,
"compression": "zstd",
"compression_level": 0,
"workers": 3,
"workers_upload": 1,
"ssn": 0,
"lsn": 0
}
-- change partitioning interval
SET interval TO 3000000
-- change number of background workers
SET workers TO 4
-- disable WAL
SET wal TO false
Some essential configuration options must be considered after environment creation creation and before creating or openning a repository.
Please take a look at the SHOW CONFIG and SET commands.
Instance UUID #
- uuid
string
Set UUID.
By default, the UUID is generated upon creation. In some cases, it might be useful to set it to a predefined value.
UUID can be changed only before the first opening.
See also CREATE STORAGE.
Serial Mode #
- serial
bool
Serial mode allows the assignment of event IDs automatically when written in an auto-increment way.
It is enabled by default.
The current serial state is stored inside the ssn variable, which can be changed.
Each new event id will be assigned as ssn + 1. The serial state is persistent.
The event ID must be set to UINT64_MAX on write.
Partitioning Interval #
- interval
int
Set partitioning interval value.
Each partition has inclusive min/max interval.
This metric sets the partition range per each new partition as:
partition min + interval - 1.
It can be changed during runtime.
See also CREATE PARTITIONS.
Write-Ahead Log #
Options to control WAL behavior.
WAL significantly affects performance and write-amplification in exchange for the per-operation durability.
Disabling WAL and relying only on automatic (or manual) per-partition durability might be a reasonable option.
-
wal
bool -
wal_rotate_wm
intThe number of operations per WAL file. When the current WAL file reaches this value, a new file will be created.
-
wal_sync_on_rotate
boolSync the previous WAL file when a new one is created (
enabled by default). -
wal_sync_on_write
boolSync the current WAL file on each write (
disabled by default). -
wal_crc
boolCalculate and validate crc for each transaction (
disabled by default).
Default Compression #
-
compression
stringDefault compression type for CREATE STORAGE and the
mainstorage.Supported values are:
none,zstd,lz4(set to zstd by default). -
compression_level
intDefault compression level depending on the compression type.
Background Workers #
- workers
int
Set the number of background workers. It can be changed only before opening.
It can be set to zero for complete manual control and deterministic testing.
Workers share the workload.
- workers_upload
int
Set the number of background workers for upload only. It can be changed only before opening.
If set to zero, regular workers will do the upload.
Enabling upload workers to access the cloud is highly recommended.
Running separate upload workers might be necessary in case of a slow network or big partitions. Workers might stall, which would lead to excessive memory consumption.
If cloud is not used, can be set to zero.
Log file #
Log messages and errors.
-
log
bool -
log_to_file
stringCreate and write a log file inside the base directory (
enabled by default). -
log_to_stdout
boolDuplicate messages from the log file to stdout (
disabled by default).
Memory Manager #
-
mm_limit
boolTurn the memory limit on or off (
disabled by default). -
mm_limit_wm
intMemory limit watermark value.
-
mm_limit_behaviour
stringBehavior for memory limit reach. Supported values are
block,error. -
mm_page_size
intSize of a single memory page.
-
mm_cache
intSize of a free page cache. Can be set to zero.