Avro format
In order to read data from an Avro file, you have to specify an .
Note that User
is a POJO generated by Avro. Flink also allows to perform string-based key selection of these POJOs. For example:
Flink’s POJO field selection also works with POJOs generated from Avro. However, the usage is only possible if the field types are written correctly to the generated class. If a field is of type Object
you can not use the field as a join or grouping key. Specifying a field in Avro like this works fine, however specifying it as a UNION-type with only one field ({"name": "type_double_test", "type": ["double"]},
) will generate a field of type . Note that specifying nullable types ({"name": "type_double_test", "type": ["null", "double"]},
) is possible!