From 6fd6219b294f8419b47aa18aac8909b9b812eb07 Mon Sep 17 00:00:00 2001 From: Rawlin Peters Date: Wed, 13 Apr 2022 00:41:42 -0600 Subject: [PATCH 1/2] Fix TM issue where CRConfig is never updated PR #6625 reduced the TM dependency on CRConfig data, but it accidentally caused TM to no longer poll for new CRConfig snapshots. This adds the CRConfig request back into the polling loop so that it updates its in-memory copy for internal use (if necessary) and for serving to TR. --- traffic_monitor/poller/monitorconfig.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/traffic_monitor/poller/monitorconfig.go b/traffic_monitor/poller/monitorconfig.go index 639cf6a346..5f4f04eafc 100644 --- a/traffic_monitor/poller/monitorconfig.go +++ b/traffic_monitor/poller/monitorconfig.go @@ -112,6 +112,11 @@ func (p MonitorConfigPoller) Poll() { log.Errorf("MonitorConfigPoller: %s\n %v\n", err, monitorConfig) continue } + // poll the CRConfig so that it is synchronized with the TMConfig + if _, err := p.Session.CRConfigRaw(p.OpsConfig.CdnName); err != nil { + log.Errorf("MonitorConfigPoller: error getting CRConfig: %v", err) + continue + } p.writeConfig(MonitorCfg{CDN: p.OpsConfig.CdnName, Cfg: *monitorConfig}) } } From 9daaed59d8fbdd4106a20558bce83b6a1bab67a8 Mon Sep 17 00:00:00 2001 From: Rawlin Peters Date: Wed, 13 Apr 2022 10:56:29 -0600 Subject: [PATCH 2/2] Add --buildvcs=false to 'go test' action --- .github/actions/go-test/entrypoint.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/actions/go-test/entrypoint.sh b/.github/actions/go-test/entrypoint.sh index 3594a68463..0da9a0a561 100755 --- a/.github/actions/go-test/entrypoint.sh +++ b/.github/actions/go-test/entrypoint.sh @@ -37,5 +37,5 @@ fi # Need to fetch golang.org/x/* dependencies go mod vendor -v -go test $INPUT_DIR +go test --buildvcs=false $INPUT_DIR exit $?