Close disconnects all clients and cleans up resources.
()
| 225 | |
| 226 | // Close disconnects all clients and cleans up resources. |
| 227 | func (m *GroupClientManager) Close() { |
| 228 | m.mu.Lock() |
| 229 | defer m.mu.Unlock() |
| 230 | |
| 231 | for name, pc := range m.clients { |
| 232 | pc.SetStatus(ProfileStatusDisconnected, nil) |
| 233 | m.logger.Debug("Disconnected from profile %s", name) |
| 234 | } |
| 235 | |
| 236 | m.clients = make(map[string]*ProfileClient) |
| 237 | } |
| 238 | |
| 239 | // ConnectionSummary represents the connection status of the group. |
| 240 | type ConnectionSummary struct { |