flow/lib.rs
1// Copyright 2023 Greptime Team
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7// http://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14
15//! This crate manage dataflow in Greptime, including adapter, expr, plan, repr and utils.
16//! It can transform substrait plan into it's own plan and execute it.
17//! It also contains definition of expression, adapter and plan, and internal state management.
18
19#![allow(dead_code)]
20#![warn(clippy::too_many_lines)]
21
22// TODO(discord9): enable this lint to handle out of bound access
23// #![cfg_attr(not(test), warn(clippy::indexing_slicing))]
24
25// allow unused for now because it should be use later
26mod adapter;
27pub(crate) mod batching_mode;
28mod compute;
29mod df_optimizer;
30pub(crate) mod engine;
31pub mod error;
32mod expr;
33pub mod heartbeat;
34mod metrics;
35mod plan;
36mod repr;
37mod server;
38mod transform;
39mod utils;
40
41#[cfg(test)]
42mod test_utils;
43
44pub use adapter::flownode_impl::FlowDualEngineRef;
45pub use adapter::{FlowConfig, FlowStreamingEngineRef, StreamingEngine};
46pub use batching_mode::frontend_client::{FrontendClient, GrpcQueryHandlerWithBoxedError};
47pub use engine::FlowAuthHeader;
48pub(crate) use engine::{CreateFlowArgs, FlowId, TableName};
49pub use error::{Error, Result};
50pub use server::{
51 FlownodeBuilder, FlownodeInstance, FlownodeServer, FlownodeServiceBuilder, FrontendInvoker,
52 get_flow_auth_options,
53};
54
55pub use crate::adapter::FlownodeOptions;