Code: Select all
com.fasterxml.jackson.databind.exc.InvalidTypeIdException: Could not resolve type id 'org.example.LocalizedString' as a subtype of [simple type, class org.example.LocalizedString]: known type ids = [LocalizedString] (for POJO property 'name')
Code: Select all
@JsonTypeInfo(use=JsonTypeInfo.Id.NAME, property="type")
@Value
public class LocalizedString {
private Map strings;
...
}
Code: Select all
{
"name": "name",
"type": {
"type": "record",
"namespace": "org.example",
"name": "LocalizedString",
"fields": [
{
"name": "type",
"type": "string"
},
{
"name": "strings",
"type": ["null", {
"type": "map",
"values": "string"
}]
}
]
}
}
Was ist hier das spezifische Problem für Avro?
Und vielleicht ist es auch problematisch, dass der Schlüssel der Strings-Map kein String ist?
Mobile version