You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "Fabian Paul (Jira)" <ji...@apache.org> on 2022/01/25 10:36:00 UTC
[jira] [Commented] (FLINK-25702) Use the configure feature provided by the kafka Serializer/Deserializer.
[ https://issues.apache.org/jira/browse/FLINK-25702?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17481724#comment-17481724 ]
Fabian Paul commented on FLINK-25702:
-------------------------------------
Merged in master: 8a694ca3a798e0b166624242ed73970e95e1e5c4
> Use the configure feature provided by the kafka Serializer/Deserializer.
> ------------------------------------------------------------------------
>
> Key: FLINK-25702
> URL: https://issues.apache.org/jira/browse/FLINK-25702
> Project: Flink
> Issue Type: Improvement
> Reporter: Jing Ge
> Assignee: Jing Ge
> Priority: Major
> Labels: pull-request-available
>
> It is hard to understand the reason of using {{Configurable}} for KafkaRecordDeserializationSchema, since Deserializer already has the similar method for configuring.
> It assumes that users might have defined a deserializerA as a subclass of both Configurable and Deserializer, where (Configurable){{{}deserializerA::configure(Map<String, ?>){}}} could have user-defined configuration logic. Since this subclass could be defined by user outside the Flink project, we want to continue to support this this user-defined deserializer for backward compatibility.
> This backward compatibility has been considered. This idea is to just reduce the type control of the input parameter DeserializationSchema a little bit from {{Configurable & Deserializer<V>}} to {{{}Deserializer<V>{}}}. The wrapper will check internally and call {{org.apache.kafka.common.Configurable.configure}} if the schema implements {{{}Configurable{}}}. In this way, old cases due to the backward compatibility will be supported implicitly without confusing users who use {{Deserializer.configure}}
--
This message was sent by Atlassian Jira
(v8.20.1#820001)