[metasrv] feature: leave a cluster with databend-meta --leave..
#6181
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.
Inform a cluster to remove a node from it:
databend-meta --leave-id <node_id_to_remove> --leave-via <node_addr_1> <node_addr_2>...
databend-meta --leave-via
will try to remove the node and quit at once.--leave-via
specifies a list of the nodeadvertise
addresses to send theleave
request to.See:
--raft_advertise_host
--leave-id
specifies the node id to leave. It can be any id in a cluster.An CI of join/leave is added to ./tests/meta-cluster/
Add doc
docs/doc/50-manage/00-metasrv/20-metasrv-add-remove-node.md
about how to remove a node from the clusterOther refactoring:
MetaRaftError::JoinClusterFail
, useMetaError::MetaServiceError
instead.I hereby agree to the terms of the CLA available at: https://databend.rs/dev/policies/cla/
Summary
Summary about this PR
Changelog
Related Issues
metactl
to remove a node from a cluster. #4988