AccountsIndexStorage holds InMemAccountsIndex[] (#19947)
This commit is contained in:
committed by
GitHub
parent
49d3d79459
commit
66e0fafc21
@@ -1,7 +1,6 @@
|
||||
use crate::accounts_index::{
|
||||
AccountMapEntry, AccountMapEntryInner, IndexValue, SlotList, WriteAccountMapEntry,
|
||||
};
|
||||
use crate::accounts_index_storage::AccountsIndexStorage;
|
||||
use crate::bucket_map_holder::BucketMapHolder;
|
||||
use crate::bucket_map_holder_stats::BucketMapHolderStats;
|
||||
use solana_measure::measure::Measure;
|
||||
@@ -29,10 +28,10 @@ impl<T: IndexValue> Debug for InMemAccountsIndex<T> {
|
||||
}
|
||||
|
||||
impl<T: IndexValue> InMemAccountsIndex<T> {
|
||||
pub fn new(storage: &AccountsIndexStorage<T>, bin: usize) -> Self {
|
||||
pub fn new(storage: &Arc<BucketMapHolder<T>>, bin: usize) -> Self {
|
||||
Self {
|
||||
map_internal: RwLock::default(),
|
||||
storage: storage.storage().clone(),
|
||||
storage: Arc::clone(storage),
|
||||
bin,
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user