When the exception is thrown in PojoSerializer for my Event class,
yoinks
           String subclassName = source.readUTF();            // subclassName 
is “java.lang.Integer”
           try {
                actualSubclass = Class.forName(subclassName, true, cl);
            } catch (ClassNotFoundException e) {
                throw new RuntimeException("Cannot instantiate class.", e);
            }
            subclassSerializer = getSubclassSerializer(actualSubclass);
            target = (T) subclassSerializer.createInstance();                   
     // target is an Integer instead of my Event class??
            // also initialize fields for which the subclass serializer is not 
responsible
            initializeFields(target);



From: Nathan Yu <nuonathan...@twosigma.com>
Sent: Friday, August 13, 2021 8:49 AM
To: JING ZHANG <beyond1...@gmail.com>; Schwalbe Matthias 
<matthias.schwa...@viseca.ch>
Cc: user@flink.apache.org
Subject: RE: Bug with PojoSerializer? java.lang.IllegalArgumentException: Can 
not set final double field Event.rating to java.lang.Integer

Does flink provide any hooks for objects before/after they are 
serialized/deserialized?

Reply via email to