You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@groovy.apache.org by "Paul King (Jira)" <ji...@apache.org> on 2019/11/24 02:46:01 UTC
[jira] [Closed] (GROOVY-9217) Fix warning "An illegal reflective
access operation has occurred" when setting property
[ https://issues.apache.org/jira/browse/GROOVY-9217?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Paul King closed GROOVY-9217.
-----------------------------
> Fix warning "An illegal reflective access operation has occurred" when setting property
> ---------------------------------------------------------------------------------------
>
> Key: GROOVY-9217
> URL: https://issues.apache.org/jira/browse/GROOVY-9217
> Project: Groovy
> Issue Type: Improvement
> Reporter: Daniel Sun
> Assignee: Daniel Sun
> Priority: Major
> Fix For: 3.0.0-rc-1
>
> Time Spent: 20m
> Remaining Estimate: 0h
>
> Input the following content in the groovySh (found by [~glaforge])
> {code:java}
> :doc collect
> {code}
> Yields the following warnings:
> {code:java}
> WARNING: Illegal reflective access by org.codehaus.groovy.reflection.ReflectionUtils (file:/D:/_DEV/groovy-3.0.0-beta-3/lib/groovy-3.0.0-beta-3.jar) to method sun.net.www.protocol.http.HttpURLConnection.setRequestMethod(java.lang.String)
> at org.codehaus.groovy.reflection.ReflectionUtils.makeAccessible(ReflectionUtils.java:204)
> at org.codehaus.groovy.reflection.ReflectionUtils.makeAccessible(ReflectionUtils.java:196)
> at org.codehaus.groovy.reflection.ReflectionUtils$1.run(ReflectionUtils.java:189)
> at org.codehaus.groovy.reflection.ReflectionUtils$1.run(ReflectionUtils.java:187)
> at java.base/java.security.AccessController.doPrivileged(Native Method)
> at org.codehaus.groovy.reflection.ReflectionUtils.makeAccessibleInPrivilegedAction(ReflectionUtils.java:187)
> at org.codehaus.groovy.reflection.CachedMethod.makeAccessibleIfNecessary(CachedMethod.java:380)
> at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:115)
> at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:323)
> at groovy.lang.MetaClassImpl.setProperty(MetaClassImpl.java:2843)
> at groovy.lang.MetaClassImpl.setProperty(MetaClassImpl.java:3898)
> at org.codehaus.groovy.runtime.InvokerHelper.setProperty(InvokerHelper.java:219)
> at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.setProperty(ScriptBytecodeAdapter.java:496)
> at org.apache.groovy.groovysh.commands.DocCommand.sendHEADRequest(DocCommand.groovy:177)
> at org.codehaus.groovy.runtime.callsite.PlainObjectMetaMethodSite.doInvoke(PlainObjectMetaMethodSite.java:43)
> at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite$PogoCachedMethodSiteNoUnwrapNoCoerce.invoke(PogoMetaMethodSite.java:190)
> at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite.callCurrent(PogoMetaMethodSite.java:58)
> at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:51)
> at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:156)
> at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:168)
> at org.apache.groovy.groovysh.commands.DocCommand.urlsFor(DocCommand.groovy:152)
> at org.codehaus.groovy.runtime.callsite.PlainObjectMetaMethodSite.doInvoke(PlainObjectMetaMethodSite.java:43)
> at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite$PogoCachedMethodSiteNoUnwrapNoCoerce.invoke(PogoMetaMethodSite.java:190)
> at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite.callCurrent(PogoMetaMethodSite.java:58)
> at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:51)
> at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:156)
> at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:168)
> at org.apache.groovy.groovysh.commands.DocCommand.doc(DocCommand.groovy:83)
> at org.apache.groovy.groovysh.commands.DocCommand$doc.callCurrent(Unknown Source)
> at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:51)
> at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:156)
> at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:168)
> WARNING: Illegal reflective access by org.codehaus.groovy.reflection.ReflectionUtils (file:/D:/_DEV/groovy-3.0.0-beta-3/lib/groovy-3.0.0-beta-3.jar) to method sun.net.www.protocol.http.HttpURLConnection.setConnectTimeout(int)
> at org.codehaus.groovy.reflection.ReflectionUtils.makeAccessible(ReflectionUtils.java:204)
> at org.codehaus.groovy.reflection.ReflectionUtils.makeAccessible(ReflectionUtils.java:196)
> at org.codehaus.groovy.reflection.ReflectionUtils$1.run(ReflectionUtils.java:189)
> at org.codehaus.groovy.reflection.ReflectionUtils$1.run(ReflectionUtils.java:187)
> at java.base/java.security.AccessController.doPrivileged(Native Method)
> at org.codehaus.groovy.reflection.ReflectionUtils.makeAccessibleInPrivilegedAction(ReflectionUtils.java:187)
> at org.codehaus.groovy.reflection.CachedMethod.makeAccessibleIfNecessary(CachedMethod.java:380)
> at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:115)
> at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:323)
> at groovy.lang.MetaClassImpl.setProperty(MetaClassImpl.java:2843)
> at groovy.lang.MetaClassImpl.setProperty(MetaClassImpl.java:3898)
> at org.codehaus.groovy.runtime.InvokerHelper.setProperty(InvokerHelper.java:219)
> at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.setProperty(ScriptBytecodeAdapter.java:496)
> at org.apache.groovy.groovysh.commands.DocCommand.sendHEADRequest(DocCommand.groovy:178)
> at org.codehaus.groovy.runtime.callsite.PlainObjectMetaMethodSite.doInvoke(PlainObjectMetaMethodSite.java:43)
> at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite$PogoCachedMethodSiteNoUnwrapNoCoerce.invoke(PogoMetaMethodSite.java:190)
> at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite.callCurrent(PogoMetaMethodSite.java:58)
> at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:51)
> at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:156)
> at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:168)
> at org.apache.groovy.groovysh.commands.DocCommand.urlsFor(DocCommand.groovy:152)
> at org.codehaus.groovy.runtime.callsite.PlainObjectMetaMethodSite.doInvoke(PlainObjectMetaMethodSite.java:43)
> at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite$PogoCachedMethodSiteNoUnwrapNoCoerce.invoke(PogoMetaMethodSite.java:190)
> at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite.callCurrent(PogoMetaMethodSite.java:58)
> at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:51)
> at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:156)
> at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:168)
> at org.apache.groovy.groovysh.commands.DocCommand.doc(DocCommand.groovy:83)
> at org.apache.groovy.groovysh.commands.DocCommand$doc.callCurrent(Unknown Source)
> at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:51)
> at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:156)
> at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:168)
> WARNING: Illegal reflective access by org.codehaus.groovy.reflection.ReflectionUtils (file:/D:/_DEV/groovy-3.0.0-beta-3/lib/groovy-3.0.0-beta-3.jar) to method sun.net.www.protocol.http.HttpURLConnection.setReadTimeout(int)
> at org.codehaus.groovy.reflection.ReflectionUtils.makeAccessible(ReflectionUtils.java:204)
> at org.codehaus.groovy.reflection.ReflectionUtils.makeAccessible(ReflectionUtils.java:196)
> at org.codehaus.groovy.reflection.ReflectionUtils$1.run(ReflectionUtils.java:189)
> at org.codehaus.groovy.reflection.ReflectionUtils$1.run(ReflectionUtils.java:187)
> at java.base/java.security.AccessController.doPrivileged(Native Method)
> at org.codehaus.groovy.reflection.ReflectionUtils.makeAccessibleInPrivilegedAction(ReflectionUtils.java:187)
> at org.codehaus.groovy.reflection.CachedMethod.makeAccessibleIfNecessary(CachedMethod.java:380)
> at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:115)
> at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:323)
> at groovy.lang.MetaClassImpl.setProperty(MetaClassImpl.java:2843)
> at groovy.lang.MetaClassImpl.setProperty(MetaClassImpl.java:3898)
> at org.codehaus.groovy.runtime.InvokerHelper.setProperty(InvokerHelper.java:219)
> at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.setProperty(ScriptBytecodeAdapter.java:496)
> at org.apache.groovy.groovysh.commands.DocCommand.sendHEADRequest(DocCommand.groovy:179)
> at org.codehaus.groovy.runtime.callsite.PlainObjectMetaMethodSite.doInvoke(PlainObjectMetaMethodSite.java:43)
> at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite$PogoCachedMethodSiteNoUnwrapNoCoerce.invoke(PogoMetaMethodSite.java:190)
> at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite.callCurrent(PogoMetaMethodSite.java:58)
> at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:51)
> at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:156)
> at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:168)
> at org.apache.groovy.groovysh.commands.DocCommand.urlsFor(DocCommand.groovy:152)
> at org.codehaus.groovy.runtime.callsite.PlainObjectMetaMethodSite.doInvoke(PlainObjectMetaMethodSite.java:43)
> at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite$PogoCachedMethodSiteNoUnwrapNoCoerce.invoke(PogoMetaMethodSite.java:190)
> at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite.callCurrent(PogoMetaMethodSite.java:58)
> at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:51)
> at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:156)
> at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:168)
> at org.apache.groovy.groovysh.commands.DocCommand.doc(DocCommand.groovy:83)
> at org.apache.groovy.groovysh.commands.DocCommand$doc.callCurrent(Unknown Source)
> at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:51)
> at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:156)
> at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:168)
> Documentation for "collect" could not be found.
> groovy:000> PogoCachedMethodSiteNoUnwrapNoCoerce
> {code}
--
This message was sent by Atlassian Jira
(v8.3.4#803005)