UNPKG

open-next-cdk

Version:

Deploy a NextJS app using OpenNext packaging to serverless AWS using CDK

12 lines (11 loc) 388 B
import { MAXIMUM_RETRY_DELAY } from "./constants"; export const createDefaultRetryToken = ({ retryDelay, retryCount, retryCost, }) => { const getRetryCount = () => retryCount; const getRetryDelay = () => Math.min(MAXIMUM_RETRY_DELAY, retryDelay); const getRetryCost = () => retryCost; return { getRetryCount, getRetryDelay, getRetryCost, }; };