This website uses cookies to ensure you get the best experience.
Learn more.
A Lambda function calls DynamoDB on every invocation. Connection setup dominates latency. Invocations may reuse an execution environment. Which implementation reduces repeated setup while avoiding shared user state?
Published
- Cache every response forever in the deployment package directory.
- Initialize the SDK client outside the handler and keep request-specific data within the invocation.
- Create a new SDK client for every record and store customer payloads in globals.
- Assume the same environment will process all future requests and omit recovery code.
Comments — 0
Sign in to comment