pub struct AccountsIndexStorage<T: IndexValue> {
pub storage: Arc<BucketMapHolder<T>>,
pub in_mem: Vec<Arc<InMemAccountsIndex<T>>>,
/* private fields */
}
Expand description
Manages the lifetime of the background processing threads.
Fields§
§storage: Arc<BucketMapHolder<T>>
§in_mem: Vec<Arc<InMemAccountsIndex<T>>>
Implementations§
Source§impl<T: IndexValue> AccountsIndexStorage<T>
impl<T: IndexValue> AccountsIndexStorage<T>
Sourcepub fn set_startup(&self, startup: Startup)
pub fn set_startup(&self, startup: Startup)
startup=true causes: in mem to act in a way that flushes to disk asap also creates some additional bg threads to facilitate flushing to disk asap startup=false is ‘normal’ operation
Sourcepub fn get_startup_remaining_items_to_flush_estimate(&self) -> usize
pub fn get_startup_remaining_items_to_flush_estimate(&self) -> usize
estimate how many items are still needing to be flushed to the disk cache.
Sourcepub fn new(bins: usize, config: &Option<AccountsIndexConfig>) -> Self
pub fn new(bins: usize, config: &Option<AccountsIndexConfig>) -> Self
allocate BucketMapHolder and InMemAccountsIndex[]
Trait Implementations§
Auto Trait Implementations§
impl<T> !Freeze for AccountsIndexStorage<T>
impl<T> !RefUnwindSafe for AccountsIndexStorage<T>
impl<T> Send for AccountsIndexStorage<T>
impl<T> Sync for AccountsIndexStorage<T>
impl<T> Unpin for AccountsIndexStorage<T>
impl<T> !UnwindSafe for AccountsIndexStorage<T>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more