![]() |
MDBX Containers
|
Parameters used by Connection to create the MDBX environment. More...
#include <Config.hpp>
Public Member Functions | |
bool | validate () const |
Validate the MDBX configuration. | |
Public Attributes | |
std::string | pathname |
Path to the database file or directory containing the database. | |
int64_t | size_lower = -1 |
Lower bound for database size. | |
int64_t | size_now = -1 |
Current size of the database. | |
int64_t | size_upper = -1 |
Upper bound for database size. | |
int64_t | growth_step = 16 * 1024 * 1024 |
Step size for database growth. | |
int64_t | shrink_threshold = 16 * 1024 * 1024 |
Threshold for database shrinking. | |
int64_t | page_size = 0 |
Page size (must be a power of two). | |
int64_t | max_readers = 0 |
Maximum reader slots; use 0 for the default (twice the CPU count). | |
int64_t | max_dbs = 10 |
Maximum number of named databases (DBI) in the environment. | |
bool | read_only = false |
Whether to open the environment in read-only mode. | |
bool | readahead = true |
Whether to enable OS readahead for sequential access. | |
bool | no_subdir = true |
Whether to store the database in a single file instead of a directory. | |
bool | sync_durable = true |
Whether to enforce synchronous durable writes (MDBX_SYNC_DURABLE). | |
bool | writemap_mode = false |
Whether to map the database with MDBX_WRITEMAP for direct modification. | |
bool | relative_to_exe = false |
Whether to resolve a relative path relative to the executable directory. | |
Parameters used by Connection to create the MDBX environment.
Each option corresponds to an MDBX flag or setting. See Database Configuration for a detailed description of how these values influence the database.
Definition at line 17 of file Config.hpp.
|
inline |
Validate the MDBX configuration.
Definition at line 37 of file Config.hpp.
int64_t mdbxc::Config::growth_step = 16 * 1024 * 1024 |
Step size for database growth.
Definition at line 23 of file Config.hpp.
int64_t mdbxc::Config::max_dbs = 10 |
Maximum number of named databases (DBI) in the environment.
Definition at line 27 of file Config.hpp.
int64_t mdbxc::Config::max_readers = 0 |
Maximum reader slots; use 0 for the default (twice the CPU count).
Definition at line 26 of file Config.hpp.
bool mdbxc::Config::no_subdir = true |
Whether to store the database in a single file instead of a directory.
Definition at line 30 of file Config.hpp.
int64_t mdbxc::Config::page_size = 0 |
Page size (must be a power of two).
Definition at line 25 of file Config.hpp.
std::string mdbxc::Config::pathname |
Path to the database file or directory containing the database.
Definition at line 19 of file Config.hpp.
bool mdbxc::Config::read_only = false |
Whether to open the environment in read-only mode.
Definition at line 28 of file Config.hpp.
bool mdbxc::Config::readahead = true |
Whether to enable OS readahead for sequential access.
Definition at line 29 of file Config.hpp.
bool mdbxc::Config::relative_to_exe = false |
Whether to resolve a relative path relative to the executable directory.
Definition at line 33 of file Config.hpp.
int64_t mdbxc::Config::shrink_threshold = 16 * 1024 * 1024 |
Threshold for database shrinking.
Definition at line 24 of file Config.hpp.
int64_t mdbxc::Config::size_lower = -1 |
Lower bound for database size.
Definition at line 20 of file Config.hpp.
int64_t mdbxc::Config::size_now = -1 |
Current size of the database.
Definition at line 21 of file Config.hpp.
int64_t mdbxc::Config::size_upper = -1 |
Upper bound for database size.
Definition at line 22 of file Config.hpp.
bool mdbxc::Config::sync_durable = true |
Whether to enforce synchronous durable writes (MDBX_SYNC_DURABLE).
Definition at line 31 of file Config.hpp.
bool mdbxc::Config::writemap_mode = false |
Whether to map the database with MDBX_WRITEMAP for direct modification.
Definition at line 32 of file Config.hpp.