Struct mz_storage::controller::persist_write_handles::PersistWorker
source · [−]pub struct PersistWorker<T: Timestamp + Lattice + Codec64 + TimestampManipulation> {
tx: UnboundedSender<(Span, PersistWorkerCmd<T>)>,
}
Fields
tx: UnboundedSender<(Span, PersistWorkerCmd<T>)>
Implementations
sourceimpl<T: Timestamp + Lattice + Codec64 + TimestampManipulation> PersistWorker<T>
impl<T: Timestamp + Lattice + Codec64 + TimestampManipulation> PersistWorker<T>
pub(crate) fn new(
frontier_responses: UnboundedSender<StorageResponse<T>>
) -> Self
pub(crate) fn register(
&self,
id: GlobalId,
write_handle: WriteHandle<SourceData, (), T, Diff>
)
pub(crate) fn append(
&self,
updates: Vec<(GlobalId, Vec<Update<T>>, T)>
) -> Receiver<Result<(), StorageError>>
sourcepub(crate) fn monotonic_append(
&self,
updates: Vec<(GlobalId, Vec<TimestamplessUpdate>, T)>
) -> Receiver<Result<(), StorageError>>
pub(crate) fn monotonic_append(
&self,
updates: Vec<(GlobalId, Vec<TimestamplessUpdate>, T)>
) -> Receiver<Result<(), StorageError>>
Appends values to collections associated with GlobalId
, but lets
the persist worker chose timestamps guaranteed to be monotonic and
that the time will be at least T
.
This lets the writer influence how far forward the timestamp will be advanced, while still guaranteeing that it will advance.
Note it is still possible for the append operation to fail in the face of contention from other writers.
Panics
-
If appending non-empty
TimelessUpdate
to closed collections (i.e. those with empty uppers), whose uppers cannot be monotonically increased.Collections with empty uppers can continue receiving empty updates, i.e. those used soley to advance collections’ uppers.
fn send(&self, cmd: PersistWorkerCmd<T>)
Trait Implementations
sourceimpl<T: Clone + Timestamp + Lattice + Codec64 + TimestampManipulation> Clone for PersistWorker<T>
impl<T: Clone + Timestamp + Lattice + Codec64 + TimestampManipulation> Clone for PersistWorker<T>
sourcefn clone(&self) -> PersistWorker<T>
fn clone(&self) -> PersistWorker<T>
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresourceimpl<T: Debug + Timestamp + Lattice + Codec64 + TimestampManipulation> Debug for PersistWorker<T>
impl<T: Debug + Timestamp + Lattice + Codec64 + TimestampManipulation> Debug for PersistWorker<T>
sourceimpl<T> Drop for PersistWorker<T>where
T: Timestamp + Lattice + Codec64 + TimestampManipulation,
impl<T> Drop for PersistWorker<T>where
T: Timestamp + Lattice + Codec64 + TimestampManipulation,
Auto Trait Implementations
impl<T> !RefUnwindSafe for PersistWorker<T>
impl<T> Send for PersistWorker<T>
impl<T> Sync for PersistWorker<T>
impl<T> Unpin for PersistWorker<T>
impl<T> !UnwindSafe for PersistWorker<T>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> FutureExt for T
impl<T> FutureExt for T
sourcefn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
sourcefn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
sourceimpl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
sourcefn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request
sourceimpl<T> Pointable for T
impl<T> Pointable for T
sourceimpl<T> ProgressEventTimestamp for Twhere
T: Data + Debug + Any,
impl<T> ProgressEventTimestamp for Twhere
T: Data + Debug + Any,
sourceimpl<P, R> ProtoType<R> for Pwhere
R: RustType<P>,
impl<P, R> ProtoType<R> for Pwhere
R: RustType<P>,
sourcefn into_rust(self) -> Result<R, TryFromProtoError>
fn into_rust(self) -> Result<R, TryFromProtoError>
See
RustType::from_proto
.sourcefn from_rust(rust: &R) -> P
fn from_rust(rust: &R) -> P
See
RustType::into_proto
.