Four Approaches to Reducing Java Startup Time: AppCDS, Native Image, Project Leyden, CRaC
summary
Java services start at ~6.5 s as packaged in Docker and the talk demonstrates four concrete fixes with measured results and gotchas: AppCDS + Spring AOT halves startup (≈50% faster) with a class-archive created at image build, Project Leyden / Java 24 AOT cache gives ~3× reduction using -XX:AOT-cache options, GraalVM native-image produces standalone binaries that run both services under 1 s (≈1.5 s combined) but requires Maven native plugin, many build flags, platform-specific images and long/fragile builds, CRaC restores from checkpoint to ~80 ms but needs Linux, specific JDK builds, extra container capabilities and careful secret handling.
AI-written summary · about
chapters (11)
- 0:00Introduction
- 1:50Meet the heroes
- 6:50Java startup time problem
- 8:12AppCDS solution
- 13:17Project Leyden future
- 18:39Native Image quest
- 24:24Native Image builds
- 30:45CRaC revolution
- 40:22CRaC in Spring
- 43:09Choosing your approach
- 44:31Q&A
related talks
53mFour Approaches to Reducing Java Startup Time
45mProject Leyden: Improving Java’s Startup Time
42mTechniques for a faster JVM start-up
01h 02mOptimizing Containerized #Java Apps with Jib, #GraalVM, CDS, & #CRaC
40mFrom Cold Starts to Escape Velocity: Three Practical Ways to Accelerate Java Services
49mJava and Containers Make it Awesome
59mRuntime Efficiencies and Spring Boot
52mTechniques for a faster JVM start-up
