app/vmselect/netstorage: reduce contention on unpackworkCh and timeseriesWorkCh for multi-CPU system by providing more capacity for these chans

This commit is contained in:
Aliaksandr Valialkin 2020-08-06 17:22:10 +03:00
parent 13f8644f8e
commit 46c98cd97a

View File

@ -71,7 +71,7 @@ func (rss *Results) Cancel() {
rss.tbf = nil rss.tbf = nil
} }
var timeseriesWorkCh = make(chan *timeseriesWork, gomaxprocs) var timeseriesWorkCh = make(chan *timeseriesWork, gomaxprocs*16)
type timeseriesWork struct { type timeseriesWork struct {
rss *Results rss *Results
@ -169,7 +169,7 @@ type packedTimeseries struct {
addrs []tmpBlockAddr addrs []tmpBlockAddr
} }
var unpackWorkCh = make(chan *unpackWork, gomaxprocs) var unpackWorkCh = make(chan *unpackWork, gomaxprocs*128)
type unpackWork struct { type unpackWork struct {
tbf *tmpBlocksFile tbf *tmpBlocksFile