[
https://issues.apache.org/jira/browse/SPARK-17265?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16000950#comment-16000950
]
nanav yorbiz commented on SPARK-17265:
--------------------------------------
spark-1.5.2 on MacOS chokes on the following in the same way (and, so does
2.1.1 on Linux)
-------
import org.apache.spark.graphx.{Edge, Graph}
case class Attr(what: Int, ever: Int)
val V = 11
val E = 42
def rndVertex = (V * Math.random).toLong
val edges = sc.parallelize(Array.fill(E)(Edge(rndVertex, rndVertex, Attr(-1,
0))))
val g = Graph.fromEdges(edges, 0)
val h = Graph.fromEdges(edges, 0)
println(g.edges.subtract(h.edges).count)
-------
> EdgeRDD Difference throws an exception
> --------------------------------------
>
> Key: SPARK-17265
> URL: https://issues.apache.org/jira/browse/SPARK-17265
> Project: Spark
> Issue Type: Bug
> Affects Versions: 2.0.0
> Environment: windows, ubuntu
> Reporter: Shishir Kharel
>
> Subtracting two edge RDD throws and exception.
> val difference = graph1.edges.subtract(graph2.edges)
> gives
> Exception in thread "main" org.apache.spark.SparkException: Job aborted due
> to stage failure: Task 1 in stage 0.0 failed 1 times, most recent failure:
> Lost task 1.0 in stage 0.0 (TID 1, localhost): java.lang.ClassCastException:
> org.apache.spark.graphx.Edge cannot be cast to scala.Tuple2
> at
> org.apache.spark.rdd.RDD$$anonfun$subtract$3$$anon$3.getPartition(RDD.scala:968)
> at
> org.apache.spark.shuffle.sort.BypassMergeSortShuffleWriter.write(BypassMergeSortShuffleWriter.java:152)
> at
> org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:79)
> at
> org.apache.spark.scheduler.ShuffleMapTask.runTask(ShuffleMapTask.scala:47)
> at org.apache.spark.scheduler.Task.run(Task.scala:86)
> at
> org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:274)
> at
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
> at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
> at java.lang.Thread.run(Thread.java:745)
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]