AWS Banner

Lambda SnapStart

AWS re:Invent is in full swing and with it come new services that people have been asking for. While these new services are exciting, the even more exciting things are improvements to existing services that users benefit from with zero change to anything they have done. One of the best examples is reducing the billing interval from 100ms to 1 ms for lambda. (read more about that here)


Well AWS has done it again. This time they have eliminated the cold starts for Lambda. 


What is a Cold Start?


Lambdas are Serverless functions that users write code for and it runs on an ultra small vm that AWS manages and maintains. These are great for paying for only when code is executing and not any other time. The trade off is that if you have a burst of traffic or a lambda hasn’t been used in a while, it could result in AWS needing to turn on a new lambda function. 

For some languages like python or Node.js these can be pretty short 1-2 seconds which is bearable, (though I hope AWS does this for all languages soon.) For a heavier framework like  Java, this can be up to 40 seconds. 


How it works:

There are lots of technical details to get this to work, but there are two main things AWS did to solve the problem. 

  1. Instead of using the base state for a Java VM, They are now taking incremental snapshots of the VM in a fully initialized state. This means that it comes up ready to work. 
  2. Like streaming a video, AWS is loading these images as the copy. Starting with the most important blocks and then ensuring the other blocks are there when they are needed. 


What does this mean: 

More Serverless everywhere. A number of enterprises we work with prefer Java. It is a dependable code language, and is already in use at many of these organizations. With the barrier of cold start removed I imagine that more and more of them will start using Serverless technologies. Which further help the cloud reduce cost and improve scalability. 


Date posted: December 2, 2022

Add new comment

Restricted HTML

  • Allowed HTML tags: <a href hreflang> <em> <strong> <cite> <blockquote cite> <code> <ul type> <ol start type> <li> <dl> <dt> <dd> <h2 id> <h3 id> <h4 id> <h5 id> <h6 id>
  • You can enable syntax highlighting of source code with the following tags: <code>, <blockcode>, <cpp>, <java>, <php>. The supported tag styles are: <foo>, [foo].
  • Web page addresses and email addresses turn into links automatically.
  • Lines and paragraphs break automatically.

Metal Toad is an Advanced AWS Consulting Partner. Learn more about our AWS Managed Services

About the Author

Nathan Wilkerson, VP of Engineering

Nathan started building computers, programming and networking with a home IPX network at age 13. Since then he has had a love of all things computer; working in programming, system administration, devops, and Cloud Computing. Over the years he's enriched his knowledge of computers with hands on experience and earning his AWS Certified Solutions Architect – Professional.

Recently, Nathan has transitioned to a Cloud Operations Manager role. He helps clients and internal teams interface with the Cloud Team using the best practices of Kanban to ensure a speedy response and resolution to tickets.

Schedule a Free Consultation

Speak with our team to understand how Metal Toad can help you drive innovation, growth, and success.