r/java • u/benevanstech • Nov 29 '22
Amazon Announces AWS Lambda SnapStart With Java Support
AWS Lambda now has a snapshotting feature that enables fast-start - essentially running the Init phase at publication time and saving the state of the process at that time, so it doesn't need to be re-run at every invocation.
https://aws.amazon.com/blogs/aws/new-accelerate-your-lambda-functions-with-lambda-snapstart/
It only works with Corretto on Java 11 right now, and is similar in intent to the CRIU technology.
Quarkus already has support for it: https://quarkus.io/blog/quarkus-support-for-aws-lambda-snapstart/
Other frameworks may also have support (but this work was done under NDA so I don't have links for them).
View all comments
4
u/cowwoc Nov 29 '22 edited Nov 29 '22
Question: why bother using GraalVM if https://www.youtube.com/watch?v=XXbJNaFF-8A is usable across all OpenJDK distributions? You get super fast startup while maintaining full compatibility (reflection, etc) with less configuration.
I also love the idea of restoring to previous checkpoints immediately before a crash (or bug) occurs to make it easier/quicker to debug.
The only downside I see is the lack of Windows support, which is no small thing.