pub struct Batch {
pub position: Option<Position>,
pub changes: usize,
pub envelopes: Arc<[Envelope]>,
}Expand description
The envelopes one ingest commit built, in build order, with the position of the last change the batch covers. A live batch with no envelopes (every change resolved to nothing this sink indexes) still carries its position, so acknowledging it moves the watermark. A snapshot batch carries none.
The envelopes are shared, not owned: one build is published to every lane and held for redelivery without copying the documents, so a batch is immutable once built — a sink stamps nothing into it.
Fields§
§position: Option<Position>The position of the last change in the batch; None for snapshot rows.
changes: usizeHow many source changes the batch was built from, for progress
accounting; 0 for a snapshot batch.
envelopes: Arc<[Envelope]>The documents, in build order.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Batch
impl<'de> Deserialize<'de> for Batch
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for Batch
Auto Trait Implementations§
impl Forget for Batch
impl Freeze for Batch
impl RefUnwindSafe for Batch
impl Send for Batch
impl Sync for Batch
impl Unpin for Batch
impl UnsafeUnpin for Batch
impl UnwindSafe for Batch
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