Spring Boot BackgroundPreinitializer

ioi.lam at oracle.com ioi.lam at oracle.com
Tue Oct 8 04:45:25 UTC 2024


On 10/7/24 3:29 PM, John Rose wrote:
> On 4 Oct 2024, at 3:29, Sebastien Deleuze wrote:
>
>
>> Side note: we really hope that a "-XX:CacheDataStore=app.cds" successor
>> will be introduced because it really helps to not have to change the java
>> command line between training and deployment runs for some deployment
>> scenarios.
> We should have a tracking RFE for this; I think Ioi
> might have one.
>
> — John


I updated https://bugs.openjdk.org/browse/JDK-8338476 to include two 
variants
of creating Leyden-enabled AOT caches:

[1] Identical replacement of the -XX:CacheDataStore flag (aka "one step 
workflow",
     where the AOT cache is created with a single "java" command).

      java -XX:CacheDataStore=app.cds -cp app.jar App
=>
      java -XX:AOTMode=autocreate -XX:AOTCache=app.aot -cp app.jar App

     - If app.aot exists, it will be used to run the application
     - Otherwise, app.aot will be created when the application exits

[2] "Two step work flow" (as proposed in JEP 483), where two "java" 
commands are
     executed: one to perform the training run, the other to perform the 
assembly phase.

     java -XX:AOTMode=record -XX:AOTConfiguration=foo.aotconfig -cp 
app.jar App
     java -XX:AOTMode=create -XX:AOTConfiguration=foo.aotconfig 
-XX:AOTCache=foo.aot -cp app.jar



More information about the leyden-dev mailing list