Release Note: The ClassLoadingMXBean and MemoryMXBean isVerbose Methods Are Now Consistent with Their setVerbose Methods

XMLWordPrintable

    • Type: Sub-task
    • Resolution: Delivered
    • Priority: P4
    • 23
    • Affects Version/s: 8u441-perf, 11.0.25-oracle, 17.0.13-oracle, 21.0.5-oracle, 23
    • Component/s: core-svc

        The `ClassLoadingMXBean::setVerbose(boolean enabled)` method will set `class+load*` logging on log output `stdout` to level `info` if `enabled` is true, and to level `off` otherwise. In contrast, the `isVerbose` method would check if exactly `class+load` logging was enabled at the `info` level on _any_ log output. This could result in counter-intuitive behavior when logging `class+load=info` to a file via the command-line, as it caused `isVerbose` to return true, even after a call to `setVerbose(false)` had been made. A similar problem existed for the `MemoryMXBean::isVerbose` method. Starting with this release, the behavior is as follows:

        - `ClassLoadingMXBean::isVerbose` will return true only if `class+load*` logging (note the wildcard use) has been enabled at the `info` level (or above) on the `stdout` log output.
        - `MemoryMXBean::isVerbose` will return true only if `gc` logging has been enabled at the `info` level (or above) on the `stdout` log output.

              Assignee:
              David Holmes
              Reporter:
              David Holmes
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: