From 1558edbc3cee850a6493b8764faa153d7fb09beb Mon Sep 17 00:00:00 2001 From: Oliver Gugger Date: Fri, 4 Sep 2020 14:10:03 +0200 Subject: [PATCH] travis+lint: fix memory usage There is a setting to control how often the garbage collector is run. Apparently this is a tradeoff between CPU and memory usage. If we can limit the memory being used in that way, this allows us to use multiple worker again, so overall this shouldn't be much slower than before. --- .golangci.yml | 2 +- .travis.yml | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.golangci.yml b/.golangci.yml index 1ffef44bb..ee9246b2a 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -1,6 +1,6 @@ run: # timeout for analysis - deadline: 4m + deadline: 10m # Skip autogenerated files for mobile. skip-files: diff --git a/.travis.yml b/.travis.yml index fd3f54468..ad87c7993 100644 --- a/.travis.yml +++ b/.travis.yml @@ -44,8 +44,8 @@ jobs: # in a GitHub Workflow. - make unit pkg=... case=_NONE_ - # Step 3: Lint go code. Limit to 1 worker to reduce memory usage. - - make lint workers=1 + # Step 3: Lint go code. Invoke GC more often to reduce memory usage. + - GOGC=30 make lint - stage: Integration Test name: Btcd Integration