You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@avro.apache.org by "ASF subversion and git services (JIRA)" <ji...@apache.org> on 2014/01/27 23:09:49 UTC

[jira] [Commented] (AVRO-1445) avro from protobuf write fails on enum with default

    [ https://issues.apache.org/jira/browse/AVRO-1445?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13883417#comment-13883417 ] 

ASF subversion and git services commented on AVRO-1445:
-------------------------------------------------------

Commit 1561875 from [~cutting] in branch 'avro/trunk'
[ https://svn.apache.org/r1561875 ]

AVRO-1445. Java: Fix protobuf support to correctly handle enums with default values.

> avro from protobuf write fails on enum with default
> ---------------------------------------------------
>
>                 Key: AVRO-1445
>                 URL: https://issues.apache.org/jira/browse/AVRO-1445
>             Project: Avro
>          Issue Type: Bug
>            Reporter: George Baxter
>            Assignee: Doug Cutting
>             Fix For: 1.7.7
>
>         Attachments: AVRO-1445.patch
>
>
> If the protobuf you're attempting to write out as avro has a enum field with a default, the following error occurs:
> Caused by: java.lang.RuntimeException: org.codehaus.jackson.JsonParseException: Unexpected character ('c' (code 99)): expected a valid value (number, String, array, object, 'true', 'false' or 'null')
>  at [Source: java.io.StringReader@118a8bef; line: 1, column: 2]
> 	at org.apache.avro.protobuf.ProtobufData.getDefault(ProtobufData.java:317)
> 	at org.apache.avro.protobuf.ProtobufData.getSchema(ProtobufData.java:208)
> 	at org.apache.avro.protobuf.ProtobufData.getNonRepeatedSchema(ProtobufData.java:283)
> 	at org.apache.avro.protobuf.ProtobufData.getSchema(ProtobufData.java:255)
> 	at org.apache.avro.protobuf.ProtobufData.getSchema(ProtobufData.java:208)
> 	at org.apache.avro.protobuf.ProtobufData.getSchema(ProtobufData.java:176)
> 	... 36 more
> java.lang.RuntimeException: java.lang.RuntimeException: org.codehaus.jackson.JsonParseException: Unexpected character ('c' (code 99)): expected a valid value (number, String, array, object, 'true', 'false' or 'null')
>  at [Source: java.io.StringReader@7d50c032; line: 1, column: 2]
> 	at org.apache.avro.protobuf.ProtobufData.getSchema(ProtobufData.java:178)



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)