Maximilian Michels created FLINK-37546:
------------------------------------------
Summary: KryoSerializer breaks without Twitter Chill library
Key: FLINK-37546
URL: https://issues.apache.org/jira/browse/FLINK-37546
Project: Flink
Issue Type: Bug
Components: API / Type Serialization System
Affects Versions: 2.0.0
Reporter: Maximilian Michels
Assignee: Maximilian Michels
Fix For: 2.0.1
KryoSerializer loads FlinkScalaKryoInstantiator via Reflection which configures
Kryo to use StdInstantiatorStrategy. After FLINK-3154 removed the Twitter Chill
library, this breaks various types. See
https://github.com/EsotericSoftware/kryo/issues/1173
At first, it seemed that the Kryo update caused this but I can reproduce this
also with Kryo 2.24.0 with the Chill library removed.
The fix is to use DefaultInstantiatorStrategy, possible with
StdIstantiatorStrategy as a fallback, e.g.:
{noformat}
Kryo.DefaultInstantiatorStrategy initStrategy = new
Kryo.DefaultInstantiatorStrategy();
initStrategy.setFallbackInstantiatorStrategy(new StdInstantiatorStrategy());
kryo.setStrategy(initStrategy);
{noformat}
Of course, we need to test what other implications this has, but it seems this
would be a new sensible default.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)