Uploaded image for project: 'JBoss Enterprise Application Platform'
  1. JBoss Enterprise Application Platform
  2. JBEAP-14102

Java 9: Illegal reflective access

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • 7.2.0.CD14
    • 7.1.0.GA
    • Security Manager
    • None
      1. start eap with JDK9

      I can see following warnings when I start EAP7.1.0.GA server with JDK9:

      WARNING: Illegal reflective access by org.wildfly.security.manager.GetAccessibleDeclaredFieldAction (jar:file:/tmp/CR4/jboss-eap-7.1/modules/system/layers/base/org/wildfly/security/elytron-private/main/wildfly-elytron-1.1.7.Final-redhat-1.jar!/) to field java.security.AccessControlContext.context
      WARNING: Illegal reflective access by org.jboss.threads.ThreadLocalResetter$1 (jar:file:/tmp/CR4/jboss-eap-7.1/modules/system/layers/base/org/jboss/threads/main/jboss-threads-2.2.1.Final-redhat-1.jar!/) to field java.lang.Thread.threadLocals
      WARNING: Illegal reflective access by org.jboss.threads.ThreadLocalResetter$2 (jar:file:/tmp/CR4/jboss-eap-7.1/modules/system/layers/base/org/jboss/threads/main/jboss-threads-2.2.1.Final-redhat-1.jar!/) to field java.lang.Thread.inheritableThreadLocals
      
      WARNING: Illegal reflective access by org.xnio.nio.NioXnio$2 (jar:file:/tmp/CR4/jboss-eap-7.1/modules/system/layers/base/org/jboss/xnio/nio/main/xnio-nio-3.5.4.Final-redhat-1.jar!/) to constructor sun.nio.ch.EPollSelectorProvider()
      
      WARNING: Illegal reflective access by io.undertow.util.FlexBase64$1 (jar:file:/tmp/CR4/jboss-eap-7.1/modules/system/layers/base/io/undertow/core/main/undertow-core-1.4.18.Final-redhat-2.jar!/) to constructor java.lang.String(char[],boolean)
      

      Oracle has stated that

      When deny becomes the default illegal-access mode then permit will likely remain supported for at least one release, so that developers can continue to migrate their code. The permit, warn, and debug modes will, over time, be removed, as will the --illegal-access option itself.

      http://openjdk.java.net/jeps/261#Relaxed-strong-encapsulation

      Not sure what all components are affected, I see at least Undertow and XNIO. Well, to be honest, I guess there will be more problems in the code which occurr in various situations...

              sguilhen Stefan Guilhen
              jstourac@redhat.com Jan Stourac
              Jan Stourac Jan Stourac
              Jan Stourac Jan Stourac
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

                Created:
                Updated:
                Resolved: