Chore: adjust batch

This commit is contained in:
Dreamacro
2021-07-23 00:30:23 +08:00
parent 4578b2c826
commit 09697b7679
3 changed files with 8 additions and 13 deletions

View File

@ -59,7 +59,7 @@ func (hc *HealthCheck) touch() {
}
func (hc *HealthCheck) check() {
b := batch.New(batch.WithConcurrencyNum(10))
b, _ := batch.New(context.Background(), batch.WithConcurrencyNum(10))
for _, proxy := range hc.proxies {
p := proxy
b.Go(p.Name(), func() (interface{}, error) {