cloud-fan commented on code in PR #44462:
URL: https://github.com/apache/spark/pull/44462#discussion_r1437620379
##########
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/plans/logical/AnalysisHelper.scala:
##########
@@ -177,10 +177,14 @@ trait AnalysisHelper extends QueryPlan[LogicalPlan] {
self: LogicalPlan =>
self.markRuleAsIneffective(ruleId)
self
} else {
+ rewritten_plan.copyTagsFrom(self)
rewritten_plan
}
} else {
- afterRule.mapChildren(_.resolveOperatorsDownWithPruning(cond,
ruleId)(rule))
+ val newPlan = afterRule
+ .mapChildren(_.resolveOperatorsDownWithPruning(cond, ruleId)(rule))
+ newPlan.copyTagsFrom(self)
+ newPlan
}
}
Review Comment:
This method `resolveOperatorsDownWithPruning` is very similar to
`TreeNode#transformDownWithPruning`. Would be good if we can refactor and unify
them. cc @beliefer
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]