<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.6</li>
<li>Java version: JDK8</li>
</ul>
<p dir="auto">DUBBO客户端与服务端建立连接超时，然后抛出异常。请问是否可以添加上重试的特性？</p>
<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.3</li>
<li>Operating System version:  win10</li>
<li>Java version: 1.8</li>
<li>SpringBootVersion: 2.0.6  2.0.9</li>
<li>nacos server: 1.1.3</li>
<li>AlibabaCloudStarterNacosDiscovery: 2.0.0</li>
</ul>
<h3 dir="auto">Steps to reproduce this issue</h3>
<ol dir="auto">
<li>boostrap.yml</li>
</ol>
<div class="highlight highlight-source-yaml notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="spring:
  application:
    name: demo-banana
  cloud:
    nacos:
      discovery:
        server-addr: 127.0.0.1:8848
        namespace: 8e135e43-4e66-462b-9039-300f6f8f55c2
      config:
        server-addr: 127.0.0.1:8848"><pre class="notranslate"><span class="pl-ent">spring</span>:
  <span class="pl-ent">application</span>:
    <span class="pl-ent">name</span>: <span class="pl-s">demo-banana</span>
  <span class="pl-ent">cloud</span>:
    <span class="pl-ent">nacos</span>:
      <span class="pl-ent">discovery</span>:
        <span class="pl-ent">server-addr</span>: <span class="pl-s">127.0.0.1:8848</span>
        <span class="pl-ent">namespace</span>: <span class="pl-s">8e135e43-4e66-462b-9039-300f6f8f55c2</span>
      <span class="pl-ent">config</span>:
        <span class="pl-ent">server-addr</span>: <span class="pl-s">127.0.0.1:8848</span></pre></div>
<ol start="2" dir="auto">
<li>application.yaml</li>
</ol>
<div class="highlight highlight-source-yaml notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="server:
  port: 8200
management:
  endpoints:
    web:
      exposure:
        include: &quot;*&quot;"><pre class="notranslate"><span class="pl-ent">server</span>:
  <span class="pl-ent">port</span>: <span class="pl-c1">8200</span>
<span class="pl-ent">management</span>:
  <span class="pl-ent">endpoints</span>:
    <span class="pl-ent">web</span>:
      <span class="pl-ent">exposure</span>:
        <span class="pl-ent">include</span>: <span class="pl-s"><span class="pl-pds">"</span>*<span class="pl-pds">"</span></span></pre></div>
<ol start="3" dir="auto">
<li>dubbo.xml</li>
</ol>
<div class="highlight highlight-text-xml notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;
&lt;beans xmlns=&quot;http://www.springframework.org/schema/beans&quot;
       xmlns:xsi=&quot;http://www.w3.org/2001/XMLSchema-instance&quot;
       xmlns:dubbo=&quot;http://dubbo.apache.org/schema/dubbo&quot;
       xsi:schemaLocation=&quot;http://www.springframework.org/schema/beans
       http://www.springframework.org/schema/beans/spring-beans-4.3.xsd
       http://dubbo.apache.org/schema/dubbo
       http://dubbo.apache.org/schema/dubbo/dubbo.xsd&quot;&gt;

    &lt;!-- 提供方应用信息，用于计算依赖关系 --&gt;
    &lt;dubbo:application name=&quot;${spring.application.name}&quot; logger=&quot;slf4j&quot;/&gt;
    &lt;dubbo:config-center address=&quot;nacos://127.0.0.1:8848&quot; namespace=&quot;public&quot; config-file=&quot;dubbo.properties&quot; group=&quot;DEFAULT_GROUP&quot;/&gt;
&lt;!--    &lt;dubbo:registry address=&quot;nacos://127.0.0.1:8848&quot;/&gt;--&gt;
    &lt;dubbo:reference interface=&quot;com.example.apple.export.AppleExport&quot; lazy=&quot;true&quot; /&gt;
&lt;/beans&gt;"><pre class="notranslate">&lt;?<span class="pl-ent">xml</span><span class="pl-e"> version</span>=<span class="pl-s"><span class="pl-pds">"</span>1.0<span class="pl-pds">"</span></span><span class="pl-e"> encoding</span>=<span class="pl-s"><span class="pl-pds">"</span>UTF-8<span class="pl-pds">"</span></span>?&gt;
&lt;<span class="pl-ent">beans</span> <span class="pl-e">xmlns</span>=<span class="pl-s"><span class="pl-pds">"</span>http://www.springframework.org/schema/beans<span class="pl-pds">"</span></span>
       <span class="pl-e">xmlns</span><span class="pl-e">:</span><span class="pl-e">xsi</span>=<span class="pl-s"><span class="pl-pds">"</span>http://www.w3.org/2001/XMLSchema-instance<span class="pl-pds">"</span></span>
       <span class="pl-e">xmlns</span><span class="pl-e">:</span><span class="pl-e">dubbo</span>=<span class="pl-s"><span class="pl-pds">"</span>http://dubbo.apache.org/schema/dubbo<span class="pl-pds">"</span></span>
       <span class="pl-e">xsi</span><span class="pl-e">:</span><span class="pl-e">schemaLocation</span>=<span class="pl-s"><span class="pl-pds">"</span>http://www.springframework.org/schema/beans</span>
