backoff function
Implementation
PollStrategy backoff(num startingThrottleInMsec, num backoffFactor) {
return (
Principal canisterId,
RequestId requestId,
RequestStatusResponseStatus status,
) {
final c = Completer();
Future.delayed(Duration(milliseconds: startingThrottleInMsec.toInt()), () {
startingThrottleInMsec *= backoffFactor;
c.complete();
});
return c.future;
};
}