Skip to content
Snippets Groups Projects
Commit 5c2c4dcc authored by Ala Luszczak's avatar Ala Luszczak Committed by Herman van Hovell
Browse files

[SPARK-19447] Remove remaining references to generated rows metric

## What changes were proposed in this pull request?

https://github.com/apache/spark/commit/b486ffc86d8ad6c303321dcf8514afee723f61f8 left behind references to "number of generated rows" metrics, that should have been removed.

## How was this patch tested?

Existing unit tests.

Author: Ala Luszczak <ala@databricks.com>

Closes #17939 from ala/SPARK-19447-fix.
parent fcb88f92
No related branches found
No related tags found
No related merge requests found
...@@ -340,8 +340,7 @@ case class RangeExec(range: org.apache.spark.sql.catalyst.plans.logical.Range) ...@@ -340,8 +340,7 @@ case class RangeExec(range: org.apache.spark.sql.catalyst.plans.logical.Range)
override val output: Seq[Attribute] = range.output override val output: Seq[Attribute] = range.output
override lazy val metrics = Map( override lazy val metrics = Map(
"numOutputRows" -> SQLMetrics.createMetric(sparkContext, "number of output rows"), "numOutputRows" -> SQLMetrics.createMetric(sparkContext, "number of output rows"))
"numGeneratedRows" -> SQLMetrics.createMetric(sparkContext, "number of generated rows"))
override lazy val canonicalized: SparkPlan = { override lazy val canonicalized: SparkPlan = {
RangeExec(range.canonicalized.asInstanceOf[org.apache.spark.sql.catalyst.plans.logical.Range]) RangeExec(range.canonicalized.asInstanceOf[org.apache.spark.sql.catalyst.plans.logical.Range])
...@@ -354,7 +353,6 @@ case class RangeExec(range: org.apache.spark.sql.catalyst.plans.logical.Range) ...@@ -354,7 +353,6 @@ case class RangeExec(range: org.apache.spark.sql.catalyst.plans.logical.Range)
protected override def doProduce(ctx: CodegenContext): String = { protected override def doProduce(ctx: CodegenContext): String = {
val numOutput = metricTerm(ctx, "numOutputRows") val numOutput = metricTerm(ctx, "numOutputRows")
val numGenerated = metricTerm(ctx, "numGeneratedRows")
val initTerm = ctx.freshName("initRange") val initTerm = ctx.freshName("initRange")
ctx.addMutableState("boolean", initTerm, s"$initTerm = false;") ctx.addMutableState("boolean", initTerm, s"$initTerm = false;")
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment