You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@avro.apache.org by "Alexander Kasper (JIRA)" <ji...@apache.org> on 2016/06/20 15:36:05 UTC
[jira] [Created] (AVRO-1865) GenericData.Array class missing no arg
constructor for Kryo serialization
Alexander Kasper created AVRO-1865:
--------------------------------------
Summary: GenericData.Array class missing no arg constructor for Kryo serialization
Key: AVRO-1865
URL: https://issues.apache.org/jira/browse/AVRO-1865
Project: Avro
Issue Type: Bug
Components: java
Affects Versions: 1.8.1
Reporter: Alexander Kasper
Attachments: add-no-arg-ctor-genericdata-array.diff
When trying to serialize Java classes generated by Avro that contain a field as follows:
`array<MyClass> myclasses = []`
serialization fails with the following error message
`com.esotericsoftware.kryo.KryoException: Class cannot be created (missing no-arg constructor)`
This is a common enough issue with Kryo that they have a dedicated section on their website on it: http://docs.datatorrent.com/troubleshooting/#application-throwing-following-kryo-exception
The attached patch adds a no args constructor for the inner class Array of GenericData with zero entries and a dummy schema. My personal tests for serialization with Kryo were successful when using it. Since I do not have complete insight into Avro I'd like to know if this could be a breaking change and how to test it if so.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)