You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@avro.apache.org by "Jeff Hodges (JIRA)" <ji...@apache.org> on 2010/04/28 09:40:32 UTC

[jira] Resolved: (AVRO-529) Cannot use array type in avro request

     [ https://issues.apache.org/jira/browse/AVRO-529?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jeff Hodges resolved AVRO-529.
------------------------------

    Fix Version/s: 1.3.2
       Resolution: Won't Fix

The error should be made better (so I made AVRO-531), and while it might be nice for arrays and maps, the problems of allowing for "nested" schemas are more trouble than they are worth, atm.

> Cannot use array type in avro request
> -------------------------------------
>
>                 Key: AVRO-529
>                 URL: https://issues.apache.org/jira/browse/AVRO-529
>             Project: Avro
>          Issue Type: Bug
>          Components: ruby
>    Affects Versions: 1.4.0
>         Environment: Mac OS X
>            Reporter: Wanli Yang
>             Fix For: 1.3.2
>
>
> While it is OK to use array in avro response, we get the following error when using it in the type definition. e.g.:
>   {
>     "namespace": "my_namespace",
>     "protocol": "MyProtocol",
>     "types": [
>       {
>         "name": "Thing", "type": "record", "fields": [
>           { "name": "id", "type": "long" },
>           { "name": "other_ids", "type": "array", "items": "long" }
> ...
> /script/../vendor/gems/avro-1.4.0.pre1/lib/avro/schema.rb:78:in `real_parse': "array" is not  a schema we know about. (Avro::SchemaParseError)
> 	from ./script/../vendor/gems/avro-1.4.0.pre1/lib/avro/schema.rb:135:in `subparse'
> 	from ./script/../vendor/gems/avro-1.4.0.pre1/lib/avro/schema.rb:369:in `initialize'
> 	from ./script/../vendor/gems/avro-1.4.0.pre1/lib/avro/schema.rb:180:in `new'
> 	from ./script/../vendor/gems/avro-1.4.0.pre1/lib/avro/schema.rb:180:in `make_field_objects'
> 	from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in `each_with_index'
> 	from ./script/../vendor/gems/avro-1.4.0.pre1/lib/avro/schema.rb:174:in `each'
> 	from ./script/../vendor/gems/avro-1.4.0.pre1/lib/avro/schema.rb:174:in `each_with_index'
> 	from ./script/../vendor/gems/avro-1.4.0.pre1/lib/avro/schema.rb:174:in `make_field_objects'
> 	from ./script/../vendor/gems/avro-1.4.0.pre1/lib/avro/schema.rb:200:in `initialize'
> 	from ./script/../vendor/gems/avro-1.4.0.pre1/lib/avro/schema.rb:53:in `new'
> 	from ./script/../vendor/gems/avro-1.4.0.pre1/lib/avro/schema.rb:53:in `real_parse'
> 	from ./script/../vendor/gems/avro-1.4.0.pre1/lib/avro/protocol.rb:73:in `parse_types'
> 	from ./script/../vendor/gems/avro-1.4.0.pre1/lib/avro/protocol.rb:70:in `collect'
> 	from ./script/../vendor/gems/avro-1.4.0.pre1/lib/avro/protocol.rb:70:in `parse_types'
> 	from ./script/../vendor/gems/avro-1.4.0.pre1/lib/avro/protocol.rb:54:in `initialize'
> 	from ./script/../vendor/gems/avro-1.4.0.pre1/lib/avro/protocol.rb:31:in `new'
> 	from ./script/../vendor/gems/avro-1.4.0.pre1/lib/avro/protocol.rb:31:in `parse'

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.