avro-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Andrei I. Holub" <andrei.ho...@gmail.com>
Subject Closest common ancestor for unions
Date Fri, 28 Oct 2016 20:58:24 GMT
If field is declared as union, it will be transformed to the Object (java)
during the schema generation.
Is it possible to change this behaviour and pick common closest ancestor
interface in the generated classes?
The other option could be providing the interface/class as a metadata and
check if union's members can be casted to it during generation. In any case
we always have Object as a backup solution if something goes wrong.
With this solution will be possible to implement some inheritance
immitation which can be nice addition to the cases where avro can be used.

View raw message