You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "Robert Metzger (Jira)" <ji...@apache.org> on 2020/11/13 18:53:00 UTC
[jira] [Commented] (FLINK-20158) KafkaSource does not implement
ResultTypeQueryable
[ https://issues.apache.org/jira/browse/FLINK-20158?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17231758#comment-17231758 ]
Robert Metzger commented on FLINK-20158:
----------------------------------------
[~becket_qin] I guess this would be a nice usability extension. I haven't checked if this works with the new "env.fromSource()", but I see no reason why it shouldn't.
> KafkaSource does not implement ResultTypeQueryable
> --------------------------------------------------
>
> Key: FLINK-20158
> URL: https://issues.apache.org/jira/browse/FLINK-20158
> Project: Flink
> Issue Type: Bug
> Components: Connectors / Kafka
> Affects Versions: 1.12.0
> Reporter: Robert Metzger
> Priority: Critical
> Fix For: 1.12.0
>
>
> As a user of the new Kafka Source introduced in (FLINK-18323), I always have to specify the return type:
> {code}
> DataStream<Event> events = env.fromSource(source, WatermarkStrategy.noWatermarks(),
> "Kafka Source").returns(TypeInformation.of(Event.class));
> {code}
> The old Kafka source implementation implements {{ResultTypeQueryable}}, which allows the DataStream API to get the return type from the deserializer.
> The new Kafka Source also should have access to the produced type from the deserializer to forward it.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)