You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am using TcpListener to transfer data from client to Server, This is service writing early 1000 lines with 4000 chars in one minutes.
Once I connected with server, code passing 1000 calls to server. I am using msgPack to send the data.
When I send the data in sync it's working fine, but If i am using Async, after 2 item, the channel got break.
Following is the sample code, basically we are using this for application logging, so from the application we are passing log information using msgPack.
System.Runtime.Serialization.SerializationException: Unpacker is not in the array header at offset 0. The stream may not be array.
at MsgPack.Serialization.SerializationExceptions.ThrowIsNotArrayHeader(Unpacker unpacker)
at MsgPack.Serialization.EmittingSerializers.Generated.System_Tuple_3_System_Int32_System_Int32_System_String_Serializer2.UnpackFromAsyncCore(Unpacker , CancellationToken )
at MsgPack.Serialization.MessagePackSerializer`1.UnpackFromAsync(Unpacker unpacker, CancellationToken cancellationToken)
at MsgPack.Serialization.MessagePackSerializer`1.UnpackAsync(Stream stream, CancellationToken cancellationToken)
The text was updated successfully, but these errors were encountered:
Thank you for feedback and sorry for delayed response.
I recognized that packer wrote broken binary because of the exception. I think it is important for logging to have error resistance unpacking, but I have no good idea for it now. I guess we cannot detect broken range automatically.
It is welcome to discuss the solution, or point out my misunderstanding. Thank you.
Hi,
I am using TcpListener to transfer data from client to Server, This is service writing early 1000 lines with 4000 chars in one minutes.
Once I connected with server, code passing 1000 calls to server. I am using msgPack to send the data.
When I send the data in sync it's working fine, but If i am using Async, after 2 item, the channel got break.
Following is the sample code, basically we are using this for application logging, so from the application we are passing log information using msgPack.
`using (var stream = _tcpClient.GetStream())
{
In the server code am getting below error
The text was updated successfully, but these errors were encountered: