From 4bb88f3b1d119871edb62cbe564d66f649e3d301 Mon Sep 17 00:00:00 2001 From: Juergen Hoeller Date: Tue, 22 Jun 2021 15:26:48 +0200 Subject: [PATCH] Remove logging dependency in BeanUtils Closes gh-27070 --- .../org/springframework/beans/BeanUtils.java | 17 +---------------- 1 file changed, 1 insertion(+), 16 deletions(-) diff --git a/spring-beans/src/main/java/org/springframework/beans/BeanUtils.java b/spring-beans/src/main/java/org/springframework/beans/BeanUtils.java index 053393e6c4..6e97683f88 100644 --- a/spring-beans/src/main/java/org/springframework/beans/BeanUtils.java +++ b/spring-beans/src/main/java/org/springframework/beans/BeanUtils.java @@ -1,5 +1,5 @@ /* - * Copyright 2002-2020 the original author or authors. + * Copyright 2002-2021 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -41,8 +41,6 @@ import kotlin.reflect.KParameter; import kotlin.reflect.full.KClasses; import kotlin.reflect.jvm.KCallablesJvm; import kotlin.reflect.jvm.ReflectJvmMapping; -import org.apache.commons.logging.Log; -import org.apache.commons.logging.LogFactory; import org.springframework.core.DefaultParameterNameDiscoverer; import org.springframework.core.KotlinDetector; @@ -75,8 +73,6 @@ import org.springframework.util.StringUtils; */ public abstract class BeanUtils { - private static final Log logger = LogFactory.getLog(BeanUtils.class); - private static final ParameterNameDiscoverer parameterNameDiscoverer = new DefaultParameterNameDiscoverer(); @@ -551,9 +547,6 @@ public abstract class BeanUtils { } catch (Throwable ex) { // e.g. AccessControlException on Google App Engine - if (logger.isDebugEnabled()) { - logger.debug("Could not access system ClassLoader: " + ex); - } return null; } } @@ -564,10 +557,6 @@ public abstract class BeanUtils { Class editorClass = cl.loadClass(editorName); if (editorClass != null) { if (!PropertyEditor.class.isAssignableFrom(editorClass)) { - if (logger.isInfoEnabled()) { - logger.info("Editor class [" + editorName + - "] does not implement [java.beans.PropertyEditor] interface"); - } unknownEditorTypes.add(targetType); return null; } @@ -579,10 +568,6 @@ public abstract class BeanUtils { catch (ClassNotFoundException ex) { // Ignore - fall back to unknown editor type registration below } - if (logger.isTraceEnabled()) { - logger.trace("No property editor [" + editorName + "] found for type " + - targetTypeName + " according to 'Editor' suffix convention"); - } unknownEditorTypes.add(targetType); return null; }