The fix sets timeout for the server and the client, and ignore SocketTimeoutException. Reviewed-by: chegar
Reviewed-by: weijun