mirror of
https://github.com/isar/libmdbx.git
synced 2024-10-30 11:29:19 +08:00
mdbx: alter defaults for MDBX_opt_rp_augment_limit
and MDBX_opt_txn_dp_limit
runtime options.
Change-Id: I08cdbfb18089a3fed4b32d931ca4423027a9939f
This commit is contained in:
parent
b1a2892038
commit
dc34041600
6
mdbx.h
6
mdbx.h
@ -1849,8 +1849,7 @@ enum MDBX_option_t {
|
|||||||
* growth, or/and to the inability of put long values.
|
* growth, or/and to the inability of put long values.
|
||||||
*
|
*
|
||||||
* The `MDBX_opt_rp_augment_limit` controls described limit for the current
|
* The `MDBX_opt_rp_augment_limit` controls described limit for the current
|
||||||
* process. Default is 1048576, i.e. 2**20. This is sure enough for databases
|
* process. Default is 262144, it is usually enough for most cases. */
|
||||||
* up to 4Gb with 4K page size. */
|
|
||||||
MDBX_opt_rp_augment_limit,
|
MDBX_opt_rp_augment_limit,
|
||||||
|
|
||||||
/** \brief Controls the in-process limit to grow a list of
|
/** \brief Controls the in-process limit to grow a list of
|
||||||
@ -1878,8 +1877,7 @@ enum MDBX_option_t {
|
|||||||
* spill to disk instead.
|
* spill to disk instead.
|
||||||
*
|
*
|
||||||
* The `MDBX_opt_txn_dp_limit` controls described threshold for the current
|
* The `MDBX_opt_txn_dp_limit` controls described threshold for the current
|
||||||
* process. Default is 1048576, i.e. 2**20. This is sure enough for databases
|
* process. Default is 65536, it is usually enough for most cases. */
|
||||||
* up to 4Gb with 4K page size. */
|
|
||||||
MDBX_opt_txn_dp_limit,
|
MDBX_opt_txn_dp_limit,
|
||||||
|
|
||||||
/** \brief Controls the in-process initial allocation size for dirty pages
|
/** \brief Controls the in-process initial allocation size for dirty pages
|
||||||
|
@ -9922,8 +9922,8 @@ __cold int mdbx_env_create(MDBX_env **penv) {
|
|||||||
env->me_stuck_meta = -1;
|
env->me_stuck_meta = -1;
|
||||||
|
|
||||||
env->me_options.dp_reserve_limit = 1024;
|
env->me_options.dp_reserve_limit = 1024;
|
||||||
env->me_options.rp_augment_limit = 1024 * 1024;
|
env->me_options.rp_augment_limit = 256 * 1024;
|
||||||
env->me_options.dp_limit = 1024 * 1024;
|
env->me_options.dp_limit = 64 * 1024;
|
||||||
if (env->me_options.dp_limit > MAX_PAGENO - NUM_METAS)
|
if (env->me_options.dp_limit > MAX_PAGENO - NUM_METAS)
|
||||||
env->me_options.dp_limit = MAX_PAGENO - NUM_METAS;
|
env->me_options.dp_limit = MAX_PAGENO - NUM_METAS;
|
||||||
env->me_options.dp_initial = MDBX_PNL_INITIAL;
|
env->me_options.dp_initial = MDBX_PNL_INITIAL;
|
||||||
|
Loading…
Reference in New Issue
Block a user