(ctx context.Context, address ...string)
| 31 | } |
| 32 | |
| 33 | func (m *imlClusterModule) CheckCluster(ctx context.Context, address ...string) ([]*cluster_dto.Node, error) { |
| 34 | info, err := admin.Admin(address...).Info(ctx) |
| 35 | if err != nil { |
| 36 | return nil, err |
| 37 | } |
| 38 | nodesOut := utils.SliceToSlice(info.Nodes, func(i *admin.Node) *cluster_dto.Node { |
| 39 | return &cluster_dto.Node{ |
| 40 | Id: i.Id, |
| 41 | Name: i.Name, |
| 42 | Admins: i.Admin, |
| 43 | Peers: i.Peer, |
| 44 | Gateways: i.Server, |
| 45 | } |
| 46 | }) |
| 47 | nodeStatus(ctx, nodesOut) |
| 48 | |
| 49 | return nodesOut, nil |
| 50 | } |
| 51 | |
| 52 | func (m *imlClusterModule) ResetCluster(ctx context.Context, clusterId string, address string) ([]*cluster_dto.Node, error) { |
| 53 |
nothing calls this directly
no test coverage detected