Skip to content

HDDS-9511. Handle DataNode decommissioning error for hoststring and port.#5469

Merged
adoroszlai merged 2 commits intoapache:masterfrom
ashishkumar50:HDDS-9511
Oct 23, 2023
Merged

HDDS-9511. Handle DataNode decommissioning error for hoststring and port.#5469
adoroszlai merged 2 commits intoapache:masterfrom
ashishkumar50:HDDS-9511

Conversation

@ashishkumar50
Copy link
Contributor

What changes were proposed in this pull request?

When decommission command is executed and if port or hostname is wrong and doesn't present in SCM, in that case command retries for 300 times which is unnecessary.
In this PR we are fixing below:
If hoststring or port is wrong, instead of throwing exception we are returning DataNodeAdmin error which will avoid retry and will be normal exit.
If there are multiple hosts passed in the command, hosts which are invalid we add into error list and continue decommissioning for the proper host.

What is the link to the Apache JIRA

https://issues.apache.org/jira/browse/HDDS-9511

How was this patch tested?

Update existing tests and verify

@adoroszlai adoroszlai requested a review from sodonnel October 22, 2023 16:30
Copy link
Contributor

@sodonnel sodonnel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. I don't recall why I made other errors be returned in the DatanodeAdminErrors, but the initial host parsing not. However I believe it makes sense to make this change.

+1 pending green CI.

@adoroszlai adoroszlai merged commit 2f9f771 into apache:master Oct 23, 2023
@adoroszlai
Copy link
Contributor

Thanks @ashishkumar50 for the patch, @sodonnel for the review.

ibrusentsev pushed a commit to ibrusentsev/ozone that referenced this pull request Nov 14, 2023
jojochuang pushed a commit to jojochuang/ozone that referenced this pull request Feb 1, 2024
…string and port. (apache#5469)

(cherry picked from commit 2f9f771)
Change-Id: I114616fdf2554bf50da59d3cc97270d4db246738
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants