[Q/A][Java SDK (Component)] Will the provider reconnect after a network failure between Nacos and the provider? #15182
Unanswered
TerryLam2010
asked this question in
Question
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Pre-check
Apache Dubbo Component
Java SDK (apache/dubbo)
Details
When there is a network failure between Nacos and the provider, Nacos will kick the provider out of the unactive instances because it does not receive heartbeats. After the network is restored, will Nacos and the provider re-register the instance? I am looking at ZookeeperRegistry, where the zkClient has a listener that re-registers to Zookeeper when a NEW_SESSION_CREATED event occurs. However, I did not see a similar implementation in NacosRegistry.
My scenario involves a network failure between Nacos and the provider, where the heartbeat is not maintained, causing the provider to be removed from the active instance list. Then, a new Nacos instance is started, and Nacos pushes an empty list to all consumers. However, there are no active provider instances on Nacos until I restart the provider.
当nacos与provider网络故障后,nacos因为收不到心跳,会将provider踢出存活实例,当恢复网络后nacos和provider会重新注册实例么?我在看ZookeeperRegistry,zkClient有一个监听器,NEW_SESSION_CREATED 会重新注册到Zookeeper。但是我在NacosRegistry中并未看到类似实现。
我的场景是发生了nacos与provider网络故障,心跳没有维持发送,将provider踢出存活实例列表。然后启动了一个新的nacos,nacos推送了空给所有的consumer,但是nacos上一直没有存活的provider实例,直至我重启了provider,才重新注册上。
Code of Conduct
Beta Was this translation helpful? Give feedback.
All reactions