1 Answer
- Newest
- Most votes
- Most comments
0
For the first part you might consider putting setup code outside the Lambda function handler so that it is only executed once (on cold starts).
For the second part: You don't say what runtime language you're using in Lambda; there are a lot of tips on the web and in our documentation for reducing cold start times for Lambda functions. I'd link to them but without knowing the language I'd suggest instead that you search for "lambda reduce cold start" and add your runtime there.
You might also consider using Lambda Provisioned Concurrency but bear in mind there is a cost for that.
Relevant content
- asked 2 years ago
- asked 6 months ago
- AWS OFFICIALUpdated 2 years ago
- AWS OFFICIALUpdated 2 years ago
- AWS OFFICIALUpdated a year ago