chakravarthiT commented on a change in pull request #24136: [SPARK-27088][SQL]  
Add a configuration to set log level for each batch at RuleExecutor
URL: https://github.com/apache/spark/pull/24136#discussion_r269517534
 
 

 ##########
 File path: 
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/rules/RuleExecutor.scala
 ##########
 @@ -152,15 +152,7 @@ abstract class RuleExecutor[TreeType <: TreeNode[_]] 
extends Logging {
         lastPlan = curPlan
       }
 
-      if (!batchStartPlan.fastEquals(curPlan)) {
-        logDebug(
-          s"""
-            |=== Result of Batch ${batch.name} ===
-            |${sideBySide(batchStartPlan.treeString, 
curPlan.treeString).mkString("\n")}
-          """.stripMargin)
-      } else {
-        logTrace(s"Batch ${batch.name} has no effect.")
-      }
+      planChangeLogger.logBatch(batch.name, batchStartPlan, curPlan)
 
 Review comment:
   The config "spark.sql.optimizer.planChangeLog.level",  is used for **logging 
 plan changes** after applying rule or batch . As per Line 148,it is logging 
when there is no change in plan,which conflicts the 
parameter(spark.sql.optimizer.planChangeLog.level).  Its not required to log 
this.
   

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to