Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

java.lang.NoClassDefFoundError: com/oracle/svm/core/jdk/LocalizationFeature #15962

Closed
jerboaa opened this issue Mar 23, 2021 · 3 comments · Fixed by #15971
Closed

java.lang.NoClassDefFoundError: com/oracle/svm/core/jdk/LocalizationFeature #15962

jerboaa opened this issue Mar 23, 2021 · 3 comments · Fixed by #15971
Labels
kind/bug Something isn't working triage/needs-triage
Milestone

Comments

@jerboaa
Copy link
Contributor

jerboaa commented Mar 23, 2021

Describe the bug

When running integration-tests/jpa-mariadb on quarkus master with a recent Graal VM CE build (21.1.0-dev) in -Dnative mode I see NCDFE and ClassNotFoundException for Graal VMs LocalizationFeature. This seems to be related to Quarkus' generated autofeature.

Expected behavior

No stacktrace when generating a native image for integration-tests/jpa-mariadb

Actual behavior

[quarkus-integration-test-jpa-mariadb-999-SNAPSHOT-runner:522013]    classlist:   7,816.03 ms,  1.19 GB
[quarkus-integration-test-jpa-mariadb-999-SNAPSHOT-runner:522013]        (cap):   1,057.90 ms,  1.19 GB
[quarkus-integration-test-jpa-mariadb-999-SNAPSHOT-runner:522013]        setup:   5,911.44 ms,  1.19 GB
java.lang.NoClassDefFoundError: com/oracle/svm/core/jdk/LocalizationFeature
	at io.quarkus.runner.AutoFeature.beforeAnalysis(AutoFeature.zig:1030)
	at com.oracle.svm.hosted.NativeImageGenerator.lambda$runPointsToAnalysis$13(NativeImageGenerator.java:724)
	at com.oracle.svm.hosted.FeatureHandler.forEachFeature(FeatureHandler.java:71)
	at com.oracle.svm.hosted.NativeImageGenerator.runPointsToAnalysis(NativeImageGenerator.java:724)
	at com.oracle.svm.hosted.NativeImageGenerator.doRun(NativeImageGenerator.java:580)
	at com.oracle.svm.hosted.NativeImageGenerator.lambda$run$2(NativeImageGenerator.java:493)
	at java.base/java.util.concurrent.ForkJoinTask$AdaptedRunnableAction.exec(ForkJoinTask.java:1407)
	at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:290)
	at java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1020)
	at java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1656)
	at java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1594)
	at java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:183)
Caused by: java.lang.ClassNotFoundException: com.oracle.svm.core.jdk.LocalizationFeature
	at java.base/java.net.URLClassLoader.findClass(URLClassLoader.java:471)
	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:589)
	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:522)
	... 12 more
17:57:19,926 INFO  [org.hib.Version] HHH000412: Hibernate ORM core version 5.4.30.Final
17:57:19,948 INFO  [org.hib.ann.com.Version] HCANN000001: Hibernate Commons Annotations {5.1.2.Final}
17:57:20,036 INFO  [org.hib.dia.Dialect] HHH000400: Using dialect: org.hibernate.dialect.MariaDB103Dialect

To Reproduce

Steps to reproduce the behavior:

  1. Build quarkus master at revision d185939
  2. Download a GraalVM CE dev build from https://github.com/graalvm/graalvm-ce-dev-builds/releases/tag/21.1.0-dev-20210323_1605
  3. Set GRAALVM_HOME to the downloaded Graal VM CE build
  4. $ ./mvnw verify -Dnative -pl integration-tests/jpa-mariadb/

Environment (please complete the following information):

Linux, Java 11.

GraalVM version (if different from Java)

21.1.0-dev

Quarkus version or git rev

d185939

Build tool (ie. output of mvnw --version or gradlew --version)

$ ./mvnw --version
Apache Maven 3.6.3 (cecedd343002696d0abb50b32b541b8a6ba2883f)
Maven home: /home/sgehwolf/.m2/wrapper/dists/apache-maven-3.6.3-bin/1iopthnavndlasol9gbrbg6bf2/apache-maven-3.6.3
Java version: 11.0.10, vendor: Red Hat, Inc., runtime: /usr/lib/jvm/java-11-openjdk-11.0.10.0.9-1.fc33.x86_64
Default locale: en_US, platform encoding: UTF-8
OS name: "linux", version: "5.11.7-200.fc33.x86_64", arch: "amd64", family: "unix"

Additional context

This seems to be the cause of some remaining problems for the graal master quarkus workflow. See oracle/graal#3272

@jerboaa jerboaa added the kind/bug Something isn't working label Mar 23, 2021
@jerboaa
Copy link
Contributor Author

jerboaa commented Mar 23, 2021

@zakkak @gsmet FYI.

@geoand
Copy link
Contributor

geoand commented Mar 23, 2021

Was the class in question replaced with some other class?

@geoand
Copy link
Contributor

geoand commented Mar 23, 2021

I'll have a look tomorrow morning

geoand added a commit to geoand/quarkus that referenced this issue Mar 23, 2021
geoand added a commit to geoand/quarkus that referenced this issue Mar 24, 2021
geoand added a commit that referenced this issue Mar 24, 2021
Support GraalVM 21.1 LocalizationFeature
@quarkus-bot quarkus-bot bot added this to the 1.14 - main milestone Mar 24, 2021
@gsmet gsmet modified the milestones: 1.14 - main, 1.13.1.Final Apr 3, 2021
gsmet pushed a commit to gsmet/quarkus that referenced this issue Apr 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Something isn't working triage/needs-triage
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants