Weekly Dose of Cloud

Share this post

Issue #24: What is AWS Lambda Cold start? And how to avoid it?

weeklydoseofcloud.substack.com

Issue #24: What is AWS Lambda Cold start? And how to avoid it?

Kisan Tamang
Mar 2, 2023
1
Share
Share this post

Issue #24: What is AWS Lambda Cold start? And how to avoid it?

weeklydoseofcloud.substack.com

In this episode, we will talk about AWS lambda Cold start, and how we can solve the problems.

snow field and green pine trees during daytime
Photo by Adam Chang on Unsplash

Lambda cold start is a delay that occurs when a new instance of an AWS Lambda function is initialized for the first time. When a Lambda function is invoked, AWS creates a new instance of the function if there is no existing instance available to handle the request. During this process, AWS initializes the function's execution environment, which includes setting up the operating system, loading the necessary libraries and dependencies, and other configuration tasks.

Thanks for reading Weekly Dose of Cloud! Subscribe for free to receive new posts and support my work.

This initialization process can take time, and the duration of the cold start delay depends on several factors, including the size of the function's code and dependencies, the amount of memory allocated to the function, and the number of concurrent requests being processed by the Lambda service.

Lambda cold start can have a significant impact on the performance of serverless applications, especially those with frequent short-lived invocations or sporadic traffic patterns. To minimize cold start delays, AWS provides several optimization techniques, including pre-warming of Lambda functions, using provisioned concurrency, and optimizing code size and dependencies.

To overcome this problem, AWS recently introduced SnapStart. Learn more about it here: https://docs.aws.amazon.com/lambda/latest/dg/snapstart.html

Thanks for reading Weekly Dose of Cloud! Subscribe for free to receive new posts and support my work.

1
Share
Share this post

Issue #24: What is AWS Lambda Cold start? And how to avoid it?

weeklydoseofcloud.substack.com
Comments
Top
New
Community

No posts

Ready for more?

© 2023 Kisan Tamang
Privacy ∙ Terms ∙ Collection notice
Start WritingGet the app
Substack is the home for great writing