What causes these warnings?

(Varuna) #1

The warnings below come up when gradle -v is run. What causes these warnings.

WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by org.codehaus.groovy.reflection.CachedClass (file:/C:/Users/User Name/gradle-4.6/lib/groovy-all-2.4.12.jar) to method java.lang.Object.finalize()
WARNING: Please consider reporting this to the maintainers of org.codehaus.groovy.reflection.CachedClass
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

(Pierre) #2


I have the same warning when my JAVA_HOME environment variable points to a Java 9 JDK (openjdk).
In Java 9 some reflection operations are deprecated due to the module mechanism.