This is a NonUI Raspberry Pi App
I send various HTTP messages to three different servers. Some of the requests work every time but others work about 3 out of 4 times. I use timers to try and ensure that I never have more than one HTTP request waiting at any one time, but I get the feeling the failures might be down to me sending a request to one server too quickly after receiving a Success response from the previous request, which may have been from a different server. The failure messages are (I think) coming from the Pi and not the Server and look like this:-
I send various HTTP messages to three different servers. Some of the requests work every time but others work about 3 out of 4 times. I use timers to try and ensure that I never have more than one HTTP request waiting at any one time, but I get the feeling the failures might be down to me sending a request to one server too quickly after receiving a Success response from the previous request, which may have been from a different server. The failure messages are (I think) coming from the Pi and not the Server and look like this:-
B4X:
19:21:29 Post: http://www.**********.com/CommGet.aspx?Originator=NetLinks&Postcode=******&Collator=51341&LastResponseID=1944&LastResponseString=NetLinks,Collator,NetLinksReadInRange,1944,29
java.io.InterruptedIOException: timeout
at okio.AsyncTimeout.exit(AsyncTimeout.java:258)
at okio.AsyncTimeout$2.read(AsyncTimeout.java:215)
at okio.RealBufferedSource.indexOf(RealBufferedSource.java:306)
at okio.RealBufferedSource.indexOf(RealBufferedSource.java:300)
at okio.RealBufferedSource.readUtf8LineStrict(RealBufferedSource.java:196)
at com.squareup.okhttp.internal.http.HttpConnection.readResponse(HttpConnection.java:191)
at com.squareup.okhttp.internal.http.HttpTransport.readResponseHeaders(HttpTransport.java:80)
at com.squareup.okhttp.internal.http.HttpEngine.readNetworkResponse(HttpEngine.java:917)
at com.squareup.okhttp.internal.http.HttpEngine.access$300(HttpEngine.java:95)
at com.squareup.okhttp.internal.http.HttpEngine$NetworkInterceptorChain.proceed(HttpEngine.java:902)
at com.squareup.okhttp.internal.http.HttpEngine.readResponse(HttpEngine.java:760)
at com.squareup.okhttp.Call.getResponse(Call.java:274)
at com.squareup.okhttp.Call$ApplicationInterceptorChain.proceed(Call.java:230)
at com.squareup.okhttp.Call.getResponseWithInterceptorChain(Call.java:201)
at com.squareup.okhttp.Call.execute(Call.java:81)