summaryrefslogtreecommitdiffstats
path: root/storage
diff options
context:
space:
mode:
authorTor Brede Vekterli <vekterli@verizonmedia.com>2020-09-04 15:56:36 +0000
committerTor Brede Vekterli <vekterli@verizonmedia.com>2020-09-04 15:57:34 +0000
commit248e1a26010de03a51e1662015899dd1554d163f (patch)
treed603040c5d1fd4f415a1eaae3600a507a73577a0 /storage
parentca28ce90eaf1c4f247ce70533bb5937bce8755a6 (diff)
Reintroduce DataStore ctor taking explicit min_arrays argument
Lets caller specify a reasonable minimum array count without needing to create an explicit buffer. Use explicit `min_arrays=1024` for content node bucket DB `DataStore`. Reduces default memory footprint of an empty (or sparsely populated) content node bucket DB with a factor of more than 1200x.
Diffstat (limited to 'storage')
-rw-r--r--storage/src/vespa/storage/bucketdb/btree_lockable_map.hpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/storage/src/vespa/storage/bucketdb/btree_lockable_map.hpp b/storage/src/vespa/storage/bucketdb/btree_lockable_map.hpp
index f859897ef11..c14afce1a7a 100644
--- a/storage/src/vespa/storage/bucketdb/btree_lockable_map.hpp
+++ b/storage/src/vespa/storage/bucketdb/btree_lockable_map.hpp
@@ -59,7 +59,7 @@ struct BTreeLockableMap<T>::ValueTraits {
template <typename T>
BTreeLockableMap<T>::BTreeLockableMap()
- : _impl(std::make_unique<GenericBTreeBucketDatabase<ValueTraits>>())
+ : _impl(std::make_unique<GenericBTreeBucketDatabase<ValueTraits>>(1024/*data store array count*/))
{}
template <typename T>