Commit 827fa450 authored by Erick Hitter's avatar Erick Hitter
Browse files

Update per review feedback

parent f89d912d
...@@ -111,7 +111,7 @@ func spawnEventWorkers(queue <-chan event) { ...@@ -111,7 +111,7 @@ func spawnEventWorkers(queue <-chan event) {
} }
func retrieveSitesPeriodically(sites chan<- site) { func retrieveSitesPeriodically(sites chan<- site) {
for true { for {
siteList, err := getSites() siteList, err := getSites()
if err != nil { if err != nil {
time.Sleep(getEventsLoop) time.Sleep(getEventsLoop)
...@@ -135,7 +135,7 @@ func heartbeat() { ...@@ -135,7 +135,7 @@ func heartbeat() {
interval := time.Duration(heartbeatInt) * time.Second interval := time.Duration(heartbeatInt) * time.Second
time.Sleep(interval) time.Sleep(interval)
for true { for {
successCount, errCount := atomic.LoadUint64(&eventRunSuccessCount), atomic.LoadUint64(&eventRunErrCount) successCount, errCount := atomic.LoadUint64(&eventRunSuccessCount), atomic.LoadUint64(&eventRunErrCount)
atomic.SwapUint64(&eventRunSuccessCount, 0) atomic.SwapUint64(&eventRunSuccessCount, 0)
atomic.SwapUint64(&eventRunErrCount, 0) atomic.SwapUint64(&eventRunErrCount, 0)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment