8172971: java.management could use System.Logger
Mandy Chung
mandy.chung at oracle.com
Thu Jan 19 17:12:03 UTC 2017
> On Jan 19, 2017, at 7:30 AM, Daniel Fuchs <daniel.fuchs at oracle.com> wrote:
>
> Hi,
>
> Please find below a patch for:
>
> 8172971: java.management could use System.Logger
> https://bugs.openjdk.java.net/browse/JDK-8172971
>
> webrev:
> http://cr.openjdk.java.net/~dfuchs/webrev_8172971/webrev.00/
>
This looks good in general and pretty straight forward change.
Is it intentional to change the level FINEST to DEBUG as opposed to TRACE in a couple places? For example,
src/java.management/share/classes/javax/management/MBeanServerFactory.java
- if (MBEANSERVER_LOGGER.isLoggable(Level.FINEST)) {
+ if (MBEANSERVER_LOGGER.isLoggable(Level.DEBUG)) {
src/java.management/share/classes/com/sun/jmx/mbeanserver/MBeanServerDelegateImpl.java
- if (MBEANSERVER_LOGGER.isLoggable(Level.FINEST)) {
- MBEANSERVER_LOGGER.logp(Level.FINEST,
- MBeanServerDelegateImpl.class.getName(),
- "getAttributes",
+ if (MBEANSERVER_LOGGER.isLoggable(Level.TRACE)) {
+ MBEANSERVER_LOGGER.log(Level.TRACE,
"Attribute " + attn[i] + " not found");
}
> I have also added a new test:
> test/sun/management/LoggingTest/LoggingTest.java
This test should have @modules java.logging and java.management.
Mandy
More information about the core-libs-dev
mailing list