Duration defaultBackoff(int attempt) { return Duration( milliseconds: (pow(2, attempt) * 100 + Random().nextDouble() * 100).toInt()); }