pub struct BuildReport {
pub tables_mapped: Vec<String>,
pub tables_empty: Vec<String>,
pub rows_read: usize,
pub vertices: usize,
pub edges: usize,
}Expand description
What a build_mutation run actually read.
build_mutation skips a spec table the source does not carry, which is the right
default (a partial source yields a partial-but-consistent graph) and is also
exactly how an empty graph comes back looking like a successful build: point
the source at the wrong namespace and every table is “skipped”, the mutation is
empty, and the call returns Ok.
This report is the discrimination. It is carried BESIDE the mutation rather than folded into it, because the mutation is what a sink MERGEs and a report is not.
Fields§
§tables_mapped: Vec<String>Spec tables the source carried rows for, in spec order.
tables_empty: Vec<String>Spec tables the source carried NO rows for — absent, or present with zero rows. These are the ones that silently vanish from an unreported build.
rows_read: usizeTotal input rows read across every mapped table.
vertices: usizeVertex rows in the resulting mutation.
edges: usizeEdge rows in the resulting mutation.
Implementations§
Source§impl BuildReport
impl BuildReport
Sourcepub fn require_non_empty(self) -> Result<Self>
pub fn require_non_empty(self) -> Result<Self>
The honest one-liner a caller uses instead of trusting Ok.
Ok(self) when at least one spec table contributed rows AND the mutation is
non-empty; otherwise a typed crate::error::BifrostError::Source naming
every table that came back empty. A build that mapped nothing is not a graph.
Trait Implementations§
Source§impl Clone for BuildReport
impl Clone for BuildReport
Source§impl Debug for BuildReport
impl Debug for BuildReport
Source§impl Default for BuildReport
impl Default for BuildReport
impl Eq for BuildReport
Source§impl PartialEq for BuildReport
impl PartialEq for BuildReport
impl StructuralPartialEq for BuildReport
Auto Trait Implementations§
impl Freeze for BuildReport
impl RefUnwindSafe for BuildReport
impl Send for BuildReport
impl Sync for BuildReport
impl Unpin for BuildReport
impl UnsafeUnpin for BuildReport
impl UnwindSafe for BuildReport
Blanket Implementations§
impl<T> Allocation for T
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.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> ⓘ
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> ⓘ
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