pub struct StreamingPlanner { /* private fields */ }Expand description
Streaming query planner
Implementations§
Source§impl StreamingPlanner
impl StreamingPlanner
Sourcepub fn plan(
&mut self,
statement: &StreamingStatement,
) -> Result<StreamingPlan, PlanningError>
pub fn plan( &mut self, statement: &StreamingStatement, ) -> Result<StreamingPlan, PlanningError>
Sourcepub fn plan_state_backed_join(
&mut self,
statement: &StreamingStatement,
admission: &StateBackedJoinAdmission,
) -> Result<StreamingPlan, PlanningError>
pub fn plan_state_backed_join( &mut self, statement: &StreamingStatement, admission: &StateBackedJoinAdmission, ) -> Result<StreamingPlan, PlanningError>
Plan one query whose unbounded join shape has already been certified by the database as a durable state-backed incremental join.
This does not relax multi-way, join-type, temporal, or implicit-join
validation. Raw stream callers must use Self::plan.
§Errors
Returns PlanningError if the statement fails the remaining streaming checks.
Sourcepub fn unregister_query(&mut self, name: &str)
pub fn unregister_query(&mut self, name: &str)
Remove query classification installed by a successful plan when the surrounding catalog transaction is rolled back or the query is dropped.
Sourcepub fn has_query(&self, name: &str) -> bool
pub fn has_query(&self, name: &str) -> bool
Whether query classification state remains for a catalog object.
Sourcepub fn unregister_source(&mut self, name: &str)
pub fn unregister_source(&mut self, name: &str)
Remove a source installed by a catalog transaction that was dropped or rolled back.
Sourcepub fn unregister_sink(&mut self, name: &str)
pub fn unregister_sink(&mut self, name: &str)
Remove a sink installed by a catalog transaction that was dropped or rolled back.
Sourcepub fn unregister_lookup_table(&mut self, name: &str)
pub fn unregister_lookup_table(&mut self, name: &str)
Remove a lookup table installed by a catalog transaction that was dropped or rolled back.
Sourcepub fn get_source(&self, name: &str) -> Option<&SourceInfo>
pub fn get_source(&self, name: &str) -> Option<&SourceInfo>
Gets a registered source by name.
Sourcepub fn list_sources(&self) -> Vec<&SourceInfo>
pub fn list_sources(&self) -> Vec<&SourceInfo>
Lists all registered sources.
Sourcepub fn list_sinks(&self) -> Vec<&SinkInfo>
pub fn list_sinks(&self) -> Vec<&SinkInfo>
Lists all registered sinks.
Sourcepub fn get_lookup_table(&self, name: &str) -> Option<&LookupTableInfo>
pub fn get_lookup_table(&self, name: &str) -> Option<&LookupTableInfo>
Gets a registered lookup table by name.
Sourcepub fn list_lookup_tables(&self) -> Vec<&LookupTableInfo>
pub fn list_lookup_tables(&self) -> Vec<&LookupTableInfo>
Lists all registered lookup tables.
Sourcepub fn lookup_tables_cloned(&self) -> HashMap<String, LookupTableInfo>
pub fn lookup_tables_cloned(&self) -> HashMap<String, LookupTableInfo>
Returns a clone of the lookup tables map for optimizer rule construction.
Sourcepub async fn to_logical_plan(
&self,
plan: &QueryPlan,
ctx: &SessionContext,
) -> Result<LogicalPlan, PlanningError>
pub async fn to_logical_plan( &self, plan: &QueryPlan, ctx: &SessionContext, ) -> Result<LogicalPlan, PlanningError>
Converts a query plan’s SQL statement into a DataFusion
LogicalPlan. Window UDFs (TUMBLE, HOP, SESSION) must be registered
on ctx via
register_streaming_functions
for windowed queries to resolve correctly.
§Errors
Returns PlanningError if DataFusion cannot create the logical plan.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for StreamingPlanner
impl RefUnwindSafe for StreamingPlanner
impl Send for StreamingPlanner
impl Sync for StreamingPlanner
impl Unpin for StreamingPlanner
impl UnsafeUnpin for StreamingPlanner
impl UnwindSafe for StreamingPlanner
Blanket Implementations§
impl<T> Allocation for T
§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
§type ArchivedMetadata = ()
type ArchivedMetadata = ()
§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata,
) -> <T as Pointee>::Metadata
fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata
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<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request§impl<L> LayerExt<L> for L
impl<L> LayerExt<L> for L
§fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
Layered].