This is quite brilliant/better way to do TCP comms in my opinion.
Looking to build on top of this idea for multiple “clients” connecting with TCP. Just to confirm, would I be correct in saying that I can “Store” a list of the “Connections” that’s currently in your “program.cs” that I can then use to reference when I want to initiate sending a message from the “server” to the client. Obviously while the “client” is still connected, even though the client might not be sending data to the “server” at the moment, the connection can still be open, therefor allowing messages being sent to the client at any time, up until the client disconnects or the connection is closed from the server side..
Is there a way that I can contact you directly with regard to some ideas / questions I have on this topic please.
A good insight. Also worth looking at davidfowl/MultiProtocolAspNetCore for the TCP server built into Kestrel as standard (which sits on top of Bedrock) using the IDuplexPipe and got much faster in .Net 7 after they ditched libuv.
Great write-up! What will happen if the client is sending large amounts of data and but reading very slowly? Would more and more data keep buffering in the memory pools?
Comments about Building a High Performance TCP Server in C#
This is quite brilliant/better way to do TCP comms in my opinion.
Looking to build on top of this idea for multiple “clients” connecting with TCP. Just to confirm, would I be correct in saying that I can “Store” a list of the “Connections” that’s currently in your “program.cs” that I can then use to reference when I want to initiate sending a message from the “server” to the client. Obviously while the “client” is still connected, even though the client might not be sending data to the “server” at the moment, the connection can still be open, therefor allowing messages being sent to the client at any time, up until the client disconnects or the connection is closed from the server side..
Is there a way that I can contact you directly with regard to some ideas / questions I have on this topic please.
Will be Greatly appreciated :)
😊+
A good insight. Also worth looking at davidfowl/MultiProtocolAspNetCore for the TCP server built into Kestrel as standard (which sits on top of Bedrock) using the IDuplexPipe and got much faster in .Net 7 after they ditched libuv.
😊+
Great write-up! What will happen if the client is sending large amounts of data and but reading very slowly? Would more and more data keep buffering in the memory pools?
😊+