Ravi Sir's Cards › AWS
Init outside handler
This interview card covers Init outside handler. Creating SDK clients inside the handler on every invoke wastes cold and warm time. Reuse clients in the global/init scope across warm invokes. MNC — what belongs outside vs inside the handler?
Read card text
What this card says
What it is
Creating SDK clients inside the handler on every invoke wastes cold and warm time.
Why it matters
Reuse clients in the global/init scope across warm invokes.
init
How / example
MNC: what belongs outside vs inside the handler?
MNC: init.