pub struct TrieChunker<U: ColumnarUpdate> { /* private fields */ }Expand description
A chunker that unwraps RecordedUpdates into bare UpdatesTyped for the merge batcher.
The intended behavior is to produce chunks whose size is within 1-2x LINK_TARGET.
It ships large batches immediately, accumulates small batches, consolidates as they
exceed 2xLINK_TARGET, and ships them unless they drop below 1xLINK_TARGET.
The flow is into (or around) self.stage, then consolidated blocks into self.ready,
each of which is put in self.stage
Trait Implementations§
Source§impl<U: ColumnarUpdate> ContainerBuilder for TrieChunker<U>
impl<U: ColumnarUpdate> ContainerBuilder for TrieChunker<U>
Source§type Container = UpdatesTyped<U>
type Container = UpdatesTyped<U>
The container type we’re building.
Source§fn extract(&mut self) -> Option<&mut Self::Container>
fn extract(&mut self) -> Option<&mut Self::Container>
Extract assembled containers, potentially leaving unfinished data behind. Can
be called repeatedly, for example while the caller can send data. Read more
Source§impl<U: ColumnarUpdate> Default for TrieChunker<U>
impl<U: ColumnarUpdate> Default for TrieChunker<U>
Source§impl<'a, U: ColumnarUpdate> PushInto<&'a mut RecordedUpdates<U>> for TrieChunker<U>
impl<'a, U: ColumnarUpdate> PushInto<&'a mut RecordedUpdates<U>> for TrieChunker<U>
Source§fn push_into(&mut self, container: &'a mut RecordedUpdates<U>)
fn push_into(&mut self, container: &'a mut RecordedUpdates<U>)
Push item into self.
Auto Trait Implementations§
impl<U> Freeze for TrieChunker<U>where
<<U as ColumnarUpdate>::Key as Columnar>::Container: Freeze,
<<U as ColumnarUpdate>::Val as Columnar>::Container: Freeze,
<<U as ColumnarUpdate>::Time as Columnar>::Container: Freeze,
<<U as ColumnarUpdate>::Diff as Columnar>::Container: Freeze,
impl<U> RefUnwindSafe for TrieChunker<U>where
<<U as ColumnarUpdate>::Key as Columnar>::Container: RefUnwindSafe,
<<U as ColumnarUpdate>::Val as Columnar>::Container: RefUnwindSafe,
<<U as ColumnarUpdate>::Time as Columnar>::Container: RefUnwindSafe,
<<U as ColumnarUpdate>::Diff as Columnar>::Container: RefUnwindSafe,
impl<U> Send for TrieChunker<U>
impl<U> Sync for TrieChunker<U>where
<<U as ColumnarUpdate>::Key as Columnar>::Container: Sync,
<<U as ColumnarUpdate>::Val as Columnar>::Container: Sync,
<<U as ColumnarUpdate>::Time as Columnar>::Container: Sync,
<<U as ColumnarUpdate>::Diff as Columnar>::Container: Sync,
impl<U> Unpin for TrieChunker<U>where
<<U as ColumnarUpdate>::Key as Columnar>::Container: Unpin,
<<U as ColumnarUpdate>::Val as Columnar>::Container: Unpin,
<<U as ColumnarUpdate>::Time as Columnar>::Container: Unpin,
<<U as ColumnarUpdate>::Diff as Columnar>::Container: Unpin,
impl<U> UnsafeUnpin for TrieChunker<U>where
<<U as ColumnarUpdate>::Key as Columnar>::Container: UnsafeUnpin,
<<U as ColumnarUpdate>::Val as Columnar>::Container: UnsafeUnpin,
<<U as ColumnarUpdate>::Time as Columnar>::Container: UnsafeUnpin,
<<U as ColumnarUpdate>::Diff as Columnar>::Container: UnsafeUnpin,
impl<U> UnwindSafe for TrieChunker<U>where
<<U as ColumnarUpdate>::Key as Columnar>::Container: UnwindSafe,
<<U as ColumnarUpdate>::Val as Columnar>::Container: UnwindSafe,
<<U as ColumnarUpdate>::Time as Columnar>::Container: UnwindSafe,
<<U as ColumnarUpdate>::Diff as Columnar>::Container: UnwindSafe,
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> 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 moreSource§impl<'a, S, T> Semigroup<&'a S> for Twhere
T: Semigroup<S>,
impl<'a, S, T> Semigroup<&'a S> for Twhere
T: Semigroup<S>,
Source§fn plus_equals(&mut self, rhs: &&'a S)
fn plus_equals(&mut self, rhs: &&'a S)
The method of
std::ops::AddAssign, for types that do not implement AddAssign.