<!DOCTYPE html><html><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body>
<p>It looks like your classpath have some directories:</p>
<p><br>
[4,648s][error ][cds ] Error: non-empty directory
'/home/danielpelaez/Documents/Distribution/aot/java-aot/build/classes/java/test'<br>
[4,648s][error ][cds ] Error: non-empty directory
'/home/danielpelaez/Documents/Distribution/aot/java-aot/build/classes/java/main'<br>
[4,648s][error ][cds ] Error: non-empty directory
'/home/danielpelaez/Documents/Distribution/aot/java-aot/build/resources/main'</p>
<p><br>
</p>
<p>Please try to package these directories into a JAR file and use
that in your classpath.</p>
<p><br>
</p>
<p>Thanks</p>
<p>- Ioi<br>
</p>
<div class="moz-cite-prefix">On 5/7/25 12:57 PM, Daniel Andres
Pelaez Lopez wrote:<br>
</div>
<blockquote type="cite" cite="mid:CAGTkQmKJh+xm=RRezDDs6jVzFkJkjrLg9pHcpXGz3Kv=d+4_Vg@mail.gmail.com">
<div dir="ltr">
<div>Hi everyone,</div>
<div><br>
</div>
<div>We are testing JEP 483 on JDK 24 using the following dummy
Gradle Spring Boot project: <a href="https://github.com/estigma88/java-aot/tree/master" moz-do-not-send="true" class="moz-txt-link-freetext">https://github.com/estigma88/java-aot/tree/master</a>.
As we want to generate the AOT cache from the tests, we added
a custom Test task to receive the AOT flags for the JVM as
follows:</div>
<div><br>
</div>
<div>tasks.withType<Test> {<br>
useJUnitPlatform()<br>
<br>
project.findProperty("aot")?.let {<br>
val aotFlags = it.toString().split(",")<br>
jvmArgs(aotFlags)<br>
}<br>
}</div>
<div><br>
</div>
<div>And we are using the following commands to generate the AOT
cache:</div>
<div><br>
</div>
<div>./gradlew :test
-Paot="-XX:AOTMode=record,-XX:AOTConfiguration=app.aotconf"
-> This one succeed</div>
<div><br>
</div>
<div>./gradlew :test
-Paot="-XX:AOTMode=create,-XX:AOTConfiguration=app.aotconf,-XX:AOTCache=app.aot"
-> This one fails</div>
<div><br>
</div>
<div>The following are the logs for the create command:</div>
<div><br>
</div>
<div>[1,328s][warning][cds] Preload Warning: Verification failed
for org.springframework.http.client.ReactorResourceFactory<br>
[1,579s][warning][cds] Preload Warning: Verification failed
for
org.springframework.test.context.transaction.TransactionalTestExecutionListener<br>
[1,581s][warning][cds] Preload Warning: Verification failed
for
org.springframework.test.context.jdbc.SqlScriptsTestExecutionListener<br>
[1,668s][warning][cds] Preload Warning: Verification failed
for
org.springframework.boot.logging.log4j2.Log4J2LoggingSystem<br>
[2,412s][warning][cds] Preload Warning: Verification failed
for
org.springframework.http.codec.multipart.DefaultPartHttpMessageReader<br>
[2,575s][warning][cds] Preload Warning: Verification failed
for
org.springframework.boot.autoconfigure.cache.InfinispanCacheConfiguration<br>
[2,577s][warning][cds] Preload Warning: Verification failed
for
org.springframework.boot.autoconfigure.cache.RedisCacheConfiguration<br>
[2,799s][warning][cds] Preload Warning: Verification failed
for
org.springframework.boot.jdbc.init.DataSourceScriptDatabaseInitializer<br>
[3,029s][warning][cds] Preload Warning: Verification failed
for
org.springframework.core.ReactiveAdapterRegistry$ReactorAdapter<br>
[3,109s][warning][cds] Preload Warning: Verification failed
for
org.springframework.boot.http.client.JettyClientHttpRequestFactoryBuilder<br>
[3,110s][warning][cds] Preload Warning: Verification failed
for
org.springframework.boot.http.client.HttpComponentsClientHttpRequestFactoryBuilder<br>
[3,180s][warning][cds] java.lang.ClassNotFoundException:
org.mockito.internal.creation.bytebuddy.inject.MockMethodDispatcher<br>
[3,180s][warning][cds] Preload Warning: Cannot find
org/mockito/internal/creation/bytebuddy/inject/MockMethodDispatcher<br>
[3,196s][warning][cds] Preload Warning: Verification failed
for
org.mockito.internal.creation.bytebuddy.InlineBytecodeGenerator<br>
[3,197s][warning][cds] java.lang.NoClassDefFoundError:
org/mockito/internal/creation/bytebuddy/inject/MockMethodDispatcher<br>
[3,197s][warning][cds] Preload Warning: Cannot find
org/mockito/internal/creation/bytebuddy/MockMethodAdvice<br>
[3,307s][warning][cds] java.lang.ClassNotFoundException:
net.bytebuddy.utility.Invoker$Dispatcher<br>
[3,307s][warning][cds] Preload Warning: Cannot find
net/bytebuddy/utility/Invoker$Dispatcher<br>
[3,906s][warning][cds,resolve] :<br>
An error has occurred while processing class list file
app.aotconf 9635:5.<br>
[3,906s][warning][cds,resolve] @cp
org/mockito/internal/creation/bytebuddy/MockMethodAdvice 1 2 7
9 10 11 17 22 26 28 29 33 36 40 44 48 258<br>
class org/mockito/internal/creation/bytebuddy/MockMethodAdvice
is not (yet) loaded by one of the built-in
loaders[3,906s][warning][cds,resolve] ^<br>
[3,906s][warning][cds,resolve] Your classlist may be out of
sync with the JDK or the application.<br>
An error has occurred while processing class list file
app.aotconf 11862:5.<br>
[4,467s][warning][cds,resolve] :<br>
class
org/mockito/internal/creation/bytebuddy/inject/MockMethodDispatcher
is not (yet) loaded by one of the built-in
loaders[4,467s][warning][cds,resolve] @cp
org/mockito/internal/creation/bytebuddy/inject/MockMethodDispatcher
1 2 8 14 20 25 27 38 59<br>
[4,467s][warning][cds,resolve] ^<br>
[4,467s][warning][cds,resolve] Your classlist may be out of
sync with the JDK or the application.<br>
[4,608s][warning][cds ] Preload Warning: Verification
failed for
org.springframework.web.servlet.view.freemarker.FreeMarkerView<br>
[4,648s][error ][cds ] Error: non-empty directory
'/home/danielpelaez/Documents/Distribution/aot/java-aot/build/classes/java/test'<br>
[4,648s][error ][cds ] Error: non-empty directory
'/home/danielpelaez/Documents/Distribution/aot/java-aot/build/classes/java/main'<br>
[4,648s][error ][cds ] Error: non-empty directory
'/home/danielpelaez/Documents/Distribution/aot/java-aot/build/resources/main'<br>
Hint: enable -Xlog:class+path=info to diagnose the failure<br>
Error occurred during CDS dumping<br>
Cannot have non-empty directory in paths</div>
<div><br>
</div>
<div>Error logs seem related to the AOT feature and not Gradle,
but you will know better.</div>
<div><br>
</div>
<div>Any help would be appreciated.</div>
<div><br>
</div>
<span class="gmail_signature_prefix">-- </span><br>
<div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature">
<div dir="ltr">
<div dir="ltr"><span style="font-family:arial,sans-serif;font-size:13px;border-collapse:collapse;color:rgb(136,136,136)">Daniel</span><br>
<div><span style="font-family:arial,sans-serif;font-size:13px;border-collapse:collapse;color:rgb(136,136,136)">e.
<a href="mailto:estigma88@gmail.com" target="_blank" moz-do-not-send="true" class="moz-txt-link-freetext">estigma88@gmail.com</a></span></div>
</div>
</div>
</div>
</div>
</blockquote>
</body>
</html>