Skip to main content

Module query

Module query 

Source
Expand description

Streaming query lifecycle management.

StreamingQuery is the unified runtime object that wires compiled (or fallback) pipelines to their Ring 0 / Ring 1 bridges and tracks lifecycle state across the Ring 0 / Ring 1 boundary.

§Usage

let query = StreamingQueryBuilder::new("SELECT ts, val FROM stream WHERE val > 10")
    .add_pipeline(executable, bridge, consumer, schema)
    .build()?;
query.start()?;
query.submit_row(&row, event_time, key_hash)?;
let actions = query.poll_ring1();
query.stop()?;

Structs§

StreamingQuery
A running streaming query that connects compiled pipelines to Ring 1 via bridges.
StreamingQueryBuilder
Builder for constructing a StreamingQuery from pre-compiled components.