<span class="pl-s">       http://www.springframework.org/schema/beans/spring-beans-4.3.xsd</span>
<span class="pl-s">       http://dubbo.apache.org/schema/dubbo</span>
<span class="pl-s">       http://dubbo.apache.org/schema/dubbo/dubbo.xsd<span class="pl-pds">"</span></span>&gt;

    <span class="pl-c"><span class="pl-c">&lt;!--</span> 提供方应用信息，用于计算依赖关系 <span class="pl-c">--&gt;</span></span>
    &lt;<span class="pl-ent">dubbo</span><span class="pl-ent">:</span><span class="pl-ent">application</span> <span class="pl-e">name</span>=<span class="pl-s"><span class="pl-pds">"</span>${spring.application.name}<span class="pl-pds">"</span></span> <span class="pl-e">logger</span>=<span class="pl-s"><span class="pl-pds">"</span>slf4j<span class="pl-pds">"</span></span>/&gt;
    &lt;<span class="pl-ent">dubbo</span><span class="pl-ent">:</span><span class="pl-ent">config-center</span> <span class="pl-e">address</span>=<span class="pl-s"><span class="pl-pds">"</span>nacos://127.0.0.1:8848<span class="pl-pds">"</span></span> <span class="pl-e">namespace</span>=<span class="pl-s"><span class="pl-pds">"</span>public<span class="pl-pds">"</span></span> <span class="pl-e">config-file</span>=<span class="pl-s"><span class="pl-pds">"</span>dubbo.properties<span class="pl-pds">"</span></span> <span class="pl-e">group</span>=<span class="pl-s"><span class="pl-pds">"</span>DEFAULT_GROUP<span class="pl-pds">"</span></span>/&gt;
<span class="pl-c"><span class="pl-c">&lt;!--</span>    &lt;dubbo:registry address="nacos://127.0.0.1:8848"/&gt;<span class="pl-c">--&gt;</span></span>
    &lt;<span class="pl-ent">dubbo</span><span class="pl-ent">:</span><span class="pl-ent">reference</span> <span class="pl-e">interface</span>=<span class="pl-s"><span class="pl-pds">"</span>com.example.apple.export.AppleExport<span class="pl-pds">"</span></span> <span class="pl-e">lazy</span>=<span class="pl-s"><span class="pl-pds">"</span>true<span class="pl-pds">"</span></span> /&gt;
