Ivan Shynkarenka

Results 148 comments of Ivan Shynkarenka

Please try this fragment of code with 3.0.14 NetCoreServer: ``` if (line == "send") { int bufferSize = 1024 * 1024; var buffer = Enumerable.Repeat((byte)'.', bufferSize).ToArray(); int count = 3...

You can use `OptionReceiveBufferSize` and `OptionSendBufferSize` options in Client/Session for your case: ``` // Prepare receive & send buffers _receiveBuffer.Reserve(OptionReceiveBufferSize); _sendBufferMain.Reserve(OptionSendBufferSize); _sendBufferFlush.Reserve(OptionSendBufferSize); ```

aah ok, I understand the issue. Will fix it soon!

TcpSessoin._receiveBuffer can become bigger than a single packet size. As the result Socket.ReceiveAsync() can receive bigger buffer at single operation. I think it is your case and you get OnReceived()...

Also pay attention that your client should receive/consume data faster than server send/produce it. Otherwise some back-pressure logic have to be implemented on the top of server/client to limit buffer...

Send(Message1), Send(Message2) - the order will be preserved, but you may receive partial data as OnReceived(Message1.1), OnReceived(Message1.2), OnReceived(Message1.3), OnReceived(Message2.1), OnReceived(Message2.2). So the good way is to have upper level protocol,...

Yes just host one or more servers in your AppService, bind them to different ports and start them: ``` var content = new HttpsServer(context, IPAddress.Any, 8443); var chat = new...

Can you briefly describe benefits of using dotnetty.buffers or some good use cases? Currently NetCoreServer requires only two (send & receive) buffers per session. The buffer is very simple dynamic...

This example shows exactly what you need: https://github.com/chronoxor/NetCoreServer/blob/master/examples/WssChatServer/Program.cs

.NET Framework 4.6: Install-Package NetCoreServer -Version 1.9.0 .NET Core 2.0: Install-Package NetCoreServer -Version 2.0.0 .NET Core 3.0: Install-Package NetCoreServer -Version 3.0.0