Open Frnd-me opened 5 months ago
I am using the following as a workaround:
someEnumIn = SomeEnum.valueOf(someEnumIn.name());
Hi @Frnd-me, could you use withLanguage(Language.JAVA)
instead? Enum is not supported in xlang serialization for now., though fury serialization spec has included enum serialization protocol. Currently enum will be serialized as an struct, which is why deserialized value is not same reference
I could try that, but that would imply that the cross-language serialization and deserialization would not work. I am trying to use Fury specifically for this feature.
I could try that, but that would imply that the cross-language serialization and deserialization would not work. I am trying to use Fury specifically for this feature.
We're reactoring fury cross-language serialization. Could you hold this for some time? BTW, which languages you used fury for xlang serialization
Sure, I will temporarily switch to Protocol Buffers, but I'll keep an eye on Fury. My system is implemented in Java, but would require cross-language serialization and deserialization from a range of other languages. I was currently testing Java <-> Python, but I can also see at least C++ and Go to be important languages for us.
Search before asking
Version
0.4.1
Component(s)
Java
Minimal reproduce step
What did you expect to see?
I expect a test for equality of the original and deserialized enum values to result in a true value.
What did you see instead?
After deserializing, a test for equality of the deserialized enum value with the original value yields false.
Anything Else?
This must have something to do with Java's enums being singletons.
Are you willing to submit a PR?