I am having a problem with a client-server TCP connection.
I am trying to set up a TCP connection to the client from my server (MS windows system).
The server sends an ARP request to the client, in my case the client is down, so the server receives no response.
The server then waits for about 20seconds before it eventually times out.
Is there anyyway that I could reduce the length of timeout in this situation? and if so how would I go about doing it?
I have heard that the default timeout is 20seconds a windows system, is there an any way to reduce this timeout?
One way is to use non-blocking sockets and set a timeout on the operation. Exactly how you set up a timeout depends on the event loop you are using.