The current Analyzer::execute_and_check API requires cloning a LogicalPlan
What changes are included in this PR?
Change Analyzer::execute_and_check to take an owned plan (and thus the caller to do the clone if they don't have one)
Are these changes tested?
CI
Note I expect this to have a limited impact on performance as the higher level APIs (e.g. SessionState::optimize still take a &LogicalPlan) but at least the lower level APIs wont
(this has 4 lines of code change and the rest are test updates to remove
&
)Which issue does this PR close?
Part of https://github.com/apache/datafusion/issues/9637
Rationale for this change
The current
Analyzer::execute_and_check
API requires cloning aLogicalPlan
What changes are included in this PR?
Analyzer::execute_and_check
to take an owned plan (and thus the caller to do the clone if they don't have one)Are these changes tested?
CI
Note I expect this to have a limited impact on performance as the higher level APIs (e.g.
SessionState::optimize
still take a&LogicalPlan
) but at least the lower level APIs wontAre there any user-facing changes?