UNPKG

@softchef/cdk-iot-device-management

Version:

IoT device management is composed of things, thing types, thing groups, jobs, files API services. The constructs can be used independently, that are based on full-managed service to create an API Gateway & Lambda function.

5 lines (4 loc) 225 B
import { MAXIMUM_RETRY_DELAY } from "./constants"; export var defaultDelayDecider = function (delayBase, attempts) { return Math.floor(Math.min(MAXIMUM_RETRY_DELAY, Math.random() * Math.pow(2, attempts) * delayBase)); };