Illegal reflective access (ArrayList.size) – Fixed in any Groovy 3.x/4.x version?

"Anjan Baradwaj via dev" <dev-GSC0n/0aZo1d/SJB6HiN2Ni2O/[email protected]>
Newsgroups gmane.comp.lang.groovy.devel
Message-ID <SA1PR22MB544595E6B48BF0CAD3E95F7B9974A@SA1PR22MB5445.namprd22.prod.outlook.com>
Hello Groovy Team,

We are using Groovy 3.0.12 with JDK 11 and see the following warning
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by org.codehaus.groovy.vmplugin.v9.Java9
(file: .../groovy-3.0.12.jar) to field java.util.ArrayList.size
WARNING: Please consider reporting this to the maintainers of org.codehaus.groovy.vmplugin.v9.Java9
WARNING: All illegal access operations will be denied in a future release

We also tested with Groovy 4.x and observed similar behavior.

Environment details:

Groovy: 3.0.12 (also tested 4.x)
Java: 11.0.29
Maven: 3.5.2

Could you please let us know:


  1.
Has this been fixed in any newer Groovy 3.x or 4.x version?
  2.
If yes, which version should we upgrade to?
  3.
Is there any recommended approach to avoid this without using --add-opens JVM options?

Thank you for your help.

Best regards,
Anjan

CONFIDENTIALITY NOTICE: The information contained in this electronic message is intended to be viewed only by the individual or entity to which it is addressed. It may contain information that is privileged, confidential, and exempt from disclosure under applicable law. If the reader of this message is not the intended recipient, you are hereby notified that any dissemination, distribution or duplication of this message is strictly prohibited. If this electronic message has been received in error, please notify sender immediately by return email and delete the original message and any copies of it from your computer system. Thank you.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.