When to use Kryo serialization in Spark?

后端 未结 3 1823
梦谈多话
梦谈多话 2021-02-19 13:17

I am already compressing RDDs using conf.set(\"spark.rdd.compress\",\"true\") and persist(MEMORY_AND_DISK_SER). Will using Kryo serialization make the

3条回答
  •  谎友^
    谎友^ (楼主)
    2021-02-19 13:50

    Kryo serialization is a more optimized serialization technique so you can use it to serialize any class which is used in an RDD or Dataframe closure. For some specific information use of Kryo serialization, see below:

    1. Use when serializing third party non-serialize classes inside an RDD or dataframe closure
    2. You want to use efficient serialization technique
    3. If you ever got a serialization error because of some class, you can register that class with the Kryo serializer

提交回复
热议问题