We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cf1d32e commit a2aa36bCopy full SHA for a2aa36b
core/src/main/scala/org/apache/spark/rdd/RDD.scala
@@ -1084,10 +1084,9 @@ abstract class RDD[T: ClassTag](
1084
if (buf.size == 0) {
1085
numPartsToTry = partsScanned * 4
1086
} else {
1087
- numPartsToTry = (1.5 * num * partsScanned / buf.size).toInt
+ numPartsToTry = (1.5 * num * partsScanned / buf.size).toInt - partsScanned
1088
}
1089
1090
- numPartsToTry = math.max(0, numPartsToTry) // guard against negative num of partitions
1091
1092
val left = num - buf.size
1093
val p = partsScanned until math.min(partsScanned + numPartsToTry, totalParts)
0 commit comments