File tree Expand file tree Collapse file tree 2 files changed +11
-3
lines changed
sql/core/src/main/scala/org/apache/spark/sql Expand file tree Collapse file tree 2 files changed +11
-3
lines changed Original file line number Diff line number Diff line change @@ -2035,7 +2035,7 @@ def isCheckpointed(self):
20352035
20362036 def getCheckpointFile (self ):
20372037 checkpointFile = self ._jschema_rdd .getCheckpointFile ()
2038- if checkpointFile .isPresent ():
2038+ if checkpointFile .isDefined ():
20392039 return checkpointFile .get ()
20402040
20412041 def coalesce (self , numPartitions , shuffle = False ):
Original file line number Diff line number Diff line change @@ -476,13 +476,18 @@ class SchemaRDD(
476476 (implicit ord : Ordering [Row ] = null ): SchemaRDD =
477477 applySchema(super .coalesce(numPartitions, shuffle)(ord))
478478
479- override def distinct (): SchemaRDD =
480- applySchema(super .distinct())
479+ def coalesce (numPartitions : Int , shuffle : Boolean ): SchemaRDD =
480+ applySchema(super .coalesce(numPartitions, shuffle)(null ))
481+
482+ override def distinct (): SchemaRDD = applySchema(super .distinct())
481483
482484 override def distinct (numPartitions : Int )
483485 (implicit ord : Ordering [Row ] = null ): SchemaRDD =
484486 applySchema(super .distinct(numPartitions)(ord))
485487
488+ def distinct (numPartitions : Int ): SchemaRDD =
489+ applySchema(super .distinct(numPartitions)(null ))
490+
486491 override def filter (f : Row => Boolean ): SchemaRDD =
487492 applySchema(super .filter(f))
488493
@@ -500,6 +505,9 @@ class SchemaRDD(
500505 (implicit ord : Ordering [Row ] = null ): SchemaRDD =
501506 applySchema(super .repartition(numPartitions)(ord))
502507
508+ def repartition (numPartitions : Int ): SchemaRDD =
509+ applySchema(super .repartition(numPartitions)(null ))
510+
503511 override def subtract (other : RDD [Row ]): SchemaRDD =
504512 applySchema(super .subtract(other))
505513
You can’t perform that action at this time.
0 commit comments