Search code examples
javajodatimekryo

How to serialize Joda-Time's LocalDate with Kryo


I am trying to serialize with Kryo a class containing a LocalDate from Joda-Time.

It looks like I'll need a custom-made serializer.

I found some Joda-Time serializers in https://github.com/magro/kryo-serializers but none for LocalDate.

Any help? Should I write my own :(?

(Some people marked this as duplicate of Serializing custom object that contains JodaTime objects into JSON, but this is a question about existing Kyro serializers, I fail to see how an answer about a custom JSON serializer solves my problem...)


Solution

  • That repository you mention (magro/kryo-serializers) now does have a JodaLocalDateSerializer (and other Joda serializers) - since about June 2015, a couple of months after you asked.