Skip to content

Native Image Feasibility

LoomCache does not currently ship a GraalVM native executable. The supported production path is the JVM Docker image and Kubernetes manifests in the deployment guide.

AreaStatusNotes
Spring Boot AOTFeasibleloom-spring-boot completes spring-boot:process-aot when both the AOT JVM and generated-source compiler receive --enable-preview.
Native executableNot shippedCI does not require native-image, and no native artifact is part of the release contract.
Java runtimeHigh frictionServer classes use Java 25 preview features, so AOT and native builds must pass preview flags consistently.
Dynamic featuresNeeds metadataServiceLoader, Class.forName(...), Kryo registrations, JDBC drivers, optional OpenTelemetry, and user serializers need reachability metadata.

Native-image support is therefore experimental research, not a production feature.

The REL.8 audit used this successful AOT probe:

Terminal window
mvn clean install -q \
-DskipTests \
-DskipITs \
-DskipIntegrationTests \
-pl loom-spring-boot \
-am
mvn -q \
-DskipTests \
-DskipITs \
-DskipIntegrationTests \
-Dspring-boot.aot.jvmArguments=--enable-preview \
-Dspring-boot.aot.compilerArguments=--enable-preview \
-pl loom-spring-boot \
spring-boot:process-aot

The same audit found no local native-image binary, so it did not produce or certify a native executable.

Before LoomCache can publish a native artifact:

  1. Add a loom-spring-boot native profile using GraalVM Native Build Tools.
  2. Pass Java 25 preview flags to the native-image build and Spring AOT phases.
  3. Check in reachability metadata for serializer providers, dynamic class loaders, JDBC drivers, optional tracing, TLS, and user-configured comparators.
  4. Decide which JVM-only operational features are disabled in native mode.
  5. Build the Linux native executable in CI with GraalVM JDK 25.
  6. Run native smoke tests for health, binary map operations, WAL restart, metrics, TLS startup, and serializer failures.

Until those gates land, use the JVM image from Kubernetes & Docker Deployment.