avro-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Doug Cutting <cutt...@apache.org>
Subject Re: Incorrect Json schema generated for @java_class
Date Thu, 28 Feb 2013 17:19:37 GMT
Annotation names in IDL are copied directly to schema properties with
the same names.

The bug is in the IDL documentation, which uses the annotation
@java_class in an example, which is meaningless.  The Java
implementation requires the "java-class" schema property, so the
annotation used should be @java-class.

I filed an issue in Jira for this.



On Wed, Feb 27, 2013 at 7:18 PM, avronewbie <shilpav4@gmail.com> wrote:
> For the IDL field:
> @java_class("java.util.ArrayList") array<int> arrayOfInts;
> the JSON schema generated by the avro-maven-plugin is
> {\"name\":\"arrayOfInts\",\"type\":{\"type\":\"array\",\"items\":\"int\",\"java_class\":\"java.util.ArrayList\"}}
> Shouldn't it be generated in JSON as java-class (with hypen instead of
> underscore) instead of java_class? Because of this reading from avro file is
> not working.
> --
> View this message in context: http://apache-avro.679487.n3.nabble.com/Incorrect-Json-schema-generated-for-java-class-tp4026430.html
> Sent from the Avro - Users mailing list archive at Nabble.com.

View raw message