Skip to content

Commit df3edf9

Browse files
authoredMar 5, 2025··
Reduce BucketListDB configs (#4661)
# Description Reduces `BUCKETLIST_DB_INDEX_CUTOFF` to 50 and disables account caching by default. During testing, I determined `BUCKETLIST_DB_INDEX_CUTOFF` to be a reasonable value wrt memory consumption. Unfortunately I was actually setting the default to 250 despite the comments and docs saying 100. While I think 100 is still fine, I've turned it down a bit more to be on the safe side and unblock the release. # Checklist - [x] Reviewed the [contributing](https://github.com/stellar/stellar-core/blob/master/CONTRIBUTING.md#submitting-changes) document - [x] Rebased on top of master (no merge commits) - [x] Ran `clang-format` v8.0.0 (via `make format` or the Visual Studio extension) - [x] Compiles - [x] Ran all tests - [ ] If change impacts performance, include supporting evidence per the [performance document](https://github.com/stellar/stellar-core/blob/master/performance-eval/performance-eval.md)
2 parents 025b02a + f8b22fe commit df3edf9

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed
 

‎docs/stellar-core_example.cfg

+4-4
Original file line numberDiff line numberDiff line change
@@ -235,20 +235,20 @@ MAX_DEX_TX_OPERATIONS_IN_TX_SET = 0
235235
# 0, indiviudal index is always used. Default page size 16 kb.
236236
BUCKETLIST_DB_INDEX_PAGE_SIZE_EXPONENT = 14
237237

238-
# BUCKETLIST_DB_MEMORY_FOR_CACHING (Integer) default 3000
238+
# BUCKETLIST_DB_MEMORY_FOR_CACHING (Integer) default 0
239239
# Memory used for caching entries by BucketListDB when Bucket size is
240240
# larger than BUCKETLIST_DB_INDEX_CUTOFF, in MB. Note that this value does
241241
# not impact Buckets smaller than BUCKETLIST_DB_INDEX_CUTOFF, as they are
242242
# always completely held in memory. If set to 0, caching is disabled.
243-
BUCKETLIST_DB_MEMORY_FOR_CACHING = 3000
243+
BUCKETLIST_DB_MEMORY_FOR_CACHING = 0
244244

245-
# BUCKETLIST_DB_INDEX_CUTOFF (Integer) default 100
245+
# BUCKETLIST_DB_INDEX_CUTOFF (Integer) default 20
246246
# Size, in MB, determining whether a bucket should have an individual
247247
# key index or a key range index. If bucket size is below this value, range
248248
# based index will be used. If set to 0, all buckets are range indexed. If
249249
# BUCKETLIST_DB_INDEX_PAGE_SIZE_EXPONENT == 0, value ignored and all
250250
# buckets have individual key index.
251-
BUCKETLIST_DB_INDEX_CUTOFF = 100
251+
BUCKETLIST_DB_INDEX_CUTOFF = 20
252252

253253
# BUCKETLIST_DB_PERSIST_INDEX (bool) default true
254254
# Determines whether BucketListDB indexes are saved to disk for faster

‎src/main/Config.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -161,8 +161,8 @@ Config::Config() : NODE_SEED(SecretKey::random())
161161
BACKGROUND_OVERLAY_PROCESSING = true;
162162
EXPERIMENTAL_PARALLEL_LEDGER_APPLY = false;
163163
BUCKETLIST_DB_INDEX_PAGE_SIZE_EXPONENT = 14; // 2^14 == 16 kb
164-
BUCKETLIST_DB_INDEX_CUTOFF = 250; // 250 mb
165-
BUCKETLIST_DB_MEMORY_FOR_CACHING = 3'000; // 3000 mb
164+
BUCKETLIST_DB_INDEX_CUTOFF = 20; // 20 mb
165+
BUCKETLIST_DB_MEMORY_FOR_CACHING = 0;
166166
BUCKETLIST_DB_PERSIST_INDEX = true;
167167
PUBLISH_TO_ARCHIVE_DELAY = std::chrono::seconds{0};
168168
// automatic maintenance settings:

0 commit comments

Comments
 (0)
Please sign in to comment.