Closed kamilwlf closed 9 years ago
@kamilwlf Please provide source code and log tail, if applicable, for the Throwable.
getClient().get("http:/xxx.net/xxx/xxx.json", new AsyncHttpResponseHandler() {
@Override
public void onSuccess(int statusCode, Header[] headers, byte[] responseBody) {
}
@Override
public void onFailure(int statusCode, Header[] headers, byte[] responseBody, Throwable error) {
}
});
@kamilwlf Thanks for that. Can you kindly produce a trace for the exception? And what backend system are you using, if I may ask?
I have a domain which is at issue: http://api.citysdk.waag.org/
another thing is that if the server is overloaded and responds only after about a minute , the data never answered , but as traditionally tested in the browser gets the correct response, of course, after a minute but gets
getClient().setTimeout(90000);
async-http-> 60 sec server lag-> java.net.SocketTimeoutException and statusCode = 0(undefined error) browser-> 60 sec server lag-> correct response
@kamilwlf Is the error code that you see in the browser sent by the backend system? Is it possible for you to catch a screenshot or copy-paste that error from the browser?
there is no error from the browser in the browser gets all the data correctly
685 ms 593 ms...
->history and Previous tests for Tested Load Time Page Size Requests Page Speed December 21 20:13:31 685 ms 2.4 kB 1 100 December 8 22:12:52 593 ms 2.5 kB 1 100 December 8 13:29:02 60.00 s 0 B 1 100 December 8 12:48:20 19.58 s 2.4 kB 1 100 December 8 12:33:36 2.60 s 2.4 kB 1 100 December 8 12:33:06 35.61 s 2.4 kB 1 100 December 8 12:31:24 39.02 s 2.4 kB 1 100 December 8 12:29:54 11.92 s 2.4 kB 1 100
@kamilwlf
Thanks for that. In the browser, and also in Pingdom, I am unable to reproduce a 60-second lag, obviously because the server isn't overloaded at the moment. So I am unable to debug the problem further.
I took a look at the source code where this '0' could come from, and I can see two places (here and here) that send '0' for the status code. The reason, obviously, is because the library cannot determine the cause of the I/O exception from the client-side point of view.
However, if you could submit a trace for the Exception, that would shed more light on this problem.
the server is overloaded daily from 1 p.m to 4 p.m Europe time
Thank you for your time, the problem isn't important to me
Alright @kamilwlf. If this becomes an issue to you, please open a ticket.
onFailure return int statusCode = 0(undefined error) instead of 12002 (Server timeout)
Throwable is corectly: java.net.SocketTimeoutException