-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Image generation failed. Exit code: 255 in windows 10 #25954
Comments
I could reproduce this issue Steps to reproduce (Windows machine)
|
The build fails with:
when trying to run
|
The logged warning got my attention, sent PR #26289 because of it. |
We have seen the failure just with "quarkus-jdbc-oracle", not with other jdbc drivers Oracle example was merged 2 days ago - quarkus-qe/quarkus-test-framework#489 Other DBs work fine
(from https://github.com/quarkus-qe/quarkus-test-framework/runs/6975549561?check_suite_focus=true) |
Hmm in @pjgg's run logs though GraalVM is installed in a path without spaces, so this can't be the issue.
Similarly in @pjgg's run logs other tests are working just fine so the issue can't be related to the installation path. Can you please reproduce the issue with |
since it works fine on other DBs, there might be something "special" about the Oracle specific overrides we have put in place to exclude metadata. I see from the logs above it includes "--exclude-config .com.oracle.database.jdbc. /META-INF/native-image/(?:native-image.properties|reflect-config.json) ". The first argument to I'll double-check what I see there when running on linux, but assuming that's the problem I'd need help from someone with a windows box to test any possible fix. |
This is due to the log not being formatted as a code block. The actual argument (as seen in pjgg's log) is:
|
right, this is what I see locally (linux):
so that seems to match, but I guess Windows could use some quotes. Got a draft: #26293 @pjgg could you test it ? I don't have Windows at hand. |
My draft #26293 doesn't work as quotes directly affect the regex (it makes it fail even in Linux). |
Actually this other PR might (unintentionally) fix this ?! If we're packaging the application as an uber-jar, no wonder that the regex doesn't match an actual jar. Too bad I'm only able to guess here - someone with Windows should confirm. cc/ @Karm |
I'm starting to think that However it's true that we need #26289 for the Oracle driver to work correctly in Windows, as otherwise with uber jars the exclusions aren't applied. |
I think I figured out what's going on; this should probably be fixed better in GraalVM, but we can already apply a simple workaround: #26357 |
Describe the bug
I can't do native build with graalvm
I'm execute ./mvnw package -Pnative
I try to compile native using jdbc and specifying the DB credentials in the properties file but I get an error, however this only happens when I add the dependencies
If I try to make the native compilation without these dependencies I can execute it without any problem
Expected behavior
Run a native executable.
Actual behavior
I'm execute ./mvnw package -Pnative and my log return this error:
How to Reproduce?
adding the jdbc and hibernate dependencies and then running mvnw package -Pnative
Output of
uname -a
orver
Windows 10
Output of
java -version
java version "11.0.13" 2021-10-19 LTS Java(TM) SE Runtime Environment 18.9 (build 11.0.13+10-LTS-370) Java HotSpot(TM) 64-Bit Server VM 18.9 (build 11.0.13+10-LTS-370, mixed mode)
GraalVM version (if different from Java)
GraalVM Updater 22.0.0.2
Quarkus version or git rev
2.9.1.Final
Build tool (ie. output of
mvnw --version
orgradlew --version
)Apache Maven 3.8.4 (9b656c72d54e5bacbed989b64718c159fe39b537) Maven home: C:\Users\andre.m2\wrapper\dists\apache-maven-3.8.4-bin\52ccbt68d252mdldqsfsn03jlf\apache-maven-3.8.4 Java version: 17.0.2, vendor: Oracle Corporation, runtime: C:\Program Files\Java\jdk-17.0.2 Default locale: en_US, platform encoding: Cp1252 OS name: "windows 10", version: "10.0", arch: "amd64", family: "windows"
Additional information
The project used is the base one created from https://code.quarkus.io/
The text was updated successfully, but these errors were encountered: