Add `map_children_mut` to `Expr` / maybe `TreeNode`?
- Dominant language
- Rust
- Stars
- 9.3k
- Forks
- 2.4k
- Avg merge
- 3d 7h
- Merged PRs (30d)
- 344
Description
https://github.com/apache/datafusion/pull/22298/ added an optimization for `LogicalPlan` rewriting to avoid cloning the tree when not necessary via a new `map_children_mut` method.
We could probably add something similar to `Expr`. I'm less sure about `Arc` and `Arc` but we should generally explore our options for this method or other changes we might be able to make to the `TreeNode` API to make optimizer rules more efficient.
Contributor guide
Research direction
Start with Apache DataFusion PR 22298 and the existing LogicalPlan map_children_mut change, then inspect the TreeNode API, Expr, Arc, and Arc options mentioned in the issue. Done means selecting and implementing a suitable non-cloning traversal API or documenting why the alternatives are not appropriate.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- backend, data-engineering, performance
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100