Warnings when using J11 and groovy3.0.0-alpha-3

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Warnings when using J11 and groovy3.0.0-alpha-3

Kerridge, Jon

Hi,

I am using J11 latest Oracle build plus groovy 3.0.0-alpha-3.

 

The groovy test program is a simple print hello script

 

I am using Intellij with Gradle and the relevant parts of the build file are:

 

repositories {
    mavenCentral()
    maven {
        url
"https://dl.bintray.com/groovy/maven"
   
}
}

dependencies {
    compile 'org.codehaus.groovy:groovy:3.0.0-alpha-3'
   
compile group: 'javax.xml.bind', name: 'jaxb-api', version: '2.3.0'
}

 

The program works but I get a warning as follows:

 

"C:\Program Files\Java\jdk-11\bin\java.exe" "-Dtools.jar=C:\Program Files\Java\jdk-11\lib\tools.jar" -Dgroovy.home=C:\Users\Jon\.gradle\caches\modules-2\files-2.1\org.codehaus.groovy\groovy\3.0.0-alpha-3\81b3f93dc6c8cdecdca450c6d5326abe9ea28971 "-Dgroovy.starter.conf=C:\Program Files\JetBrains\IntelliJ IDEA Community Edition 2018.2.2\plugins\Groovy\lib\groovy-starter.conf" "-javaagent:C:\Program Files\JetBrains\IntelliJ IDEA Community Edition 2018.2.2\lib\idea_rt.jar=58513:C:\Program Files\JetBrains\IntelliJ IDEA Community Edition 2018.2.2\bin" -Dfile.encoding=UTF-8 -classpath C:\Users\Jon\.gradle\caches\modules-2\files-2.1\org.codehaus.groovy\groovy\3.0.0-alpha-3\81b3f93dc6c8cdecdca450c6d5326abe9ea28971\groovy-3.0.0-alpha-3.jar org.codehaus.groovy.tools.GroovyStarter --conf "C:\Program Files\JetBrains\IntelliJ IDEA Community Edition 2018.2.2\plugins\Groovy\lib\groovy-starter.conf" --main groovy.ui.GroovyMain --classpath .;D:\IJTest\testj10g2.5.2\out\production\classes;C:\Users\Jon\.gradle\caches\modules-2\files-2.1\org.codehaus.groovy\groovy\3.0.0-alpha-3\81b3f93dc6c8cdecdca450c6d5326abe9ea28971\groovy-3.0.0-alpha-3.jar --encoding=UTF-8 D:\IJTest\testj10g2.5.2\src\main\groovy\test1.groovy

WARNING: An illegal reflective access operation has occurred

WARNING: Illegal reflective access by org.codehaus.groovy.vmplugin.v7.Java7$1 (file:/C:/Users/Jon/.gradle/caches/modules-2/files-2.1/org.codehaus.groovy/groovy/3.0.0-alpha-3/81b3f93dc6c8cdecdca450c6d5326abe9ea28971/groovy-3.0.0-alpha-3.jar) to constructor java.lang.invoke.MethodHandles$Lookup(java.lang.Class,int)

WARNING: Please consider reporting this to the maintainers of org.codehaus.groovy.vmplugin.v7.Java7$1

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

hello from test

 

Process finished with exit code 0

 

Where hello from test is what I was expecting!

 

Is this currently expected behaviour or is something amiss?

 

Jon Kerridge

 

 

From: Paul King <[hidden email]>
Sent: 14 August 2018 12:21
To: [hidden email]; [hidden email]
Subject: Re: Java 11 Compatibility check: Apache-groovy

 

 

On Tue, Aug 14, 2018 at 9:10 PM Dragan, Krzysztof <[hidden email]> wrote:

Hi,

We are reaching out to you to check Java 11 compatibility of the library Apache-groovy

 

Could you help us by answering the following questions:

 

Col 1

Col2

Col3

Col4

Col5

Col6

Library name

Latest version

Is the library compatible with Java 11 Compatible?
(Y/N)

Is the library supported with Java 11?

(Y/N)

(If ā€œNā€ in compatibility or support)

What is the versions that would be compatible and Supported?

Date of support availability?

Apache Groovy

Stable: 2.5.2, Preliminary: 3.0.0-alpha-3

For 2.5, Groovy classes compiled with JDK10 should run on JDK11. Groovy 3.0 builds and all tests pass on JDK11 but further testing is required.

See previous answer.

See previous answer.

2.5.2 was released yesterday. Groovy 3.0.0 final doesn't have a set target date yet but isn't due in the next few months.

 

Appreciate your response by 17.08.2018

 

Thanks,

Krzysztof Dragan

PTC Inc. Contractor

 

This message and its attachment(s) are intended for the addressee(s) only and should not be read, copied, disclosed, forwarded or relied upon by any person other than the intended addressee(s) without the permission of the sender. If you are not the intended addressee you must not take any action based on this message and its attachment(s) nor must you copy or show them to anyone. Please respond to the sender and ensure that this message and its attachment(s) are deleted.

It is your responsibility to ensure that this message and its attachment(s) are scanned for viruses or other defects. Edinburgh Napier University does not accept liability for any loss or damage which may result from this message or its attachment(s), or for errors or omissions arising after it was sent. Email is not a secure medium. Emails entering Edinburgh Napier University's system are subject to routine monitoring and filtering by Edinburgh Napier University.

Edinburgh Napier University is a registered Scottish charity. Registration number SC018373

Reply | Threaded
Open this post in threaded view
|

Re: Warnings when using J11 and groovy3.0.0-alpha-3

Daniel.Sun
Hi Kerridge,

     You can set environment variable GROOVY_TURN_OFF_JAVA_WARNINGS to true
to avoid these warnings.

     Eliminating these warnings is one of tasks of groovy 3.0.0.

Cheers,
Daniel.Sun



-----
Daniel Sun
Apache Groovy committer
Blog: http://blog.sunlan.me 
Twitter: @daniel_sun

--
Sent from: http://groovy.329449.n5.nabble.com/Groovy-Dev-f372993.html
Daniel Sun
Apache Groovy committer

Blog: http://blog.sunlan.me
Twitter: @daniel_sun