From 82ebff411540df45ae214ac16fddf9d2fba212fd Mon Sep 17 00:00:00 2001 From: Liang-Chi Hsieh Date: Tue, 25 Oct 2016 07:29:57 +0000 Subject: [PATCH] Polishing comment. --- .../apache/spark/sql/execution/WholeStageCodegenExec.scala | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sql/core/src/main/scala/org/apache/spark/sql/execution/WholeStageCodegenExec.scala b/sql/core/src/main/scala/org/apache/spark/sql/execution/WholeStageCodegenExec.scala index bc78234fee70c..5bf871296ed7f 100644 --- a/sql/core/src/main/scala/org/apache/spark/sql/execution/WholeStageCodegenExec.scala +++ b/sql/core/src/main/scala/org/apache/spark/sql/execution/WholeStageCodegenExec.scala @@ -299,8 +299,8 @@ case class WholeStageCodegenExec(child: SparkPlan) extends UnaryExecNode with Co override def outputOrdering: Seq[SortOrder] = child.outputOrdering override def executeCollect(): Array[InternalRow] = child match { - // This happens when the user is collecting results back to the driver, we could skip - // the shuffling and scan increasingly the RDD to get the limited items. + // A physical Limit operator has optimized executeCollect which scans increasingly + // the RDD to get the limited items, without fully materializing the RDD. case g: GlobalLimitExec => g.executeCollect() case _ => super.executeCollect() }