<ul class="contains-task-list">
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have searched the <a href="https://github.com/apache/dubbo/issues">issues</a> of this repository and believe that this is not a duplicate.</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have checked the <a href="https://github.com/apache/dubbo/blob/master/FAQ.md">FAQ</a> of this repository and believe that this is not a duplicate.</li>
</ul>
<h3 dir="auto">Environment</h3>
<ul dir="auto">
<li>Dubbo version: 2.7.5-SNAPSHOT</li>
<li>Operating System version: Max OS 10.14.5</li>
<li>Java version: Oracle jdk 1.8.0_131</li>
</ul>
<h3 dir="auto">Steps to reproduce this issue</h3>
<ol dir="auto">
<li>checkout master branch</li>
<li>checkout HEAD <a class="commit-link" data-hovercard-type="commit" data-hovercard-url="https://github.com/apache/dubbo/commit/15d808446d4bebc3b87f986ccc657f9e5baff728/hovercard" href="https://github.com/apache/dubbo/commit/15d808446d4bebc3b87f986ccc657f9e5baff728"><tt>15d8084</tt></a></li>
<li>run command: ./mvnw clean install -DskipTests=false &amp; ./mvnw clean test-compile failsafe:integration-test</li>
</ol>
<p dir="auto">Pls. provide [GitHub address] to reproduce this issue.</p>
<h3 dir="auto">Expected Result</h3>
<p dir="auto">What do you expected from the above steps？</p>
<p dir="auto">The build should run successfully</p>
<h3 dir="auto">Actual Result</h3>
<p dir="auto">What actually happens?</p>
<p dir="auto">Unit test failing</p>
<p dir="auto">If there is an exception, please attach the exception trace:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="[INFO] 
[INFO] Results:
[INFO] 
[ERROR] Failures: 
[ERROR]   ServiceConfigTest.testDelayExport:173 
Expected: a collection with size &lt;1&gt;
     but: collection size was &lt;0&gt;
[ERROR]   ServiceConfigTest.testExport:155 
protocol.export(
    &lt;any org.apache.dubbo.rpc.Invoker&gt;
);
Wanted 1 time:
-&gt; at org.apache.dubbo.config.ServiceConfigTest.testExport(ServiceConfigTest.java:155)
But was 2 times:
-&gt; at org.apache.dubbo.config.mock.MockProtocol2.export(MockProtocol2.java:36)
-&gt; at org.apache.dubbo.config.mock.MockProtocol2.export(MockProtocol2.java:36)


[INFO] 
[ERROR] Tests run: 557, Failures: 2, Errors: 0, Skipped: 2
"><pre class="notranslate"><code class="notranslate">[INFO] 
[INFO] Results:
[INFO] 
[ERROR] Failures: 
[ERROR]   ServiceConfigTest.testDelayExport:173 
Expected: a collection with size &lt;1&gt;
     but: collection size was &lt;0&gt;
[ERROR]   ServiceConfigTest.testExport:155 
protocol.export(
    &lt;any org.apache.dubbo.rpc.Invoker&gt;
);
Wanted 1 time:
-&gt; at org.apache.dubbo.config.ServiceConfigTest.testExport(ServiceConfigTest.java:155)
But was 2 times:
-&gt; at org.apache.dubbo.config.mock.MockProtocol2.export(MockProtocol2.java:36)
-&gt; at org.apache.dubbo.config.mock.MockProtocol2.export(MockProtocol2.java:36)


[INFO] 
[ERROR] Tests run: 557, Failures: 2, Errors: 0, Skipped: 2

</code></pre></div>
<p dir="auto"><a href="https://github.com/apache/incubator-dubbo/blob/master/dubbo-config/dubbo-config-spring/src/main/java/org/apache/dubbo/config/spring/beans/factory/annotation/ServiceAnnotationBeanPostProcessor.java">https://github.com/apache/incubator-dubbo/blob/master/dubbo-config/dubbo-config-spring/src/main/java/org/apache/dubbo/config/spring/beans/factory/annotation/ServiceAnnotationBeanPostProcessor.java</a></p>
<p dir="auto">这个java类里面的private void registerServiceBean 这个方法, 下面这几行<br>
if (scanner.checkCandidate(beanName, serviceBeanDefinition)) { // check duplicated candidate bean<br>
registry.registerBeanDefinition(beanName, serviceBeanDefinition);</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="        if (logger.isInfoEnabled()) {
            logger.warn(&quot;The BeanDefinition[&quot; + serviceBeanDefinition +
                    &quot;] of ServiceBean has been registered with name : &quot; + beanName);
        }

    } else {

        if (logger.isWarnEnabled()) {
            logger.warn(&quot;The Duplicated BeanDefinition[&quot; + serviceBeanDefinition +
                    &quot;] of ServiceBean[ bean name : &quot; + beanName +
                    &quot;] was be found , Did @DubboComponentScan scan to same package in many times?&quot;);
        }

    }"><pre class="notranslate"><code class="notranslate">        if (logger.isInfoEnabled()) {
            logger.warn("The BeanDefinition[" + serviceBeanDefinition +
                    "] of ServiceBean has been registered with name : " + beanName);
        }

    } else {

        if (logger.isWarnEnabled()) {
            logger.warn("The Duplicated BeanDefinition[" + serviceBeanDefinition +
                    "] of ServiceBean[ bean name : " + beanName +
                    "] was be found , Did @DubboComponentScan scan to same package in many times?");
        }

    }
</code></pre></div>
<p dir="auto">请问, 为什么在检查没有重复的bean定义的时候, 还要打印一条警告信息? 不是应该是info信息吗?</p>