datafusion_physical_plan/
lib.rs

1// Licensed to the Apache Software Foundation (ASF) under one
2// or more contributor license agreements.  See the NOTICE file
3// distributed with this work for additional information
4// regarding copyright ownership.  The ASF licenses this file
5// to you under the Apache License, Version 2.0 (the
6// "License"); you may not use this file except in compliance
7// with the License.  You may obtain a copy of the License at
8//
9//   http://www.apache.org/licenses/LICENSE-2.0
10//
11// Unless required by applicable law or agreed to in writing,
12// software distributed under the License is distributed on an
13// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14// KIND, either express or implied.  See the License for the
15// specific language governing permissions and limitations
16// under the License.
17
18#![doc(
19    html_logo_url = "https://raw.githubusercontent.com/apache/datafusion/19fe44cf2f30cbdd63d4a4f52c74055163c6cc38/docs/logos/standalone_logo/logo_original.svg",
20    html_favicon_url = "https://raw.githubusercontent.com/apache/datafusion/19fe44cf2f30cbdd63d4a4f52c74055163c6cc38/docs/logos/standalone_logo/logo_original.svg"
21)]
22#![cfg_attr(docsrs, feature(doc_cfg))]
23// Make sure fast / cheap clones on Arc are explicit:
24// https://github.com/apache/datafusion/issues/11143
25#![deny(clippy::clone_on_ref_ptr)]
26
27//! Traits for physical query plan, supporting parallel execution for partitioned relations.
28//!
29//! Entrypoint of this crate is trait [ExecutionPlan].
30
31pub use datafusion_common::hash_utils;
32pub use datafusion_common::utils::project_schema;
33pub use datafusion_common::{internal_err, ColumnStatistics, Statistics};
34pub use datafusion_execution::{RecordBatchStream, SendableRecordBatchStream};
35pub use datafusion_expr::{Accumulator, ColumnarValue};
36pub use datafusion_physical_expr::window::WindowExpr;
37use datafusion_physical_expr::PhysicalSortExpr;
38pub use datafusion_physical_expr::{
39    expressions, Distribution, Partitioning, PhysicalExpr,
40};
41
42pub use crate::display::{DefaultDisplay, DisplayAs, DisplayFormatType, VerboseDisplay};
43pub use crate::execution_plan::{
44    collect, collect_partitioned, displayable, execute_input_stream, execute_stream,
45    execute_stream_partitioned, get_plan_string, with_new_children_if_necessary,
46    ExecutionPlan, ExecutionPlanProperties, PlanProperties,
47};
48pub use crate::metrics::Metric;
49pub use crate::ordering::InputOrderMode;
50pub use crate::stream::EmptyRecordBatchStream;
51pub use crate::topk::TopK;
52pub use crate::visitor::{accept, visit_execution_plan, ExecutionPlanVisitor};
53pub use crate::work_table::WorkTable;
54pub use spill::spill_manager::SpillManager;
55
56mod ordering;
57mod render_tree;
58mod topk;
59mod visitor;
60
61pub mod aggregates;
62pub mod analyze;
63pub mod async_func;
64pub mod coalesce;
65pub mod coalesce_batches;
66pub mod coalesce_partitions;
67pub mod common;
68pub mod coop;
69pub mod display;
70pub mod empty;
71pub mod execution_plan;
72pub mod explain;
73pub mod filter;
74pub mod filter_pushdown;
75pub mod joins;
76pub mod limit;
77pub mod memory;
78pub mod metrics;
79pub mod placeholder_row;
80pub mod projection;
81pub mod recursive_query;
82pub mod repartition;
83pub mod sorts;
84pub mod spill;
85pub mod stream;
86pub mod streaming;
87pub mod tree_node;
88pub mod union;
89pub mod unnest;
90pub mod windows;
91pub mod work_table;
92pub mod udaf {
93    pub use datafusion_expr::StatisticsArgs;
94    pub use datafusion_physical_expr::aggregate::AggregateFunctionExpr;
95}
96
97pub mod test;