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
[WFCORE-6346] Module java.base must open java.net package to all unnamed modules #5498
Conversation
@ropalka @fjuma This seems like something to fix in the 20.x branch as well, for this month's WF 28.0.1, as it seems like a regression in WF 28.0.0 via the upgrade that brought in https://issues.redhat.com/browse/WEJBHTTP-108. |
Good point, thanks @bstansberry. |
Yes, I agree. |
@@ -273,9 +273,11 @@ private void testJPMSArguments(final Collection<String> command, final int expec | |||
assertArgumentExists(command, "--add-exports=java.naming/com.sun.jndi.url.ldap=ALL-UNNAMED", expectedCount); | |||
assertArgumentExists(command, "--add-exports=java.naming/com.sun.jndi.url.ldaps=ALL-UNNAMED", expectedCount); | |||
assertArgumentExists(command, "--add-exports=jdk.naming.dns/com.sun.jndi.dns=ALL-UNNAMED", expectedCount); | |||
assertArgumentExists(command, "--add-opens=java.base/java.lang=ALL-UNNAMED", expectedCount); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems as out of scope of this change.
Double checking if this is intentional.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this is fine; this test is testing that the expected JVM modular options are also used when launching jar files or the server for the tests
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, this was just a missing assert that Rio took the opportunity to correct.
rem Needed for marshalling of proxies | ||
set "DEFAULT_MODULAR_JVM_OPTIONS=!DEFAULT_MODULAR_JVM_OPTIONS! --add-opens=java.base/java.lang.reflect=ALL-UNNAMED" | ||
rem Needed by JBoss Marshalling | ||
set "DEFAULT_MODULAR_JVM_OPTIONS=!DEFAULT_MODULAR_JVM_OPTIONS! --add-opens=java.base/java.io=ALL-UNNAMED" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this intentional? Different open than java.net
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@mchoma This one should be fine, it was already there and down from L53 to keep it in the same order as it was declared in the other files
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, so approving from my side
rem Needed for marshalling of proxies | ||
set "DEFAULT_MODULAR_JVM_OPTIONS=!DEFAULT_MODULAR_JVM_OPTIONS! --add-opens=java.base/java.lang.reflect=ALL-UNNAMED" | ||
rem Needed by JBoss Marshalling | ||
set "DEFAULT_MODULAR_JVM_OPTIONS=!DEFAULT_MODULAR_JVM_OPTIONS! --add-opens=java.base/java.io=ALL-UNNAMED" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@mchoma This one should be fine, it was already there and down from L53 to keep it in the same order as it was declared in the other files
@@ -273,9 +273,11 @@ private void testJPMSArguments(final Collection<String> command, final int expec | |||
assertArgumentExists(command, "--add-exports=java.naming/com.sun.jndi.url.ldap=ALL-UNNAMED", expectedCount); | |||
assertArgumentExists(command, "--add-exports=java.naming/com.sun.jndi.url.ldaps=ALL-UNNAMED", expectedCount); | |||
assertArgumentExists(command, "--add-exports=jdk.naming.dns/com.sun.jndi.dns=ALL-UNNAMED", expectedCount); | |||
assertArgumentExists(command, "--add-opens=java.base/java.lang=ALL-UNNAMED", expectedCount); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this is fine; this test is testing that the expected JVM modular options are also used when launching jar files or the server for the tests
@ropalka When you get a chance, please create a PR against the 20.x branch. Thanks! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ropalka This LGTM but if there isn't one already, please file a JIRA to update https://github.com/wildfly/wildfly/blob/main/pom.xml#L175-L207
Thanks for spotting this out @bstansberry ! Here you go: wildfly/wildfly#16835 |
Thanks, @ropalka and all involved in the review |
https://issues.redhat.com/browse/WFCORE-6346