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

Check that no dependencies include native-image metadata #16062

Open
Sanne opened this issue Mar 26, 2021 · 2 comments
Open

Check that no dependencies include native-image metadata #16062

Sanne opened this issue Mar 26, 2021 · 2 comments
Labels
area/build area/native-image help wanted Extra attention is needed kind/enhancement New feature or request

Comments

@Sanne
Copy link
Member

Sanne commented Mar 26, 2021

Description

Library maintainers are now encouraged to add metadata for native-image within the jar files to improve the out-of-the-box experience on GraalVM native.

This is great as it will likely, on average, reduce the friction to adopt native-image in the larger ecosystem; however we've already witnessed that in some cases such metadata might be incompatible with flags from other libraries, or just have a different impact than what the original author intended.

My proposal is to introduce some assertions in our build to verify that no 3rd party library we depend on has any such metadata; that's not to say we want to ban them, but this is meant to make sure we actually notice when some apparently innocent version upgrade of a random library pulls in new flags on the classpath, so that we get a chance to investigate them and test them, and possibly apply corrective measures.

@zakkak
Copy link
Contributor

zakkak commented Apr 2, 2021

👍 #16139 and #15434 seem to be caused by such native-image metadata.

Detecting such metadata and overriding the offending parts with oracle/graal#3179 (expected to land in GraalVM 21.2.0 on Jul 20 2021) would be nice!

@zakkak
Copy link
Contributor

zakkak commented Nov 29, 2022

FTR #29413 is also caused by such native-image metadata.

@Sanne Sanne added the help wanted Extra attention is needed label Nov 29, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/build area/native-image help wanted Extra attention is needed kind/enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants