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

upgraded javassist to 3.23.1-GA to suppress warning with JDK9+ #1247

Merged
merged 2 commits into from
Jul 23, 2018
Merged

upgraded javassist to 3.23.1-GA to suppress warning with JDK9+ #1247

merged 2 commits into from
Jul 23, 2018

Conversation

tomparle
Copy link
Contributor

In addition to #1245 that fix JDK9+ compatibility (see #1200), upgrade javassist to latest version which is JDK9 compatible to suppress this warning :
WARNING: Illegal reflective access by javassist.util.proxy.SecurityActions (file:.../play-1.x/framework/lib/javassist-3.21.0-GA.jar) to method java.lang.ClassLoader.defineClass(java.lang.String,byte[],int,int,java.security.ProtectionDomain)

Copy link
Contributor

@asolntsev asolntsev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved (if Travis build becomes green).

@tomparle
Copy link
Contributor Author

Thanks Andrei.
My bad not to have seen some test failed, I'm going to check and fix this as soon as possible !

…nd that was fixed in latest version of javassist
@tomparle
Copy link
Contributor Author

OK, it took me more time than expected to understand the issue and finally fix it, but I'm glad to have found it out !
The class PropertiesEnhancer seems to have contained a workaround to fix an issue in javassist previous version :
// protected classes will be considered public by this call && Modifier.isPublic(ctField.getDeclaringClass().getModifiers());

This call to Modifier.isPublic() should have returned false for a protected class (from javassist flags), but was returning true up to javassist version 3.21, hence the previous workaround in Play with the previous comment.
Starting from Javassist 3.23, the method Modifier.isPublic() correctly returns false for a protected class, and returns true for the method Modifier.isProtected(), hence the proposed fix.

@xael-fry xael-fry merged commit bdfc7ad into playframework:master Jul 23, 2018
@xael-fry
Copy link
Member

All is green.
Merge it master
Thanks @asolntsev @tomparle

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants