AcctIdx: env var "SOLANA_TEST_ACCOUNTS_INDEX_MEMORY_LIMIT_MB" (#23194)

* AcctIdx: env var "SOLANA_TEST_ACCOUNTS_INDEX_MEMORY_LIMIT_MB"

* ignore env var when starting as validator

* Update runtime/src/bucket_map_holder.rs

Co-authored-by: Trent Nelson <trent.a.b.nelson@gmail.com>

Co-authored-by: Trent Nelson <trent.a.b.nelson@gmail.com>
This commit is contained in:
Jeff Washington (jwash)
2022-02-22 09:40:12 -06:00
committed by GitHub
parent ac70070e5b
commit 7ebf398ed7
3 changed files with 23 additions and 9 deletions

View File

@@ -2117,7 +2117,10 @@ pub fn main() {
_ => unreachable!(),
};
let mut accounts_index_config = AccountsIndexConfig::default();
let mut accounts_index_config = AccountsIndexConfig {
started_from_validator: true, // this is the only place this is set
..AccountsIndexConfig::default()
};
if let Some(bins) = value_t!(matches, "accounts_index_bins", usize).ok() {
accounts_index_config.bins = Some(bins);
}