EDR: An illegal reflective access operation has occurred in cb-datagrid startup.out
search cancel

EDR: An illegal reflective access operation has occurred in cb-datagrid startup.out

book

Article ID: 289430

calendar_today

Updated On:

Products

Carbon Black EDR (formerly Cb Response)

Issue/Introduction

During startup of cb-datagrid there is a series of warnings logged in /var/log/cb/datagrid/startup.out:
WARNING: Hazelcast is starting in a Java modular environment (Java 9 and newer) but without proper access to required Java packages. Use additional Java arguments to provide Hazelcast access to Java internal API. The internal API access is used to get the best performance results. Arguments to be used:
 --add-modules java.se --add-exports java.base/jdk.internal.ref=ALL-UNNAMED --add-opens java.base/java.lang=ALL-UNNAMED --add-opens java.base/java.nio=ALL-UNNAMED --add-opens java.base/sun.nio.ch=ALL-UNNAMED --add-opens java.management/sun.management=ALL-UNNAMED --add-opens jdk.management/com.sun.management.internal=ALL-UNNAMED
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by com.hazelcast.internal.networking.nio.SelectorOptimizer (file:/usr/share/cb/datagrid/lib/hazelcast-all-3.12.13.jar) to field sun.nio.ch.SelectorImpl.selectedKeys
WARNING: Please consider reporting this to the maintainers of com.hazelcast.internal.networking.nio.SelectorOptimizer
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

Environment

  • EDR Server: Version 7.0+

Cause

The hazelcast warnings indicate that there was a change in Java 9 and newer that generates a warning when a less restrictive access to Java packages is being utilized. EDR Server 7.x is utilizing Java 11.

Resolution

At this time, Java is only warning about this coding practice and not blocking any functionality, so the warnings are only informational and are not causing any adverse impact.

Additional Information

In a future release of Java, it is possible that this would be blocked and would require a code change.