Skip to main content

TemporalBucketing

Trait TemporalBucketing 

Source
pub trait TemporalBucketing<'scope, T: Timestamp>: Sized {
    // Required method
    fn bucket(self, as_of: Antichain<T>, threshold: T::Summary) -> Self;
}
Expand description

Sort outstanding updates into a BucketChain, and reveal data not in advance of the input frontier. Retains a capability at the last input frontier to retain the right to produce data at times between the last input frontier and the current input frontier.

Required Methods§

Source

fn bucket(self, as_of: Antichain<T>, threshold: T::Summary) -> Self

Construct a new stream that stores updates into a BucketChain and reveals data not in advance of the frontier. Data that is within threshold distance of the input frontier or the as_of is passed through without being stored in the chain.

The output container matches the input’s, so a caller keeps whichever representation it had.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl<'scope, T, D> TemporalBucketing<'scope, T> for Stream<'scope, T, Column<(D, T, Diff)>>
where T: Timestamp + Default + ExchangeData + MzData + BucketTimestamp + TotalOrder + Lattice, for<'a> Ref<'a, T>: Copy + Ord, D: ExchangeData + MzData + Ord + Clone + Debug + Hashable, for<'a> Ref<'a, D>: Copy + Ord + Hash, for<'a> Ref<'a, Diff>: Ord, for<'a> <(D, T, Diff) as Columnar>::Container: Push<Ref<'a, (D, T, Diff)>>,

Implementation for streams in scopes where timestamps define a total order.

Source§

fn bucket(self, as_of: Antichain<T>, threshold: T::Summary) -> Self

Source§

impl<'scope, T, D> TemporalBucketing<'scope, T> for StreamVec<'scope, T, (D, T, Diff)>
where T: Timestamp + Default + ExchangeData + MzData + BucketTimestamp + TotalOrder + Lattice, D: ExchangeData + MzData + Ord + Clone + Debug + Hashable, for<'a> <(D, T, Diff) as Columnar>::Container: Push<&'a (D, T, Diff)>,

Implementation for Vec streams in scopes where timestamps define a total order.

A caller whose consumer wants owned records keeps a Vec-native operator, because staging the whole stream through a column would copy every pass-through record and allocate it again on the way out. Only records that enter the chain are encoded, which they were anyway: the chain’s batcher is columnar. The reduce key-value path is the one such caller, and this implementation goes away once its consumer reads columns.

Source§

fn bucket(self, as_of: Antichain<T>, threshold: T::Summary) -> Self

Implementors§