orisgarno opened a new issue, #2628: URL: https://github.com/apache/fory/issues/2628
### Search before asking - [x] I had searched in the [issues](https://github.com/apache/fory/issues) and found no similar issues. ### Version v0.12.2 ### Component(s) Java ### Minimal reproduce step The class is so huge, i cannot pinpoint the problematic field. but the fory setup is: ``` ForyBuilder foryBuilder = Fory.builder() .withLanguage(Language.JAVA) .withRefTracking(true) .withIntCompressed(true) .withLongCompressed(true) .withStringCompressed(true) .withCompatibleMode(CompatibleMode.COMPATIBLE) .withMetaShare(true) .withScopedMetaShare(true) .withMetaCompressor(new DeflaterMetaCompressor()) .requireClassRegistration(false) .withAsyncCompilation(true) .serializeEnumByName(false); ``` while i try with fury 0.9, its totally fine ### What did you expect to see? able to serialize ### What did you see instead? for few first serialize, it works. but minutes later, it shows this error ``` java.lang.ClassCastException: class java.lang.String cannot be cast to class java.lang.Enum (java.lang.String and java.lang.Enum are in module java.base of loader 'bootstrap') \tat org.apache.fory.serializer.EnumSerializer.write(EnumSerializer.java:32) \tat org.apache.fory.serializer.collection.SerializationBinding$JavaSerializationBinding.write(SerializationBinding.java:104) \tat org.apache.fory.serializer.collection.MapLikeSerializer.writeKeyForNullValueChunkGeneric(MapLikeSerializer.java:313) \tat org.apache.fory.serializer.collection.MapLikeSerializer.writeJavaNullChunkGeneric(MapLikeSerializer.java:284) \tat com.censored.FareDetailShownForyRefCodec_1.writeFields12$(FareDetailShownForyRefCodec_1.java:1081) ``` ### Anything Else? _No response_ ### Are you willing to submit a PR? - [x] I'm willing to submit a PR! -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
