Reputation: 9000
I've got my Kafka Streams processing configuration for AUTO_REGISTER_SCHEMAS
set to true.
I noticed in this auto generated schema it creates the following 2 types
{
"name": "id",
"type": {
"type": "string",
"avro.java.string": "String"
}
},
Could someone please explain why it creates 2 types and what exactly "avro.java.string": "String"
is.
Thanks
Upvotes: 13
Views: 11835
Reputation: 7957
By default Avro uses CharSequence
for the String representation, the following syntax allows you to overwrite the default behavior and use java.lang.String as the String type for the instances of the fields declared like this
"type": {
"type": "string",
"avro.java.string": "String"
}
Upvotes: 14