[ https://issues.apache.org/jira/browse/FLINK-25702?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Jing Ge updated FLINK-25702: ---------------------------- Description: 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}} was: it is hard to understand the reason of using {{Configurable}} for KafkaRecordDeserializationSchema, since Deserializer already has the similar method for configuring. . > 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)