Skip to content

Commit 7926070

Browse files
committed
feat(sdk): configure Lambda client timeouts
Add connection and socket timeout configurations to LambdaClient to improve reliability: - connectionTimeout: 5000ms (5 seconds) - socketTimeout: 50000ms (50 seconds) This helps prevent hanging requests and provides better error handling for Lambda API calls.
1 parent efa419a commit 7926070

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

packages/aws-durable-execution-sdk-js/src/storage/api-storage.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,12 @@ export class ApiStorage implements ExecutionState {
1717
protected client: LambdaClient;
1818

1919
constructor() {
20-
this.client = new LambdaClient();
20+
this.client = new LambdaClient({
21+
requestHandler: {
22+
connectionTimeout: 5000,
23+
socketTimeout: 50000,
24+
},
25+
});
2126
}
2227

2328
/**

0 commit comments

Comments
 (0)