Add aot-cache module: the JDK 25 AOT cache on Spring Boot 4.1 vs AppCDS, Spring AOT and GraalVM native

A Spring Boot 4.1.1 order service started 12 ways (plain and extracted jar, Spring AOT output, AppCDS, AOT cache trained with and without traffic, JDK 27, native image), ten interleaved rounds each, with first-request latency; 24 cache-mismatch cases; Docker layer arithmetic. Transcripts are in output/ (no docs/ folder).

Co-Authored-By: Claude Sonnet 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01TF9JWFvJSNm6HVzswzZU5a
This commit is contained in:
Claude
2026-09-24 16:44:16 +00:00
parent fa4205f631
commit 3e2029ab3a
30 changed files with 1023 additions and 1 deletions
+11
View File
@@ -0,0 +1,11 @@
#!/usr/bin/env bash
# Builds the GraalVM native image of the same service (no reflection tricks: the app has none). Takes minutes.
source "$(dirname "$0")/env.sh"
cd "$ROOT"; mkdir -p "$WORK"
t0=$(date +%s)
JAVA_HOME=$GRAALVM mvn_run mvn -B -DskipTests -Pnative native:compile > "$WORK/native-build.log" 2>&1
rc=$?
echo "# GraalVM: $("$GRAALVM/bin/native-image" --version 2>&1 | head -1)"
grep -E "types, .* fields, and .* methods found reachable|Peak RSS|Finished generating|BUILD (SUCCESS|FAILURE)|Total time" "$WORK/native-build.log" | sed -E 's/^\[INFO\] //; s/^ +//'
[ $rc -eq 0 ] && cp "target/aot-cache" "$WORK/aot-cache-native" && ls -l "$WORK/aot-cache-native" "$WORK/app.jar" | awk '{printf "%-30s %d MB\n", $NF, $5/1048576}'
echo "build wall time: $(( $(date +%s) - t0 )) s"