Multi-Threaded TCP/IP Server Without .NET Socket Class
.NET programmers, learn about a way that can help you write high performance server applications in .NET.
.NET programmers, learn about a way that can help you write high performance server applications in .NET.
By using the Ping class, one of the many classes included in the .NET Framework Library, you can create a simple server monitor that ensures your servers are all responding to network traffic.
Learn about blocking versus unblocking sockets, and about the use of generics and a sample socket connection pool.
Second part of the C# asynchronous socket example, showing more features in socket programming.
This is a simple Client-Server application developed to explain the concept of asynchronous sockets in C#. This extends the socket program to accept multiple clients. Because this example uses Asynchronous methods, threads are not necessary to communicate to multiple clients (though internally the asynchronous communication mechanism uses threads at the OS level).
The security enhancements that the .NET Framework 2.0 made to the TCP channel enable secure TCP communication either through code or application configuration files. Learn how to apply both techniques to .NET remoting clients and servers.
Most articles that illustrate how to send data via sockets tend to focus on sending and receiving simple textual data. While this is certainly useful, one very common practical need is to prefix a length value to the data being sent.
This is a simple C# chat program using asynchronous socket.