I found a problem in HTTPRequest.java. Inside the mehtod public HTTPResponse post(String host, int port, boolean isKeepAlive). I think the setting timeout too late, and it should not set after the postSocket = new Socket(host, port); I read the jdk source code, when the socket is created with address and port, the connection will be automatically established. So I think the timeout should be set before socket connecting. Am I right? Thanks for any tips and help.
I have changed as the following.
Please check it :-)