Add snapshot hash of full accounts state (#8295) (#8515)

* Add snapshot hash of full accounts state

* Use normal hashing for the accounts delta state

* Add merkle

(cherry picked from commit 947a339714)

Co-authored-by: sakridge <sakridge@gmail.com>
This commit is contained in:
mergify[bot]
2020-02-27 17:36:28 -08:00
committed by GitHub
parent 9afd14a0c6
commit 7b23e79922
7 changed files with 298 additions and 279 deletions

View File

@@ -338,6 +338,7 @@ pub fn add_snapshot<P: AsRef<Path>>(
snapshot_storages: &[SnapshotStorage],
) -> Result<SlotSnapshotPaths> {
bank.purge_zero_lamport_accounts();
bank.update_accounts_hash();
let slot = bank.slot();
// snapshot_path/slot
let slot_snapshot_dir = get_bank_snapshot_dir(snapshot_path, slot);