@message-queue-toolkit/core
Version:
Useful utilities, interfaces and base classes for message queue handling. Supports AMQP and SQS with a common abstraction on top currently
11 lines • 359 B
JavaScript
/**
* Check if the retry date is exceeded
*
* @param timestamp
* @param maxRetryDuration max retry duration in seconds
*/
export const isRetryDateExceeded = (timestamp, maxRetryDuration) => {
const lastRetryDate = new Date(timestamp.getTime() + maxRetryDuration * 1000);
return new Date() > lastRetryDate;
};
//# sourceMappingURL=dateUtils.js.map