#[non_exhaustive]pub struct BatchOutcome {
pub accepted: Vec<bool>,
}Expand description
Per-record outcomes for a push_batch.
accepted[i] is true when record i is durable at the requested tier.
A cleared bit does not mean the record was never written. It means not durable as of this reply — retry it, and expect it may nonetheless have been committed, because weir is at-least-once. A set bit inherits the crown invariant and is the strong statement; a cleared bit is the weak one.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.accepted: Vec<bool>One entry per record, in the order they were sent.
Implementations§
Source§impl BatchOutcome
impl BatchOutcome
Sourcepub fn all_accepted(&self) -> bool
pub fn all_accepted(&self) -> bool
Whether every record in the batch is durable.
Sourcepub fn rejected_indices(&self) -> Vec<usize>
pub fn rejected_indices(&self) -> Vec<usize>
Indices of the records that are not durable, in order — the set to retry.
Trait Implementations§
Source§impl Clone for BatchOutcome
impl Clone for BatchOutcome
Source§fn clone(&self) -> BatchOutcome
fn clone(&self) -> BatchOutcome
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for BatchOutcome
impl Debug for BatchOutcome
impl Eq for BatchOutcome
Source§impl PartialEq for BatchOutcome
impl PartialEq for BatchOutcome
impl StructuralPartialEq for BatchOutcome
Auto Trait Implementations§
impl Freeze for BatchOutcome
impl RefUnwindSafe for BatchOutcome
impl Send for BatchOutcome
impl Sync for BatchOutcome
impl Unpin for BatchOutcome
impl UnsafeUnpin for BatchOutcome
impl UnwindSafe for BatchOutcome
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