Hash stored accounts in bg (#16157)
* lazy calculate account hash * push to bg thread * remove deadlock * logs * format * some cleanup on aisle 9 * format, fix up some metrics * fix test, remove legacy function only there for tests * cleanup * remove unused store_hasher * Switch to crossbeam * clippy * format * use iter() * rework from feedback * hash_slot -> slot * hash(cluster_type) Co-authored-by: Carl Lin <carl@solana.com>
This commit is contained in:
committed by
GitHub
parent
6f3926b643
commit
f374b35944
@@ -187,6 +187,7 @@ pub fn package_snapshot<P: AsRef<Path>, Q: AsRef<Path>>(
|
||||
snapshot_package_output_path.as_ref().to_path_buf(),
|
||||
bank.capitalization(),
|
||||
hash_for_testing,
|
||||
bank.cluster_type(),
|
||||
);
|
||||
|
||||
Ok(package)
|
||||
@@ -978,6 +979,7 @@ pub fn process_accounts_package_pre(
|
||||
let (hash, lamports) = AccountsDb::calculate_accounts_hash_without_index(
|
||||
&accounts_package.storages,
|
||||
thread_pool,
|
||||
accounts_package.cluster_type,
|
||||
);
|
||||
|
||||
assert_eq!(accounts_package.expected_capitalization, lamports);
|
||||
|
Reference in New Issue
Block a user