diff --git a/lbcd.go b/lbcd.go index 1110eeab..b9606653 100644 --- a/lbcd.go +++ b/lbcd.go @@ -281,7 +281,9 @@ func main() { // limits the garbage collector from excessively overallocating during // bursts. This value was arrived at with the help of profiling live // usage. - debug.SetGCPercent(10) + if _, ok := os.LookupEnv("GOGC"); !ok { + debug.SetGCPercent(10) + } // Up some limits. if err := limits.SetLimits(); err != nil {