Spring Native turns Spring apps into native executables

Spring Native beta release leverages GraalVM to compile Spring Java and Kotlin applications to native images, reducing startup time and memory overhead compared to the JVM.

Spring Native, for compiling Spring Java applications to standalone executables called native images, is now available as a beta release. Native images promise faster startup times and lower runtime memory overhead compared to the JVM.

Launched March 11 and available on start.spring.io, the Spring Native beta compiles Spring applications to native images using the GraalVM multi-language runtime. These standalone executables offer benefits including nearly instant startup (typically fewer than 100ms), instant peak performance, and lower memory consumption, at the cost of longer build times and fewer runtime optimizations than the JVM.

Spring Native supports the Java and Kotlin programming languages. Situations where Spring Native might be a good choice include:

Spring Native allows developers to generate an optimized container image with a minimal OS layer and a small native executable with just the required bits from the Java Development Kit, Spring, and the dependencies needed in an application. The developers behind Spring plan to adapt Spring infrastructure for native images without requiring changes to existing Spring Boot applications.

Copyright © 2021 IDG Communications, Inc.

How to choose a low-code development platform