avro-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tatu Saloranta <tsalora...@gmail.com>
Subject Re: Limitations in enum symbols not mentioned in the spec
Date Wed, 27 Feb 2013 18:53:16 GMT
On Wed, Feb 27, 2013 at 10:43 AM, Francis Galiegue <fgaliegue@gmail.com> wrote:
> On Wed, Feb 27, 2013 at 7:40 PM, Doug Cutting <cutting@apache.org> wrote:
>> The restrictions on names are primarily to facilitate translation into
>> programming languages.  Map keys are user data, not part of a schema
>> that might be so translated.  We restricted map keys to strings, since
>> the standard map implementations in some programming languages don't
>> permit arbitrary types in keys.
> I was talking about what is allowed in map keys, not values -- if map
> keys were able to be anything other than strings, Avro could not be
> mapped to JSON.

JSON does not limit keys in any ways, so this is not true.
But maybe you mean that Avro could not be mapped to JSON constrained
by a specific kind of JSON Schema.
I think Avro actually handles this part in more pragmatic terms than
JSON Schema, since many programming languages have clear distinction
between typed objects (in Java, POJOs) and untyped "hash table" like
structure (Maps).

-+ Tatu +-

View raw message