Skip to content

Commit

Permalink
Limit max execution time (i.e. timeout) to 29 seconds for Backend Ima…
Browse files Browse the repository at this point in the history
…ge Handler Lambda Function since Api Gateway on front has that limitation.
  • Loading branch information
fvsnippets authored and Federico Valido committed Oct 8, 2023
1 parent 29fe1e7 commit 9bd9e18
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion source/constructs/lib/back-end/back-end-construct.ts
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ export class BackEnd extends Construct {
description: `${props.solutionName} (${props.solutionVersion}): Performs image edits and manipulations`,
memorySize: 1024,
runtime: Runtime.NODEJS_16_X,
timeout: Duration.minutes(15),
timeout: Duration.seconds(29),
role: imageHandlerLambdaFunctionRole,
entry: path.join(__dirname, "../../../image-handler/index.ts"),
environment: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1205,7 +1205,7 @@ exports[`Serverless Image Handler Stack Snapshot 1`] = `
"Value": "S0ABC",
},
],
"Timeout": 900,
"Timeout": 29,
},
"Type": "AWS::Lambda::Function",
},
Expand Down

0 comments on commit 9bd9e18

Please sign in to comment.