* call debug.FreeOSMemory() once in 5 minutes

This commit is contained in:
Simon Zolin 2020-09-04 14:23:51 +03:00
parent 45745943a5
commit 781f011419

View file

@ -40,7 +40,7 @@ func memoryUsage() {
// periodically call "debug.FreeOSMemory" so
// that the OS could reclaim the free memory
go func() {
ticker := time.NewTicker(15 * time.Second)
ticker := time.NewTicker(5 * time.Minute)
for {
select {
case t := <-ticker.C: