[ 
https://issues.apache.org/jira/browse/KARAF-5448?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16322398#comment-16322398
 ] 

Guillaume Nodet edited comment on KARAF-5448 at 1/11/18 3:31 PM:
-----------------------------------------------------------------

I don't think this will ever be fixed in the JDK.
Those warnings still appear with java 9.0.1 if you run {{la}} for example which 
shows the {{ShellTable}} list for bundles, you should see the warning.
Each of these warnings needs to be fixed by somehow removing the reflection 
code, which may not be easy.

The problem won't be fixed by the JDK. At some point, the default will be 
changed to {{--illegal-access=deny}} which will break the code. See 
https://jaxenter.com/jdk-9-replace-permit-illegal-access-134180.html


was (Author: gnt):
I don't think this will ever be fixed in the JDK.
Those warnings still appear with java 9.0.1 if you run {{la}} for example which 
shows the {{ShellTable}} list for bundles, you should see the warning.
Each of these warnings needs to be fixed by somehow removing the reflection 
code, which may not be easy.

> Fix Java 9 warnings
> -------------------
>
>                 Key: KARAF-5448
>                 URL: https://issues.apache.org/jira/browse/KARAF-5448
>             Project: Karaf
>          Issue Type: Improvement
>            Reporter: Guillaume Nodet
>            Assignee: Guillaume Nodet
>             Fix For: 4.2.0
>
>
> There are a few illegal access warnings when running tests on Java 9:
> {code}
> WARNING: An illegal reflective access operation has occurred
> WARNING: Illegal reflective access by 
> org.apache.karaf.shell.support.table.ShellTable (jar:bundle://16.0:0/!/) to 
> field java.io.PrintStream.charOut
> WARNING: Please consider reporting this to the maintainers of 
> org.apache.karaf.shell.support.table.ShellTable
> WARNING: Use --illegal-access=warn to enable warnings of further illegal 
> reflective access operations
> WARNING: All illegal access operations will be denied in a future release
> WARNING: An illegal reflective access operation has occurred                  
>                                                                               
>   
> WARNING: Illegal reflective access by org.eclipse.jetty.util.BufferUtil 
> (jar:bundle://52.0:0/!/) to field java.nio.MappedByteBuffer.fd
> WARNING: Please consider reporting this to the maintainers of 
> org.eclipse.jetty.util.BufferUtil
> WARNING: Use --illegal-access=warn to enable warnings of further illegal 
> reflective access operations
> WARNING: All illegal access operations will be denied in a future release
> WARNING: An illegal reflective access operation has occurred
> WARNING: Illegal reflective access by 
> org.apache.karaf.management.RmiRegistryFactory (jar:bundle://29.0:0/!/) to 
> field sun.rmi.transport.tcp.TCPEndpoint.localEndpoints
> WARNING: Please consider reporting this to the maintainers of 
> org.apache.karaf.management.RmiRegistryFactory
> WARNING: Use --illegal-access=warn to enable warnings of further illegal 
> reflective access operations
> WARNING: All illegal access operations will be denied in a future release
> WARNING: An illegal reflective access operation has occurred
> WARNING: Illegal reflective access by org.apache.aries.jndi.startup.Activator 
> (jar:bundle://93.0:0/!/) to field 
> javax.naming.spi.NamingManager.initctx_factory_builder
> WARNING: Please consider reporting this to the maintainers of 
> org.apache.aries.jndi.startup.Activator
> WARNING: Use --illegal-access=warn to enable warnings of further illegal 
> reflective access operations
> WARNING: All illegal access operations will be denied in a future release
> WARNING: An illegal reflective access operation has occurred
> WARNING: Illegal reflective access by 
> io.netty.util.internal.PlatformDependent0 
> (bundle://151.0:1/netty-all-4.0.30.Final.jar) to field java.nio.Buffer.address
> WARNING: Please consider reporting this to the maintainers of 
> io.netty.util.internal.PlatformDependent0
> WARNING: Use --illegal-access=warn to enable warnings of further illegal 
> reflective access operations
> WARNING: All illegal access operations will be denied in a future release
> karaf-maven-plugin:
> WARNING: An illegal reflective access operation has occurred
> WARNING: Illegal reflective access by 
> com.sun.xml.bind.v2.runtime.reflect.opt.Injector 
> (file:/Users/gnodet/.m2/repository/com/sun/xml/bind/jaxb-impl/2.2.11/jaxb-impl-2.2.11.jar)
>  to method java.lang.ClassLoader.defineClass(java.lang.String,byte[],int,int)
> WARNING: Please consider reporting this to the maintainers of 
> com.sun.xml.bind.v2.runtime.reflect.opt.Injector
> WARNING: Use --illegal-access=warn to enable warnings of further illegal 
> reflective access operations
> WARNING: All illegal access operations will be denied in a future release
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to