Skip to content

Commit

Permalink
exporting recluster function
Browse files Browse the repository at this point in the history
  • Loading branch information
tanmayja committed Apr 22, 2024
1 parent 6fef589 commit b1907ad
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions deployment/aeroinfo.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,16 @@ func InfoQuiesceUndo(log logr.Logger, policy *aero.ClientPolicy, allHosts []*Hos
return c.InfoQuiesceUndo(getHostIDsFromHostConns(allHosts))
}

// InfoRecluster recluster hosts.
func InfoRecluster(log logr.Logger, policy *aero.ClientPolicy, allHosts []*HostConn) error {
c, err := newCluster(log, policy, allHosts, allHosts)
if err != nil {
return fmt.Errorf("unable to create a cluster copy for running aeroinfo: %v", err)
}

return c.InfoRecluster(getHostIDsFromHostConns(allHosts))
}

// GetQuiescedNodes returns a list of node hostIDs of all nodes that are pending_quiesce=true.
func GetQuiescedNodes(log logr.Logger, policy *aero.ClientPolicy, allHosts []*HostConn) ([]string, error) {
c, err := newCluster(log, policy, allHosts, allHosts)
Expand Down

0 comments on commit b1907ad

Please sign in to comment.