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

Handle Enable-Native-Access manifest attribute if present #10009

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

zakkak
Copy link
Collaborator

@zakkak zakkak commented Nov 1, 2024

Closes #10008

@oracle-contributor-agreement oracle-contributor-agreement bot added the OCA Verified All contributors have signed the Oracle Contributor Agreement. label Nov 1, 2024
@zakkak zakkak requested a review from zapster November 1, 2024 11:50
@zapster
Copy link
Member

zapster commented Nov 4, 2024

thanks for the contribution @zakkak. I'll have a look as soon as time allows.

@zapster
Copy link
Member

zapster commented Nov 12, 2024

Sorry for the delay, @zakkak. A lot of side tracking this week. I agree that #10008 is something we need to fix. In the current state, --enable-native-access is only about the image builder itself. At image run time, all native access check are currently disabled (aka all native access is allowed to all modules). This is about to change. I've pushed the current proposal to #10076. It is not yet fully ready, but the basics should be there. I'll need to do further testing, especially with external projects, though. Feedback from your sides is also very welcome.

That said, I believe that #10076 will break this PR, or at least partially defeat its purpose. I suggest we wait until #10076 lands and then revisit this and #10008. Would that work for you?

@zakkak
Copy link
Collaborator Author

zakkak commented Nov 12, 2024

Thank you for the update @zapster .

Would that work for you?

Yes, that's fine with us. As said in quarkusio/quarkus#44257 (comment) this is still a warning.

@zakkak
Copy link
Collaborator Author

zakkak commented Nov 12, 2024

I'll need to do further testing, especially with external projects, though. Feedback from your sides is also very welcome.

Quarkus is not using modules, so I am not sure how much we can test this on our side other than passing --enable-native-access=ALL-UNNAMED. If there is anything specific you would like me to try, let me know.

@zapster
Copy link
Member

zapster commented Nov 12, 2024

Quarkus is not using modules, so I am not sure how much we can test this on our side

That is totally fine. Out of interest, are you already passing --enable-native-access=ALL-UNNAMED to the image builder, or are do you intend to set this via the manifest attribute (#10008)?

@zakkak
Copy link
Collaborator Author

zakkak commented Nov 12, 2024

No, we currently don't do anything about it. For some cases setting it via the manifest attribute would be enough, but we will definitely need to pass --enable-native-access in other cases such as testing, dev-mode, etc.

The Quarkus issue tracking this is quarkusio/quarkus#44257.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
OCA Verified All contributors have signed the Oracle Contributor Agreement. redhat-interest
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Native Image] GraalVM for JDK 24 ignores manifest entry Enable-Native-Access
2 participants