Skip to content

Commit f09fb08

Browse files
committed
symbolize join approach
1 parent cd170a9 commit f09fb08

File tree

6 files changed

+1123
-385
lines changed

6 files changed

+1123
-385
lines changed

datafusion-cli/src/main.rs

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,11 @@ use datafusion_cli::{
3838

3939
use clap::Parser;
4040
use datafusion::catalog::CatalogProviderList;
41-
use datafusion::execution::SessionStateBuilder;
42-
use datafusion_cli::symbolize::{SymbolizeOptimizerRule, SymbolizeQueryPlanner};
41+
use datafusion::execution::{FunctionRegistry, SessionStateBuilder};
42+
use datafusion_cli::symbolize::logical::{
43+
SymbolizeMarkerOptimizerRule, SymbolizeQueryPlanner,
44+
};
45+
use datafusion_cli::symbolize::udf::register_symbolize_udf;
4346
use mimalloc::MiMalloc;
4447

4548
#[global_allocator]
@@ -178,12 +181,12 @@ async fn main_inner() -> Result<()> {
178181
.with_runtime_env(runtime_env)
179182
.with_default_features()
180183
.with_query_planner(Arc::new(SymbolizeQueryPlanner {}))
181-
.with_optimizer_rule(Arc::new(SymbolizeOptimizerRule {}))
184+
.with_optimizer_rule(Arc::new(SymbolizeMarkerOptimizerRule {}))
182185
.build();
183186
let ctx = SessionContext::new_with_state(state).enable_url_table();
184187
ctx.refresh_catalogs().await?;
188+
register_symbolize_udf(&ctx);
185189
// install dynamic catalog provider that can register required object stores
186-
println!("catalog list {:?}", ctx.state().catalog_list());
187190
let dynamic_catalog = Arc::new(DynamicObjectStoreCatalog::new(
188191
ctx.state().catalog_list().clone(),
189192
ctx.state_weak_ref(),

0 commit comments

Comments
 (0)