&lt;/<span class="pl-ent">beans</span>&gt;</pre></div>
<p dir="auto">4.dubbo.properties</p>
<div class="highlight highlight-source-ini notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="dubbo.registry.address=nacos://127.0.0.1:8848"><pre class="notranslate"><span class="pl-k">dubbo.registry.address</span>=nacos://127.0.0.1:8848</pre></div>
<p dir="auto">Pls. provide [GitHub address] to reproduce this issue.</p>
<h3 dir="auto">Expected Result</h3>
<p dir="auto">启动成功</p>
<h3 dir="auto">Actual Result</h3>
<p dir="auto">启动失败</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="[2019-08-16 08:39:37.717]  INFO org.apache.catalina.core.AprLifecycleListener : The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: [D:\SDK\JDK8\bin;C:\Windows\Sun\Java\bin;C:\Windows\system32;C:\Windows;D:\Developer\Jetbrains\IntelliJ IDEA\jbr\\bin;D:\Developer\Jetbrains\IntelliJ IDEA\jbr\\bin\server;C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\iCLS\;C:\Program Files\Intel\Intel(R) Management Engine Components\iCLS\;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows\System32\OpenSSH\;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;D:\SDK\JDK8\bin;D:\SDK\Python3;C:\Users\xiaolei.fu\AppData\Local\Microsoft\WindowsApps;D:\Common\BandZip\;D:\Developer\Microsoft VS Code\bin;D:\Developer\Jetbrains\IntelliJ IDEA\bin;;.]
[2019-08-16 08:39:37.821]  INFO org.apache.catalina.core.ContainerBase.[Tomcat].[localhost].[/] : Initializing Spring embedded WebApplicationContext
[2019-08-16 08:39:37.834]  INFO com.alibaba.cloud.sentinel.SentinelWebAutoConfiguration : [Sentinel Starter] register Sentinel CommonFilter with urlPatterns: [/*].
[2019-08-16 08:39:38.510]  INFO com.alibaba.nacos.client.naming : initializer namespace from System Property :null
[2019-08-16 08:39:38.510]  INFO com.alibaba.nacos.client.naming : initializer namespace from System Environment :null
[2019-08-16 08:39:38.510]  INFO com.alibaba.nacos.client.naming : initializer namespace from System Property :null
[2019-08-16 08:39:38.516] DEBUG com.alibaba.nacos.client.naming : failover switch is not found, failover00-00---000-VIPSRV_FAILOVER_SWITCH-000---00-00
[2019-08-16 08:39:38.796]  INFO org.apache.catalina.core.StandardService : Stopping service [Tomcat]
[2019-08-16 08:39:38.801]  WARN org.apache.catalina.loader.WebappClassLoaderBase : The web application [ROOT] appears to have started a thread named [com.alibaba.nacos.naming.client.listener] but has failed to stop it. This is very likely to create a memory leak. Stack trace of thread:
 sun.misc.Unsafe.park(Native Method)
 java.util.concurrent.locks.LockSupport.parkNanos(LockSupport.java:215)
 java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.awaitNanos(AbstractQueuedSynchronizer.java:2078)
 java.util.concurrent.LinkedBlockingQueue.poll(LinkedBlockingQueue.java:467)
 com.alibaba.nacos.client.naming.core.EventDispatcher$Notifier.run(EventDispatcher.java:114)
 java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
 java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
 java.lang.Thread.run(Thread.java:748)"><pre class="notranslate"><code class="notranslate">[2019-08-16 08:39:37.717]  INFO org.apache.catalina.core.AprLifecycleListener : The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: [D:\SDK\JDK8\bin;C:\Windows\Sun\Java\bin;C:\Windows\system32;C:\Windows;D:\Developer\Jetbrains\IntelliJ IDEA\jbr\\bin;D:\Developer\Jetbrains\IntelliJ IDEA\jbr\\bin\server;C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\iCLS\;C:\Program Files\Intel\Intel(R) Management Engine Components\iCLS\;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows\System32\OpenSSH\;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;D:\SDK\JDK8\bin;D:\SDK\Python3;C:\Users\xiaolei.fu\AppData\Local\Microsoft\WindowsApps;D:\Common\BandZip\;D:\Developer\Microsoft VS Code\bin;D:\Developer\Jetbrains\IntelliJ IDEA\bin;;.]
[2019-08-16 08:39:37.821]  INFO org.apache.catalina.core.ContainerBase.[Tomcat].[localhost].[/] : Initializing Spring embedded WebApplicationContext
[2019-08-16 08:39:37.834]  INFO com.alibaba.cloud.sentinel.SentinelWebAutoConfiguration : [Sentinel Starter] register Sentinel CommonFilter with urlPatterns: [/*].
[2019-08-16 08:39:38.510]  INFO com.alibaba.nacos.client.naming : initializer namespace from System Property :null
[2019-08-16 08:39:38.510]  INFO com.alibaba.nacos.client.naming : initializer namespace from System Environment :null
[2019-08-16 08:39:38.510]  INFO com.alibaba.nacos.client.naming : initializer namespace from System Property :null
[2019-08-16 08:39:38.516] DEBUG com.alibaba.nacos.client.naming : failover switch is not found, failover00-00---000-VIPSRV_FAILOVER_SWITCH-000---00-00
[2019-08-16 08:39:38.796]  INFO org.apache.catalina.core.StandardService : Stopping service [Tomcat]
[2019-08-16 08:39:38.801]  WARN org.apache.catalina.loader.WebappClassLoaderBase : The web application [ROOT] appears to have started a thread named [com.alibaba.nacos.naming.client.listener] but has failed to stop it. This is very likely to create a memory leak. Stack trace of thread:
 sun.misc.Unsafe.park(Native Method)
 java.util.concurrent.locks.LockSupport.parkNanos(LockSupport.java:215)
 java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.awaitNanos(AbstractQueuedSynchronizer.java:2078)
 java.util.concurrent.LinkedBlockingQueue.poll(LinkedBlockingQueue.java:467)
 com.alibaba.nacos.client.naming.core.EventDispatcher$Notifier.run(EventDispatcher.java:114)
 java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
 java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
 java.lang.Thread.run(Thread.java:748)
</code></pre></div>