KouShenhai opened a new issue, #2785:
URL: https://github.com/apache/fory/issues/2785

   ### Search before asking
   
   - [x] I had searched in the [issues](https://github.com/apache/fory/issues) 
and found no similar issues.
   
   
   ### Version
   
   version: 0.12.3
   openjdk: 25
   os: Arch Linux aarch64
   
   ### Component(s)
   
   Java
   
   ### Minimal reproduce step
   
   ```java
   public final class ForyFactory {
   
        private static final ForyFactory FACTORY = new ForyFactory();
   
        private final ThreadSafeFory fory = new 
ForyBuilder().withLanguage(Language.JAVA)
                        // enable reference tracking for shared/circular 
reference.
                        // Disable it will have better performance if no 
duplicate reference.
                        .withRefTracking(false)
                        // compress int for smaller size
                        .withIntCompressed(true)
                        // compress long for smaller size
                        .withLongCompressed(true)
                        // enable type forward/backward compatibility
                        // disable it for small size and better performance.
                        .withCompatibleMode(CompatibleMode.COMPATIBLE)
                        // enable async multi-threaded compilation.
                        .withAsyncCompilation(true)
                        .requireClassRegistration(false)
                        .buildThreadSafeFory();
   
        public static ForyFactory getFuryFactory() {
                return FACTORY;
        }
   
        public byte[] serialize(Object object) {
                if (object == null) {
                        return new byte[0];
                }
                return fory.serialize(object);
        }
   
        public Object deserialize(byte[] bytes) {
                if (bytes == null) {
                        return null;
                }
                return fory.deserialize(bytes);
        }
   
   }
   ````
   
   ### What did you expect to see?
   
   Successful serialization
   
   ### What did you see instead?
   
   ```java
   ### Error updating database.  Cause: 
org.apache.fory.exception.SerializationException: java.lang.InternalError: a 
fault occurred in an unsafe memory access operation
   ### The error occurred while executing an update
   ### Cause: org.apache.fory.exception.SerializationException: 
java.lang.InternalError: a fault occurred in an unsafe memory access operation] 
with root cause
   java.lang.InternalError: a fault occurred in an unsafe memory access 
operation
        at java.base/jdk.internal.misc.Unsafe.putLong(Native Method) ~[?:?]
        at [email protected]/sun.misc.Unsafe.putLong(Unsafe.java:370) 
~[?:?]
        at 
org.apache.fory.memory.MemoryBuffer.writeInt64(MemoryBuffer.java:714) 
~[fory-core-0.13.0-SNAPSHOT.jar!/:0.13.0-SNAPSHOT]
        at 
org.apache.fory.serializer.CompatibleSerializer.write(CompatibleSerializer.java:95)
 ~[fory-core-0.13.0-SNAPSHOT.jar!/:0.13.0-SNAPSHOT]
        at 
org.apache.fory.serializer.collection.ChildContainerSerializers$ChildCollectionSerializer.onCollectionWrite(ChildContainerSerializers.java:145)
 ~[fory-core-0.13.0-SNAPSHOT.jar!/:0.13.0-SNAPSHOT]
        at 
org.apache.fory.serializer.collection.ChildContainerSerializers$ChildCollectionSerializer.onCollectionWrite(ChildContainerSerializers.java:126)
 ~[fory-core-0.13.0-SNAPSHOT.jar!/:0.13.0-SNAPSHOT]
        at 
org.apache.fory.serializer.collection.CollectionLikeSerializer.write(CollectionLikeSerializer.java:317)
 ~[fory-core-0.13.0-SNAPSHOT.jar!/:0.13.0-SNAPSHOT]
        at org.apache.fory.Fory.writeData(Fory.java:652) 
~[fory-core-0.13.0-SNAPSHOT.jar!/:0.13.0-SNAPSHOT]
        at org.apache.fory.Fory.write(Fory.java:403) 
~[fory-core-0.13.0-SNAPSHOT.jar!/:0.13.0-SNAPSHOT]
        at org.apache.fory.Fory.serialize(Fory.java:323) 
~[fory-core-0.13.0-SNAPSHOT.jar!/:0.13.0-SNAPSHOT]
        at org.apache.fory.Fory.serialize(Fory.java:295) 
~[fory-core-0.13.0-SNAPSHOT.jar!/:0.13.0-SNAPSHOT]
        at org.apache.fory.ThreadLocalFory.serialize(ThreadLocalFory.java:98) 
~[fory-core-0.13.0-SNAPSHOT.jar!/:0.13.0-SNAPSHOT]
   ```
   
   ### Anything Else?
   
   _No response_
   
   ### Are you willing to submit a PR?
   
   - [ ] 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]

Reply via email to