parthchandra commented on code in PR #45488:
URL: https://github.com/apache/spark/pull/45488#discussion_r1535858713
##########
sql/core/src/test/scala/org/apache/spark/sql/SparkSessionExtensionSuite.scala:
##########
@@ -583,6 +611,24 @@ case class MyParser(spark: SparkSession, delegate:
ParserInterface) extends Pars
delegate.parseQuery(sqlText)
}
+case class ExplainPlanInfoTagRule() extends Rule[SparkPlan] {
Review Comment:
Let me see if I understand this right -
A session extension implementation can implement the trait above and set the
implementation in a config. If such an implementation is provided, then explain
plan can print it. We can replace the `enableExtensionInfo` flag with this new
conf.
The contents and formatting of the extended explain string etc, now become
part of the session extension and so we can remove the changes in `QueryPlan`.
The extension implementors will have to do more work, but likely will have
greater flexibility.
Let me know if I misunderstood. Otherwise I'll go ahead with this change.
--
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]