cloud-fan commented on a change in pull request #26516: [SPARK-29893] improve
the local shuffle reader performance by changing the reading task number from 1
to multi.
URL: https://github.com/apache/spark/pull/26516#discussion_r347723347
##########
File path:
sql/core/src/main/scala/org/apache/spark/sql/execution/adaptive/LocalShuffledRowRDD.scala
##########
@@ -17,20 +17,26 @@
package org.apache.spark.sql.execution.adaptive
+import scala.collection.mutable.ArrayBuffer
+
import org.apache.spark._
import org.apache.spark.rdd.RDD
import org.apache.spark.sql.catalyst.InternalRow
import org.apache.spark.sql.execution.metric.{SQLMetric,
SQLShuffleReadMetricsReporter}
-
/**
- * The [[Partition]] used by [[LocalShuffledRowRDD]]. A pre-shuffle partition
- * (identified by `preShufflePartitionIndex`) contains a range of post-shuffle
partitions
- * (`startPostShufflePartitionIndex` to `endPostShufflePartitionIndex - 1`,
inclusive).
+ * The [[Partition]] used by [[LocalShuffledRowRDD]].
+ * @param indexId the index in the RDD.
+ * @param mapIndex the mapper ID.
+ * @param startPartition the start partition ID in mapIndex mapper.
+ * @param endPartition the end partition ID in mapIndx mapper.
*/
private final class LocalShuffledRowRDDPartition(
- val preShufflePartitionIndex: Int) extends Partition {
- override val index: Int = preShufflePartitionIndex
+ val indexId: Int,
Review comment:
if we write `val index` here, can we avoid `override val index: Int =
indexId`?
----------------------------------------------------------------
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]