You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by ConeyLiu <gi...@git.apache.org> on 2017/10/30 14:00:19 UTC

[GitHub] spark pull request #19586: [SPARK-22367][WIP][CORE] Separate the serializati...

Github user ConeyLiu commented on a diff in the pull request:

    https://github.com/apache/spark/pull/19586#discussion_r147709649
  
    --- Diff: core/src/main/scala/org/apache/spark/serializer/KryoSerializer.scala ---
    @@ -205,11 +205,45 @@ class KryoSerializationStream(
     
       private[this] var kryo: Kryo = serInstance.borrowKryo()
     
    +  // This is only used when we write object and class separately.
    +  var classWrote = false
    +
       override def writeObject[T: ClassTag](t: T): SerializationStream = {
         kryo.writeClassAndObject(output, t)
    --- End diff --
    
    From the code, it just write a `varInt` if the class have been registered. And also there need some calculation for getting the `varInt`. But from the test, the overhead looks more serious than I expected.


---

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org