retryWithExponentialBackoff
fun <T> Flow<T>.retryWithExponentialBackoff(minMillis: Long = 100, maxMillis: Long = 60000, onRetry: suspend (Throwable, Long) -> Boolean = { _, _ -> true }): Flow<T>(source)
On an error, Retry on the upstream with an exponential delay between each attempt. Behaviour can be modified by proving onRetry - if a call to this returns false
it will stop retrying and propagate the error downstream.