You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "Chesnay Schepler (Jira)" <ji...@apache.org> on 2022/08/08 10:36:00 UTC
[jira] [Closed] (FLINK-28675) Avro Schemas should eagerly validate that class is SpecificRecord
[ https://issues.apache.org/jira/browse/FLINK-28675?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Chesnay Schepler closed FLINK-28675.
------------------------------------
Fix Version/s: (was: 1.16.0)
Resolution: Invalid
This is already enforced by generics.
> Avro Schemas should eagerly validate that class is SpecificRecord
> -----------------------------------------------------------------
>
> Key: FLINK-28675
> URL: https://issues.apache.org/jira/browse/FLINK-28675
> Project: Flink
> Issue Type: Improvement
> Components: Formats (JSON, Avro, Parquet, ORC, SequenceFile)
> Affects Versions: 1.15.1
> Reporter: Chesnay Schepler
> Priority: Major
>
> The AvroDeserializationSchema supports both generic and specific records, with dedicated factory methods.
> It does however not validate in any way whether the classes passed to the factories methods are actually generic/specific records respectively, which can result in Flink attempting to read generic records (and failing with an NPE) even though the user told us to read specific records.
> We should validate this eagerly and fail early.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)