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

Timothy Dimo commented on AVRO-3217:
------------------------------------

[~rskraba] the serialization failure occurs in the Java client as noted. The 
REST Proxy works fine without adding the additional property information.

According to Confluent, "This is addressed in 5.5.1 and later by specifying 
{{auto.register.schemas=false}} and {{use.latest.version=true}} in the Avro 
serializer configs." See 
[here|https://github.com/confluentinc/schema-registry/issues/868] and 
[here|[https://github.com/confluentinc/schema-registry/issues/1352].] However - 
at least for now - my team has decided to add the property to the schema file 
since we don't know the long-term implications of the {{use.latest.version=true 
setting.}}

This particular problem appears to be tied up with the Confluent 
KafkaAvroSerializer.

> Avro IDL does not allow creation of avro.java.string subtype
> ------------------------------------------------------------
>
>                 Key: AVRO-3217
>                 URL: https://issues.apache.org/jira/browse/AVRO-3217
>             Project: Apache Avro
>          Issue Type: Bug
>          Components: java, tools
>    Affects Versions: 1.10.2
>         Environment: Java 8, Windows, macOS, Confluent Platform 5.5.1
>            Reporter: Timothy Dimo
>            Priority: Major
>
>  
> When using a Java application that has class files generated from an avsc 
> file via the Avro Maven plugin along with the 
> {noformat}
> <stringType>String</stringType>{noformat}
> switch set, serialization of records of the type string such as
>  
> {code:java}
> {"name":"eventType","type":"string"}{code}
> will fail. Changing the type to include an "avro.java.string" detail such as
>  
> {code:java}
> "name": "eventType",
>             "type": {
>               "avro.java.string": "String",
>               "type": "string"
>             }
> {code}
> will succeed.
>  
> It is not possible to create this "avro.java.string": "String" detail via the 
> Avro IDL language. The schema creator must first create the avsc file then 
> manually update all of the "type":"string" fields.
> See also [this 
> link|https://stackoverflow.com/questions/69303642/why-does-an-avro-field-that-was-string-now-require-avro-java-string-type].
>  
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to