I am trying to create a flink consumer for a kafka avro serialized topic. I have the kafka topic streaming avro serialized data. I can see it via the avroconsoleconsumer.
The Flink 1.6.0 has added an AvroDeserializationSchema
but I can not find a complete example of its usage. Yes there are a few that generate an avrodeserialization class seemingly prior to 1.6.0 added the class.
I have an avro class generated via the avro-tools.
right now i have been trying to following the examples that exist but they are different enough that I can't get things going. (I don't program in Java that often)
Most use some form of the following
Myclass mc = new MyClass();
AvroDeserializationSchema<Myclass> ads = new AvroDeserializationSchema<> (Myclass.class);
FlinkKafkaConsumer010<Myclass> kc = new FlinkKafkaConsumer010<>(topic,ads,properties);
where Myclass is a avro class generated via the avro-tools jar. Is this the correct way to go? I am experiencing some private/public access issues when doing this and leveraging the internal flink 1.6.0 avrodeserializationschema class. Do I have to create a new class and extend the avrodeserializationschema?