Kùzu C++ API
Loading...
Searching...
No Matches
kuzu::main::SystemConfig Struct Reference

Stores runtime configuration for creating or opening a Database. More...

#include <database.h>

Public Member Functions

 SystemConfig (uint64_t bufferPoolSize=-1u, uint64_t maxNumThreads=0, bool enableCompression=true, bool readOnly=false, uint64_t maxDBSize=-1u, bool autoCheckpoint=true, uint64_t checkpointThreshold=16777216)
 Creates a SystemConfig object.
 

Public Attributes

uint64_t bufferPoolSize
 
uint64_t maxNumThreads
 
bool enableCompression
 
bool readOnly
 
uint64_t maxDBSize
 
bool autoCheckpoint
 
uint64_t checkpointThreshold
 

Detailed Description

Stores runtime configuration for creating or opening a Database.

Constructor & Destructor Documentation

◆ SystemConfig()

kuzu::main::SystemConfig::SystemConfig ( uint64_t bufferPoolSize = -1u,
uint64_t maxNumThreads = 0,
bool enableCompression = true,
bool readOnly = false,
uint64_t maxDBSize = -1u,
bool autoCheckpoint = true,
uint64_t checkpointThreshold = 16777216 )
explicit

Creates a SystemConfig object.

Parameters
bufferPoolSizeMax size of the buffer pool in bytes. The larger the buffer pool, the more data from the database files is kept in memory, reducing the amount of File I/O
maxNumThreadsThe maximum number of threads to use during query execution
enableCompressionWhether or not to compress data on-disk for supported types
readOnlyIf true, the database is opened read-only. No write transaction is allowed on the Database object. Multiple read-only Database objects can be created with the same database path. If false, the database is opened read-write. Under this mode, there must not be multiple Database objects created with the same database path.
maxDBSizeThe maximum size of the database in bytes. Note that this is introduced temporarily for now to get around with the default 8TB mmap address space limit some environment. This will be removed once we implemente a better solution later. The value is default to 1 << 43 (8TB) under 64-bit environment and 1GB under 32-bit one (see DEFAULT_VM_REGION_MAX_SIZE).
autoCheckpointIf true, the database will automatically checkpoint when the size of the WAL file exceeds the checkpoint threshold.
checkpointThresholdThe threshold of the WAL file size in bytes. When the size of the WAL file exceeds this threshold, the database will checkpoint if autoCheckpoint is true.

Member Data Documentation

◆ autoCheckpoint

bool kuzu::main::SystemConfig::autoCheckpoint

◆ bufferPoolSize

uint64_t kuzu::main::SystemConfig::bufferPoolSize

◆ checkpointThreshold

uint64_t kuzu::main::SystemConfig::checkpointThreshold

◆ enableCompression

bool kuzu::main::SystemConfig::enableCompression

◆ maxDBSize

uint64_t kuzu::main::SystemConfig::maxDBSize

◆ maxNumThreads

uint64_t kuzu::main::SystemConfig::maxNumThreads

◆ readOnly

bool kuzu::main::SystemConfig::readOnly

The documentation for this struct was generated from the following file: