xiguashu opened a new issue, #1305:
URL: https://github.com/apache/incubator-fury/issues/1305

   ### Search before asking
   
   - [X] I had searched in the 
[issues](https://github.com/apache/incubator-fury/issues) and found no similar 
issues.
   
   
   ### Version
   
   Fury:  0.4.1
   OS: macOS Big Sur 11.2.3 (20D91)
   JDK: 11.0.12
   
   ### Component(s)
   
   Java
   
   ### Minimal reproduce step
   
       @Test
       public void test() throws IOException {
           String str = "{\"f1\":[{\"ff1\":\"RECRUITCORE\",\"ff2\":\"123\"}]}";
           JSONObject jsonObject = JSONObject.parseObject(str);
   
           Fury fury = Fury.builder()
                   .withLanguage(Language.JAVA)
                   .requireClassRegistration(false)
                   .withCompatibleMode(CompatibleMode.SCHEMA_CONSISTENT)
                   .withAsyncCompilation(true)
                   .build();
   
           byte[] bytes = fury.serialize(jsonObject);
           Object res = fury.deserialize(bytes);
   
       }
   
   ### What did you expect to see?
   
   Get the original jsonObject after deserialization.
   
   ### What did you see instead?
   
   The exception: 
   java.lang.IndexOutOfBoundsException: readerIndex(130) + length(1) exceeds 
size(130): MemoryBuffer{size=130, readerIndex=130, writerIndex=0, 
heapMemory=len(130), heapData=[2, -1, 1, 0, -60, -90, 110, 26, 36, -49, 11, 
-13, 20, 0, 99, 111, 109, 46, 97, 108, 105, 98, 97, 98, 97, 46, 102, 97, 115, 
116, 106, 115, 111, 110, 0, 81, -106, 123, 29, -23, -115, 44, -75, 10, 0, 74, 
83, 79, 78, 79, 98, 106, 101, 99, 116, 1, -1, 0, 2, 102, 49, -1, 1, 1, 0, 0, 0, 
36, 15, -90, 82, 17, 113, -126, -41, 9, 0, 74, 83, 79, 78, 65, 114, 114, 97, 
121, 1, 4, 1, 1, 0, 0, 1, 1, 0, 2, -1, 0, 3, 102, 102, 49, -1, 44, 0, 11, 82, 
69, 67, 82, 85, 73, 84, 67, 79, 82, 69, -1, 0, 3, 102, 102, 50, -1, 44, 0, 3, 
49, 50, 51], heapOffset=0, offHeapBuffer=null, address=16, addressLimit=146}
   
        at io.fury.memory.MemoryBuffer.readByte(MemoryBuffer.java:2002)
        at io.fury.Fury.readJavaStringRef(Fury.java:654)
        at 
io.fury.serializer.collection.MapSerializers$StringKeyMapSerializer.read(MapSerializers.java:328)
        at 
io.fury.serializer.collection.MapSerializers$StringKeyMapSerializer.read(MapSerializers.java:306)
        at io.fury.Fury.readDataInternal(Fury.java:899)
        at io.fury.Fury.readRef(Fury.java:801)
        at io.fury.Fury.deserialize(Fury.java:750)
        at io.fury.Fury.deserialize(Fury.java:681)
   
   ### 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