Skip to content

Commit

Permalink
PWX-37595: honour force flag over node status
Browse files Browse the repository at this point in the history
Signed-off-by: sanjain <[email protected]>
  • Loading branch information
sanjain-px committed Aug 29, 2024
1 parent 2d20853 commit 01748bf
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion cluster/manager/manager.go
Original file line number Diff line number Diff line change
Expand Up @@ -1830,7 +1830,8 @@ func (c *ClusterManager) Remove(nodes []api.Node, forceRemove bool) error {
// If node is not down, do not remove it
if nodeCacheStatus != api.Status_STATUS_OFFLINE &&
nodeCacheStatus != api.Status_STATUS_MAINTENANCE &&
nodeCacheStatus != api.Status_STATUS_DECOMMISSION {
nodeCacheStatus != api.Status_STATUS_DECOMMISSION &&
!forceRemove {

msg := fmt.Sprintf(decommissionErrMsg, nodes[i].Id)
logrus.Errorf(msg+", node status: %s", nodeCacheStatus)
Expand Down

0 comments on commit 01748bf

Please sign in to comment.