github EsotericSoftware/kryo kryo-parent-4.0.0
kryo-4.0.0

7 years ago
  • [BREAKING] Generics handling is more robust now, the former optimization for smaller size (but increased serialization time) is now optional and disabled by default.

    Important: This change breaks the serialization format of the FieldSerializer for generic fields, therefore generic classes serialized with Kryo 3 and FieldSerializer cannot be deserialized with Kryo 4 by default. To deserialize such Kryo 3 serialized generic classes you have to set kryo.getFieldSerializerConfig().setOptimizedGenerics(true);!

    For details see #433: Disable the optimization of generics serialization and provide an API for enabling/disabling it (9923d05).

    This improves/fixes #377 "Kryo does not correctly support parameterized type hierarchy", #384 "ClassCastException When Writing a Map After Previously Reading a Map with Different Generic Type"
  • #424 Fixed (Compatible)FieldSerializer inheritance issue (5a7b7c5)
  • Update reflectasm to latest version, reduction of synchronization (132456e, d77c752)
  • #352 Add forward compatibility to TaggedFieldSerializer (93bff2d)
  • #418 Add checks to setting output buffer and throw IllegalArgumentException when setting a buffer size greater than the max buffer size (d57e00c)
  • #417 Make FieldSerializer.serializeTransient usable (8aae38d)
  • [BREAKING] #415 Make Closure public, moving it to ClosureSerializer (bf80397, 6c402d9)
    Fixes #299 "Can't register ClosureSerializer"
  • #414 Introduce FieldSerializerConfig to encapsulate config in Kryo (4a47981)
  • Fix #412: Add default serializer for java.net.URL (c10fd76)
  • #404 Use system property to detect Android (c238f97)
  • #396 Adds Charset serializer, also set as default serializer (d7e924b)
    Resolves #364 "Few of the java Charsets classes from rt.jar can not be deserialized"
  • #395 Adds support for java 8 java.time.* classes (aff0689)
  • [BREAKING] #392 Move Generics{,Resolver} to serializers, reduce public api (e22ffb8)
  • #400 Modified utility hash maps to gracefully handle very large number of entries. (2b8e6fd)
    Resolves #382 "Kryo breaks down while serializing genomic data"
  • Adds serializers for java8 Optional{Int,Long,Double} (fb65ee9)
  • #362 Add java8 support and serializer for java.util.Optional (12229ca)
  • #393 Fix #389 revert ByteOrder on overflow in require during writeVar_() during writeVar_() (7d840a0)
  • #394 Fix positioning and order updates in ByteBufferInput and ByteBufferOutput (88f5875)
  • #388 Resolve #386: Automatically test serialization compatibility (c904c7e)
  • #375 Fix #370 copyTransient is not global (8414444, 481ddf4, 1ada47d)
  • #368) Try to load classes with fallback that uses current ClassLoader. (8dee484)
  • Update objenesis to 2.2 (ba67801)
  • #359 Use binary search to find field in CompatibleFieldSerializer for object with lots of fields (8678e50)
  • Fixed #346 Issue resizing UnsafeMemoryOutput on OSX 10.10.5 (50d1a6f)
  • Fixed bug #340 KryoException: Encountered unregistered class ID: <negative_number> (2fdf64e)
  • #344 Propagate flush to underlying stream (b3d6bda)
  • #342 Prevent creation of cyclic Generics stack when serializing specific generics object trees
  • #337/#338 ByteBufferInputStream violates InputStream contract (cf06241)
  • #297 Warn unregistered classes option (fd7d1b2)

Here's the list of all commits since 3.0.3

And most importantly; many thanks to all contributors!

Compatibility

  • Serialization compatible
    • Standard IO: No (format for generic fields written by FieldSerializer changed, compatibility can be achieved with kryo.getFieldSerializerConfig().setOptimizedGenerics(true);)
    • Unsafe-based IO: No (format for generic fields written by FieldSerializer changed, compatibility can be achieved with kryo.getFieldSerializerConfig().setOptimizedGenerics(true);)
  • Binary compatible - No (Details)
  • Source compatible - No (Details)

Don't miss a new kryo release

NewReleases is sending notifications on new releases.