You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "Stephan Ewen (JIRA)" <ji...@apache.org> on 2016/09/21 15:56:20 UTC
[jira] [Closed] (FLINK-4645) Hard to register Kryo Serializers due
to generics
[ https://issues.apache.org/jira/browse/FLINK-4645?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Stephan Ewen closed FLINK-4645.
-------------------------------
> Hard to register Kryo Serializers due to generics
> -------------------------------------------------
>
> Key: FLINK-4645
> URL: https://issues.apache.org/jira/browse/FLINK-4645
> Project: Flink
> Issue Type: Bug
> Components: Core
> Affects Versions: 1.1.2
> Reporter: Stephan Ewen
> Assignee: Stephan Ewen
> Fix For: 1.2.0
>
>
> It currently does not work to do this:
> {code}
> env.registerTypeWithKryoSerializer(TreeMultimap.class, JavaSerializer.class);
> {code}
> instead on needs to do that:
> {code}
> env.registerTypeWithKryoSerializer(TreeMultimap.class, (Class<? extends Serializer<?>>) JavaSerializer.class);
> {code}
> The fix would be to change the signature of the environment method from
> {code}
> public void registerTypeWithKryoSerializer(Class<?> type, Class<? extends Serializer<?>> serializerClass)
> {code}
> to
> {code}
> public void registerTypeWithKryoSerializer(Class<?> type, Class<? extends Serializer> serializerClass)
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)