Skip to content

🎥 Make videos programmatically with React

`@remotion/lambda`: Add AWS `ServiceException` to list of retryable errors

Jonny Burgerec98c489c76e
diff --git a/packages/lambda/src/shared/is-flaky-error.ts b/packages/lambda/src/shared/is-flaky-error.ts
index 93ab96e59d..b645b52490 100644
--- a/packages/lambda/src/shared/is-flaky-error.ts
+++ b/packages/lambda/src/shared/is-flaky-error.ts
@@ -86,5 +86,14 @@ export const isFlakyError = (err: Error): boolean => {
return true;
}
+ // ServiceException: We currently do not have sufficient capacity in the region you requested. Our system will be working on provisioning additional capacity. You can avoid getting this error by temporarily reducing your request rate.
+ if (
+ message.includes(
+ 'ServiceException: We currently do not have sufficient capacity in the region you requested',
+ )
+ ) {
+ return true;
+ }
+
return false;
};