HDDS-7341. EC: Close pipelines with unregistered nodes#3850
Merged
sodonnel merged 3 commits intoapache:masterfrom Oct 19, 2022
Merged
HDDS-7341. EC: Close pipelines with unregistered nodes#3850sodonnel merged 3 commits intoapache:masterfrom
sodonnel merged 3 commits intoapache:masterfrom
Conversation
errose28
approved these changes
Oct 18, 2022
Contributor
There was a problem hiding this comment.
nit. I see other tests doing this as well but I'm not sure it's necessary since createPipelineManager(boolean) is passing this variable to the PipelineManagerImpl constructor.
Contributor
Author
There was a problem hiding this comment.
You are correct. I just copied the new test from an old one and adapted. I have removed that line from all the tests and they all pass locally.
Member
There was a problem hiding this comment.
At that time with Junit4, I had some issues with the test running, So I added it. I just checked now it is safe to remove. Thanks for cleaning it up @sodonnel.
captainzmc
pushed a commit
that referenced
this pull request
Oct 20, 2022
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changes were proposed in this pull request?
A datanode is stopped and before the stale node handler is triggered, SCM is restarted. When SCM restarts its loads all the only pipelines and nodes from RocksDB, and then all the nodes will register again.
In the case of EC pipelines, there is nothing to trigger the close of a pipeline (and the containers on it) except:
In the case above, the EC pipeline will sit forever in an Open state, but any attempt to write to it will likely result in errors on the client due to one of the nodes not being available. These errors still will not trigger it to close.
A solution to this problem, is to add logic to the pipeline scrubber to close any pipelines that have unregistered nodes. Stale / Dead nodes should be handled by the existing stale / dead node handlers.
What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-7341
How was this patch tested?
New unit test and validated on a docker compose cluster.