Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 1 addition & 9 deletions native/core/src/execution/planner.rs
Original file line number Diff line number Diff line change
Expand Up @@ -146,15 +146,7 @@ pub struct PhysicalPlanner {

impl Default for PhysicalPlanner {
fn default() -> Self {
let session_ctx = Arc::new(SessionContext::new());

// register UDFs from datafusion-spark crate
session_ctx.register_udf(ScalarUDF::new_from_impl(SparkExpm1::default()));

Self {
exec_context_id: TEST_EXEC_CONTEXT_ID,
session_ctx,
}
Self::new(Arc::new(SessionContext::new()))
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note that Self::new will register the UDF:

    pub fn new(session_ctx: Arc<SessionContext>) -> Self {
        // register UDFs from datafusion-spark crate
        session_ctx.register_udf(ScalarUDF::new_from_impl(SparkExpm1::default()));
        Self {
            exec_context_id: TEST_EXEC_CONTEXT_ID,
            session_ctx,
        }
    }

}
}

Expand Down
Loading