Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Incomplete
-
1.1.0
-
None
Description
Calling collectAsMap() on a JavaPairRDD reconstructed from a checkpoint fails with a ClassCastException:
Exception in thread "main" java.lang.ClassCastException: [Ljava.lang.Object; cannot be cast to [Lscala.Tuple2;
at org.apache.spark.rdd.PairRDDFunctions.collectAsMap(PairRDDFunctions.scala:595)
at org.apache.spark.api.java.JavaPairRDD.collectAsMap(JavaPairRDD.scala:569)
at org.facboy.spark.CheckpointBug.main(CheckpointBug.java:46)
Code sample reproducing the issue: https://gist.github.com/facboy/8387e950ffb0746a8272
Attachments
Issue Links
- relates to
-
SPARK-2737 ClassCastExceptions when collect()ing JavaRDDs' underlying Scala RDDs
- Resolved
-
SPARK-1040 Collect as Map throws a casting exception when run on a JavaPairRDD object
- Resolved
-
SPARK-10762 GenericRowWithSchema exception in casting ArrayBuffer to HashSet in DataFrame to RDD from Hive table
- Closed