Add secondary indexes (#14212)
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
use crate::{
|
||||
accounts_index::AccountIndex,
|
||||
bank::{Bank, BankSlotDelta, Builtins},
|
||||
bank_forks::CompressionType,
|
||||
hardened_unpack::{unpack_snapshot, UnpackError},
|
||||
@@ -592,6 +593,7 @@ pub fn bank_from_archive<P: AsRef<Path>>(
|
||||
genesis_config: &GenesisConfig,
|
||||
debug_keys: Option<Arc<HashSet<Pubkey>>>,
|
||||
additional_builtins: Option<&Builtins>,
|
||||
account_indexes: HashSet<AccountIndex>,
|
||||
) -> Result<Bank> {
|
||||
// Untar the snapshot into a temporary directory
|
||||
let unpack_dir = tempfile::Builder::new()
|
||||
@@ -616,6 +618,7 @@ pub fn bank_from_archive<P: AsRef<Path>>(
|
||||
genesis_config,
|
||||
debug_keys,
|
||||
additional_builtins,
|
||||
account_indexes,
|
||||
)?;
|
||||
|
||||
if !bank.verify_snapshot_bank() {
|
||||
@@ -775,6 +778,7 @@ fn rebuild_bank_from_snapshots<P>(
|
||||
genesis_config: &GenesisConfig,
|
||||
debug_keys: Option<Arc<HashSet<Pubkey>>>,
|
||||
additional_builtins: Option<&Builtins>,
|
||||
account_indexes: HashSet<AccountIndex>,
|
||||
) -> Result<Bank>
|
||||
where
|
||||
P: AsRef<Path>,
|
||||
@@ -808,6 +812,7 @@ where
|
||||
frozen_account_pubkeys,
|
||||
debug_keys,
|
||||
additional_builtins,
|
||||
account_indexes,
|
||||
),
|
||||
}?)
|
||||
})?;
|
||||
|
Reference in New Issue
Block a user