Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8347648

Remove the allowNonPublic MBean compatibility property

XMLWordPrintable

    • Icon: CSR CSR
    • Resolution: Approved
    • Icon: P4 P4
    • 25
    • core-svc
    • None
    • behavioral
    • minimal
    • Ancient property for compatibility with MBean code from before JDK 8.
    • System or security property
    • Implementation

      Summary

      Remove the System Property jdk.jmx.mbeans.allowNonPublic which was introduced in JDK 8 and was intended to be transitional, being removed in later releases. This removal is long overdue.

      Problem

      The System Property jdk.jmx.mbeans.allowNonPublic was added with JDK-8010285, to optionally be compatible with a time before JDK-8, when Management Interfaces being public was not enforced.

      From JDK-8010285: The system property "jdk.jmx.mbeans.allowNonPublic" is used to revert to the old behaviour allowing non-public management interfaces. This property is considered to be transitional and will be removed in the subsequent releases.

      This property is also documented in the JDK 8 Compatibility Guide: https://www.oracle.com/java/technologies/javase/8-compatibility-guide.html

      That was a long time ago. This compatibility convenience flag should be removed.

      Solution

      Remove the code that reads the System Property jdk.jmx.mbeans.allowNonPublic, the conditions related to it, and the tests.

      New behaviour will be the same as current behaviour with the property unset.

      Specification

      No specification change. Property is not documented in the JDK.

      Github PR for reference: https://github.com/openjdk/jdk/pull/23098

            kevinw Kevin Walls
            kevinw Kevin Walls
            Alex Menkov, Serguei Spitsyn
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: