The current loader implementation retries after an error with linear backoff:
|
return Math.min((errorCount - 1) * 1000, 5000); |
Instead it should use exponential backoff to reduce the potential API load in case of many client errors. That could look like this:
private long getRetryDelayMillis() {
return Math.min( Math.pow(errorCount - 1, 2) * 1000, 8000);
}