zhenjiaguo commented on a change in pull request #1391:
URL: https://github.com/apache/incubator-kyuubi/pull/1391#discussion_r752124267



##########
File path: 
dev/kyuubi-extension-spark-3-1/src/main/scala/org/apache/kyuubi/sql/watchdog/ForcedMaxOutputRowsRule.scala
##########
@@ -110,33 +113,33 @@ case class MarkAggregateOrderRule(session: SparkSession) 
extends Rule[LogicalPla
     // mark child aggregate
     a.aggregateExpressions.filter(_.resolved).foreach(_.setTagValue(
       ForcedMaxOutputRowsConstraint.CHILD_AGGREGATE,
-      ForcedMaxOutputRowsConstraint.CHILD_AGGREGATE_FLAG)
-    )
+      ForcedMaxOutputRowsConstraint.CHILD_AGGREGATE_FLAG))
   }
 
   private def findAndMarkChildAggregate(plan: LogicalPlan): LogicalPlan = plan 
match {
     /*
-    * The case mainly process order not aggregate column but grouping column 
as below
-    * SELECT c1, COUNT(*) as cnt
-    * FROM t1
-    * GROUP BY c1
-    * ORDER BY c1
-    * */
-    case a: Aggregate if a.aggregateExpressions
-      .exists(x => x.resolved && x.name.equals("aggOrder")) => 
markChildAggregate(a)
+     * The case mainly process order not aggregate column but grouping column 
as below
+     * SELECT c1, COUNT(*) as cnt
+     * FROM t1
+     * GROUP BY c1
+     * ORDER BY c1
+     * */
+    case a: Aggregate
+        if a.aggregateExpressions
+          .exists(x => x.resolved && x.name.equals("aggOrder")) =>
+      markChildAggregate(a)

Review comment:
       It seems a little weird




-- 
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]


Reply via email to