Hi,
I run into Task not Serializable excption with following code below. When I
remove the threads and run, it works, but with threads I run into Task not
serializable exception.
object SparkKart extends Serializable{
def parseVector(line: String): Vector[Double] = {
DenseVector(line.split
}
}
--
View this message in context:
http://apache-spark-user-list.1001560.n3.nabble.com/Task-not-serializable-exception-tp21776p21778.html
Sent from the Apache Spark User List mailing list archive at Nabble.com
() {
val dist1 =data.map(x = squaredDistance(x,kPoints(0)))
}
})
thread1.start
I am facing Task not serializable exception:
Exception in thread Thread-32 org.apache.spark.SparkException: Task not
serializable
at
org.apache.spark.util.ClosureCleaner