You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@avro.apache.org by Simon Heeg <si...@unbelievable-machine.com> on 2018/11/12 15:02:58 UTC

[Question] Avro Java Library validate Record with LogicalTypes

Hi there,

I was searching the internet for quite a while, before I decided to write to this list. My problem is, that I have a GenericRecord and I want to test that it matches its Schema. That works like a charm until I introduce logical types to the schema because now the SpecificData.get().validate(…,...) method returns false. Taking a close look at the Code of SpecificData.class  in the Avro 1.8.2 Java Library it reveals that “validate” does not take notice of registered LogicalTypeConversions and tries to verify that my DateTime is an instance of long.
Can you recommend a way that I can use to validate my GenericRecords? To you guys know about a Bug ticket on this issue?

Best wishes and thanks for your support,
Simon