You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dubbo.apache.org by li...@apache.org on 2019/04/12 03:16:59 UTC

[incubator-dubbo] branch master updated: Merge pull request #3862, bugfix/remove-parse-error-log, revert #3823.

This is an automated email from the ASF dual-hosted git repository.

liujun pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-dubbo.git


The following commit(s) were added to refs/heads/master by this push:
     new 68e5522  Merge pull request #3862, bugfix/remove-parse-error-log, revert #3823.
68e5522 is described below

commit 68e5522a64a422ebedfe3ad216247bbb4dbe5a79
Author: xujingfeng <25...@qq.com>
AuthorDate: Fri Apr 12 11:16:54 2019 +0800

    Merge pull request #3862, bugfix/remove-parse-error-log, revert #3823.
---
 .../apache/dubbo/config/spring/schema/DubboBeanDefinitionParser.java  | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/dubbo-config/dubbo-config-spring/src/main/java/org/apache/dubbo/config/spring/schema/DubboBeanDefinitionParser.java b/dubbo-config/dubbo-config-spring/src/main/java/org/apache/dubbo/config/spring/schema/DubboBeanDefinitionParser.java
index 3c69294..f5c2ab0 100644
--- a/dubbo-config/dubbo-config-spring/src/main/java/org/apache/dubbo/config/spring/schema/DubboBeanDefinitionParser.java
+++ b/dubbo-config/dubbo-config-spring/src/main/java/org/apache/dubbo/config/spring/schema/DubboBeanDefinitionParser.java
@@ -136,6 +136,7 @@ public class DubboBeanDefinitionParser implements BeanDefinitionParser {
                 String beanProperty = name.substring(3, 4).toLowerCase() + name.substring(4);
                 String property = StringUtils.camelToSplitName(beanProperty, "-");
                 props.add(property);
+                // check the setter/getter whether match
                 Method getter = null;
                 try {
                     getter = beanClass.getMethod("get" + name.substring(3), new Class<?>[0]);
@@ -143,7 +144,8 @@ public class DubboBeanDefinitionParser implements BeanDefinitionParser {
                     try {
                         getter = beanClass.getMethod("is" + name.substring(3), new Class<?>[0]);
                     } catch (NoSuchMethodException e2) {
-                        logger.error("Method " + name + " parse error,  cause: " + e2.getMessage(), e2);
+                        // ignore, there is no need any log here since some class implement the interface: EnvironmentAware,
+                        // ApplicationAware, etc. They only have setter method, otherwise will cause the error log during application start up.
                     }
                 }
                 if (getter == null