[ https://issues.apache.org/jira/browse/FLINK-4969?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15667040#comment-15667040 ]
Timo Walther commented on FLINK-4969: ------------------------------------- The definition of type information using Strings is deprecated. You should use a type hint: https://ci.apache.org/projects/flink/flink-docs-master/dev/types_serialization.html#creating-a-typeinformation-or-typeserializer > TypeInfoParser needs to be extended to parse the java.sql.* types into the > corresponding TypeInfos. > --------------------------------------------------------------------------------------------------- > > Key: FLINK-4969 > URL: https://issues.apache.org/jira/browse/FLINK-4969 > Project: Flink > Issue Type: Bug > Components: DataSet API, DataStream API > Affects Versions: 1.1.3 > Reporter: radu > Priority: Minor > Labels: features > Original Estimate: 24h > Remaining Estimate: 24h > > Using the "returns" option from the API in order to enforce the type for the > data stream will lead create incorrect types for java.sql.* types. The > TypeInfoParser, used to parse the types, needs to be extended to parse the > java.sql.* types into the corresponding TypeInfos. > > Example > = ds.map(new mapFunction(){ > ... > }}) .returns(“Tuple#<java.sql.TIMESTAMP,…>”); > > > The problem is that if you rely on the type extraction mechanism called > within the "returns()" to recognize TIMESTAMP of type SqlTimeTypeInfo it will > not happen but instead a GenericType<TIMESTAMP> will be created. It is the > same for the other sql types (e.g. TIME) -- This message was sent by Atlassian JIRA (v6.3.4#6332)