Running the chat program in the profiler to see which parts are time consuming. The chat program example illustrates the following.
A layered architecture
Design and coding best practices
Thread usage on client and server when using non-blocking sockets
TCP communication with non-blocking sockets