Hi devs, Currently I am working on some changes to serializer for NFA class in CEP library. I am trying to understand how the TypeSerializer#ensureCompatibility feature works.
What I want to do is in a previous version (e.g. in 1.3.0) some information was serialized that now shouldn't. In TypeSerializer#ensureCompatibility I am setting a flag based on corresponding ConfigSnapshot version that tells me if that additional info should be read. So let’s get to the point :). Unfortunately it does not work for HeapStateBackend as during restoring the StateBackend the method TypeSerializer#ensureCompatibility is not invoked and the state value is eagerly deserialized with the not reconfigured serializer. It does work though for RocksDBStateBackend, as while restoring there is no deserialisation of the value(lazy deserialization). It is first deserialized when accessing (getColumnFamily etc. I suppose) and then the method ensuringCompatibility is called and the serializer is properly reconfigured. My questions are: - is my serialization plan ok, with setting the flag - are the different behaviours intended or is it a bug for HeapStateBackend If it is a bug, I would be willing to fix it(or at least try), but probably I will need some guidance. Regards Dawid
signature.asc
Description: Message signed with OpenPGP