sokui commented on code in PR #3186:
URL: https://github.com/apache/ozone/pull/3186#discussion_r878755347
##########
hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/node/NewNodeHandler.java:
##########
@@ -56,6 +56,7 @@ public NewNodeHandler(PipelineManager pipelineManager,
public void onMessage(DatanodeDetails datanodeDetails,
EventPublisher publisher) {
try {
+ pipelineManager.closeStalePipelines(datanodeDetails);
Review Comment:
Sorry. I think I misstated my case. You are right. When a datanode is dead
for a long time, SCM actually won't remove it from its registration list. So
when this node with the same uuid comes up again with different IP, it will
fall to update address condition, instead of registering new node.
However, there is another case. If the SCM also restarts, then it will lose
all its in memory node registration map, but it still have all the old
pipelines since pipelines are read from persistent. So in this case, if the
datanode changes its IP, and come to register with SCM, SCM will treat it as a
new node instead of a known node with different IP. So in this case, we still
need to close all the stale pipelines which has the old IPs for this datanode.
Please let me know if my above statement makes sense to you. Thanks!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]