Issue
What workflow (automated pipeline) can I use to create a container image from my Spring Boot application for deployment on Kubernetes that utilises the fast startup functionality provided by CRaC's checkpoint/restore logic?
There has already been ideas involving Paketo Buildpacks mentioned in this: GitHub Issue Please check them out too when you come across here.
Question
Can anyone apply the core CRaC approach described in JVM Checkpoint Restore to a fully automated workflow/pipeline for applications that are built and deployed on a Kubernetes platform?
Background
On cloud platforms, it is essential for a container to start within seconds (or even sub-second) to ensure a scale-to-zero approach like FaaS or to use horizontal autoscaling. One way of achieving this is native image builds, but not all existing Spring Boot applications support this or can accept it's trade-offs. The emerging alternative, based on CRaC, is available in two JDKs now: Liberica and Azul Zulu
Using Paketo Buildpacks like the one from BellSoft is a very efficient and powerful way for building container images from source code, even though the choice for the two CRaC enabled JDKs has not yet been added to this particular pack.
As an introduction to CRaC, check out Sébastien's talk at the Devoxx 2023 conference.
Tried already
I've tried to use a Tekton pipeline on Kubernetes to execute the necessary steps and build the Spring Boot application using the existing Paketo Buildpack. This pack lets you choose between a few different JDK distributions but CRaC enabled JDKs are not included at this point.
I hope, the Buildpack will offer this soon. Then I might be able to build the Tekton pipeline around it. The challenge of the checkpoint creation and it's storage/publishing for future fast starts can be handled in a Kubernetes environment but has not been documented yet.
But I would be interested in any fully automated build pipelines (including creating checkpoint and using it in Kubernetes deployments) that others have implemented already.