I use DefaultHttpClient to fetch data from server, but NoHttpResponseException occurred sporadically.
I refered to this post a link, and
HttpProtocolParams.setUseExpectContinue(httpClient.getParams(), false);
does not work for me.
I use HttpRequestRetryHandler to avoid this problem, and it works, but I don't think this is a perfect method because of the network data package dumped by tcpdump on the server side.
I found that when NoHttpResponseException occured, an new port is used when connecting to the server instead of the old port used before this request(HttpClient does not reuse the old connection). But I didn't find any tcp 3-way handshake data package when the new port from client side connecting to the server side. But based on the tcp theory, handshake is the must step when making an new connection.
I don't know whether it is the bug of android(I'm using android 2.3 for testing), does anyone have idea? Thanks in advance.