.NET6.0 How to reach 10 gigabits per second with TCP sockets?
Is it realistic in C# Socket(AddressFamily.InterNetwork, SocketType.Stream, ProtocolType.Tcp); to get a data transfer rate of 10 gigabits per second on 10 thousand connections on Ryzen 7 5800 with SSD + windows 10??? Unfortunately the maximum speed I was able to achieve was 1.69 gigabits per second on .Net6.0 (in the release version) and a project on netstandard2.0 as a library. I tested on localhost:8080. With the same nginx the speed reaches 8.5, 10 gigabits per second. Is there any simple code that can pull this or at least an example from github in C# that can easily realize such data transfer speed? The buffer size is specified in socket.ReceiveBufferSize = 8123; socket.SendBufferSize = 8123; socketAsyncEventArgs.SetBuffer(new byte[8123], 0, 8123); SocketAsyncEventArgs only solves the problem of 10000 connections. Tried setting thread pool sizes as: