From 911bfa1f474a8aa44534e418a7ee1537f57ab411 Mon Sep 17 00:00:00 2001 From: hengyunabc Date: Sat, 9 May 2020 04:16:43 +0800 Subject: [PATCH] revert #5710 --- .../config/spring/schema/DubboBeanDefinitionParser.java | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) 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 5a849ffef3f..31b299ad21b 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 @@ -130,13 +130,7 @@ private static BeanDefinition parse(Element element, ParserContext parserContext parseProperties(element.getChildNodes(), classDefinition, parserContext); beanDefinition.getPropertyValues().addPropertyValue("ref", new BeanDefinitionHolder(classDefinition, id + "Impl")); } - } else if (ReferenceBean.class.equals(beanClass)) { - String interfaceClassName = resolveAttribute(element, "interface", parserContext); - if (StringUtils.isNotEmpty(interfaceClassName)) { - Class interfaceClass = ReflectUtils.forName(interfaceClassName); - beanDefinition.setTargetType(interfaceClass); - } - } else if (ProviderConfig.class.equals(beanClass)) { + } else if (ProviderConfig.class.equals(beanClass)) { parseNested(element, parserContext, ServiceBean.class, true, "service", "provider", id, beanDefinition); } else if (ConsumerConfig.class.equals(beanClass)) { parseNested(element, parserContext, ReferenceBean.class, false, "reference", "consumer", id, beanDefinition);