HttpRequestRetryHandler does not allow you to control the level; if you want to do something very specific, I would recommend implementing something like Handler , where you can send Runnables to start using delay, using, for example, Handler.postDelayed () with an increase in delay according to your formula.
Handler mHandler = new Handler(); int mDelay = INITIAL_DELAY; // try request mHandler.postDelayed(mDelay, new Runnable() { public void run() { // try your request here; if it fails, then repost: if (failed) { mDelay *= 2; // or as per your formula mHandler.postDelayed(mDelay, this); } else { // success! } } });
source share