performance improvement and small fix on loadbalancer

This commit is contained in:
yusing
2024-10-09 18:10:51 +08:00
parent 5c40f4aa84
commit d91b66ae87
11 changed files with 77 additions and 50 deletions

View File

@@ -133,7 +133,7 @@ func ConnectClient(host string) (Client, E.NestedError) {
}
func CloseAllClients() {
clientMap.RangeAll(func(_ string, c Client) {
clientMap.RangeAllParallel(func(_ string, c Client) {
c.Client.Close()
})
clientMap.Clear()