Github user cloud-fan commented on a diff in the pull request:
https://github.com/apache/spark/pull/19661#discussion_r149012452
--- Diff:
core/src/main/scala/org/apache/spark/serializer/KryoSerializer.scala ---
@@ -178,10 +178,31 @@ class KryoSerializer(conf: SparkConf)
kryo.register(Utils.classForName("scala.collection.immutable.Map$EmptyMap$"))
kryo.register(classOf[ArrayBuffer[Any]])
+ // We can't load those class directly in order to avoid unnecessary
jar dependencies.
+ // We load them safely, ignore it if the class not found.
+
safeClassLoader("org.apache.spark.mllib.linalg.Vector").foreach(kryo.register(_))
--- End diff --
I don't have a strong objection to this, it's a little hacky though. cc
@srowen
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]