You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2020/10/30 06:42:08 UTC

[GitHub] [spark] c21 commented on a change in pull request #30200: [SPARK-33027][SQL] Add DisableUnnecessaryBucketedScan rule to AQE

c21 commented on a change in pull request #30200:
URL: https://github.com/apache/spark/pull/30200#discussion_r514898262



##########
File path: sql/core/src/main/scala/org/apache/spark/sql/execution/adaptive/AdaptiveSparkPlanExec.scala
##########
@@ -85,14 +86,16 @@ case class AdaptiveSparkPlanExec(
   @transient private val removeRedundantProjects = RemoveRedundantProjects
   @transient private val removeRedundantSorts = RemoveRedundantSorts
   @transient private val ensureRequirements = EnsureRequirements
+  @transient private val disableUnnecessaryBucketedScan = DisableUnnecessaryBucketedScan
 
   // A list of physical plan rules to be applied before creation of query stages. The physical
   // plan should reach a final status of query stages (i.e., no more addition or removal of
   // Exchange nodes) after running these rules.
   private def queryStagePreparationRules: Seq[Rule[SparkPlan]] = Seq(
     removeRedundantProjects,
     removeRedundantSorts,
-    ensureRequirements
+    ensureRequirements,
+    disableUnnecessaryBucketedScan

Review comment:
       @cloud-fan - agree, updated.

##########
File path: sql/core/src/test/scala/org/apache/spark/sql/sources/DisableUnnecessaryBucketedScanSuite.scala
##########
@@ -230,14 +248,14 @@ abstract class DisableUnnecessaryBucketedScanSuite extends QueryTest with SQLTes
         assertCached(spark.table("t1"))
 
         // Verify cached bucketed table scan not disabled
-        val partitioning = spark.table("t1").queryExecution.executedPlan
-          .outputPartitioning
-        assert(partitioning match {
+        val inMemoryScan = find(spark.table("t1").queryExecution.executedPlan)(

Review comment:
       @cloud-fan - sure, it's less verbose, updated.




----------------------------------------------------------------
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:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org