- 最后登录
- 2021-7-7
- 注册时间
- 2013-9-13
- 阅读权限
- 20
- 积分
- 288
- 纳金币
- 99
- 精华
- 0
|
客户端组织了一个三层ISFSObject的嵌套关系数据,其中有业务中文字符串数据作为ISFSObject的key,能发送到服务端,但是服务端返回客户端时,抛出异常:
Exception: java.nio.BufferOverflowException
Message: *** Null ***
+--- --- ---+
Stack Trace:
+--- --- ---+
java.nio.HeapByteBuffer.put(Unknown Source)
java.nio.ByteBuffer.put(Unknown Source)
com.smartfoxserver.v2.protocol.serialization.DefaultSFSDataSerializer.encodeSFSObjectKey(DefaultSFSDataSerializer.java:1320)
com.smartfoxserver.v2.protocol.serialization.DefaultSFSDataSerializer.obj2bin(DefaultSFSDataSerializer.java:505)
com.smartfoxserver.v2.protocol.serialization.DefaultSFSDataSerializer.object2binary(DefaultSFSDataSerializer.java:491)
com.smartfoxserver.v2.protocol.serialization.DefaultSFSDataSerializer.encodeObject(DefaultSFSDataSerializer.java:830)
com.smartfoxserver.v2.protocol.serialization.DefaultSFSDataSerializer.obj2bin(DefaultSFSDataSerializer.java:508)
com.smartfoxserver.v2.protocol.serialization.DefaultSFSDataSerializer.object2binary(DefaultSFSDataSerializer.java:491)
com.smartfoxserver.v2.protocol.serialization.DefaultSFSDataSerializer.encodeObject(DefaultSFSDataSerializer.java:830)
com.smartfoxserver.v2.protocol.serialization.DefaultSFSDataSerializer.obj2bin(DefaultSFSDataSerializer.java:508)
com.smartfoxserver.v2.protocol.serialization.DefaultSFSDataSerializer.object2binary(DefaultSFSDataSerializer.java:491)
com.smartfoxserver.v2.protocol.serialization.DefaultSFSDataSerializer.encodeObject(DefaultSFSDataSerializer.java:830)
com.smartfoxserver.v2.protocol.serialization.DefaultSFSDataSerializer.obj2bin(DefaultSFSDataSerializer.java:508)
com.smartfoxserver.v2.protocol.serialization.DefaultSFSDataSerializer.object2binary(DefaultSFSDataSerializer.java:491)
com.smartfoxserver.v2.protocol.serialization.DefaultSFSDataSerializer.encodeObject(DefaultSFSDataSerializer.java:830)
com.smartfoxserver.v2.protocol.serialization.DefaultSFSDataSerializer.obj2bin(DefaultSFSDataSerializer.java:508)
com.smartfoxserver.v2.protocol.serialization.DefaultSFSDataSerializer.object2binary(DefaultSFSDataSerializer.java:491)
com.smartfoxserver.v2.protocol.serialization.DefaultSFSDataSerializer.encodeObject(DefaultSFSDataSerializer.java:830)
com.smartfoxserver.v2.protocol.serialization.DefaultSFSDataSerializer.obj2bin(DefaultSFSDataSerializer.java:508)
com.smartfoxserver.v2.protocol.serialization.DefaultSFSDataSerializer.object2binary(DefaultSFSDataSerializer.java:491)
com.smartfoxserver.v2.entities.data.SFSObject.toBinary(SFSObject.java:234)
com.smartfoxserver.v2.protocol.binary.BinaryIoHandler.handleWrite(BinaryIoHandler.java:76)
com.smartfoxserver.v2.protocol.SFSIoHandler.onDataWrite(SFSIoHandler.java:333)
com.smartfoxserver.v2.protocol.SFSProtocolCodec.onPacketWrite(SFSProtocolCodec.java:157)
com.smartfoxserver.bitswarm.core.BitSwarmEngine.writeToSocket(BitSwarmEngine.java:396)
com.smartfoxserver.bitswarm.core.BitSwarmEngine.write(BitSwarmEngine.java:390)
com.smartfoxserver.bitswarm.io.Response.write(Response.java:70)
com.smartfoxserver.v2.api.response.SFSResponseApi.sendExtResponse(SFSResponseApi.java:86)
com.smartfoxserver.v2.api.SFSApi.sendExtensionResponse(SFSApi.java:1338)
com.smartfoxserver.v2.extensions.BaseSFSExtension.send(BaseSFSExtension.java:433)
com.smartfoxserver.v2.extensions.BaseSFSExtension.send(BaseSFSExtension.java:410)
vr.fullControl.vrtest.VrOnlineExtension.SendFpsetData(VrOnlineExtension.java:537)
vr.fullControl.vrtest.simulation.World.processSendFPData(World.java:133)
vr.fullControl.vrtest.handlers.SendFirePowerDataToClient.handleClientRequest(SendFirePowerDataToClient.java:13)
com.smartfoxserver.v2.extensions.SFSExtension.handleClientRequest(SFSExtension.java:208)
com.smartfoxserver.v2.controllers.ExtensionController.processRequest(ExtensionController.java:143)
com.smartfoxserver.bitswarm.controllers.AbstractController.run(AbstractController.java:96)
java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
java.lang.Thread.run(Unknown Source)
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
经过测试,服务端send到客户端时,只要实例化的ISFSObject用中文做了Key就会抛这个异常,求好心人指点下。
但是我的一个朋友测试,他那里是能send到客户端成功的。我的同事测试也会报这个异常。
真心求指教!!!! |
|