Skip to content

ClientProtocolException – Not any more

July 22, 2012

During my tests with the Android emulator I came across this error quite frequently and repeatedly:

org.apache.http.client.ClientProtocolException
Caused by: org.apache.http.client.NonRepeatableRequestException: Cannot retry request with a non-repeatable request entity

I dont know why it happens, but if the request fails once, the Http library usually retries the request if it can. Since I was uploading files using streams (since they are too large), the Http library cannot retry the request (for whatever reason it fails). However, I stopped getting this error until I saw something similar in the crash logs I get from the market. I knew what was going on so I have added my own retry logic, which attempts to re-upload the stream 5 times, then if it fails it aborts.

Apart from this update there are a few other changes. Interesting one is the ‘Start at boot’ feature that allows the app to be started at boot if the phone is restarted for any reason, so you do not lose your scheduled pipes.

There are many other minor things I need to update as well, hope I get time soon for a quick update.

Advertisements
No comments yet

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: