Module solana_runtime::serde_snapshot

source ·

Structs§

  • Incremental snapshots only calculate their accounts hash based on the account changes WITHIN the incremental slot range. So, we need to keep track of the full snapshot expected accounts hash results. We also need to keep track of the hash and capitalization specific to the incremental snapshot slot range. The capitalization we calculate for the incremental slot will NOT be consistent with the bank’s capitalization. It is not feasible to calculate a capitalization delta that is correct given just incremental slots account data and the full snapshot’s capitalization.
  • Helper type to wrap AccountsDbFields when reconstructing AccountsDb from either just a full snapshot, or both a full and incremental snapshot
  • Helper type to wrap BankFields when reconstructing Bank from either just a full snapshot, or both a full and incremental snapshot
  • Helper type to wrap BufReader streams when deserializing and reconstructing from either just a full snapshot, or both a full and incremental snapshot

Functions§

  • effectively updates the accounts hash in the serialized bank file on disk read serialized bank from pre file update accounts_hash write serialized bank to post file return true if pre file found