From bf472d3df9f5e1c12f18f2fb848ef42026dc5ea4 Mon Sep 17 00:00:00 2001 From: DarthSim Date: Thu, 1 Dec 2022 01:42:47 +0600 Subject: [PATCH] Use runtime.GOMAXPROCS to calc default concurrency --- config/config.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config/config.go b/config/config.go index 57b2590f..38946318 100644 --- a/config/config.go +++ b/config/config.go @@ -203,7 +203,7 @@ func Reset() { KeepAliveTimeout = 10 ClientKeepAliveTimeout = 90 DownloadTimeout = 5 - Concurrency = runtime.NumCPU() * 2 + Concurrency = runtime.GOMAXPROCS(0) * 2 RequestsQueueSize = 0 MaxClients = 2048