Adapt AOTCache documentation to JEP 514

Closes gh-47274
This commit is contained in:
Stéphane Nicoll
2025-11-03 15:06:53 +01:00
parent 8345ee5694
commit ba9afc005c
@@ -38,12 +38,10 @@ To use the AOT cache, you should first perform a training run on your applicatio
----
$ java -Djarmode=tools -jar my-app.jar extract --destination application
$ cd application
$ java -XX:AOTMode=record -XX:AOTConfiguration=app.aotconf -Dspring.context.exit=onRefresh -jar my-app.jar
$ java -XX:AOTMode=create -XX:AOTConfiguration=app.aotconf -XX:AOTCache=app.aot -jar my-app.jar
$ java -XX:AOTCacheOutput=app.aot -Dspring.context.exit=onRefresh -jar my-app.jar
----
This creates an `app.aot` cache file that can be reused as long as the application is not updated.
The intermediate `app.aotconf` file is no longer needed and can be safely deleted.
To use the cache file, you need to add an extra parameter when starting the application: