Skip to content
This repository has been archived by the owner on Nov 1, 2022. It is now read-only.

Commit

Permalink
Merge pull request #700 from weaveworks/remove-git-poll-loop-verbose-…
Browse files Browse the repository at this point in the history
…logging

Remove git poll loop verbose logging
  • Loading branch information
Sam Broughton committed Aug 21, 2017
2 parents f86f7ba + d1e2ca7 commit 891b3d6
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions daemon/loop.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,35 +51,28 @@ func (d *Daemon) GitPollLoop(stop chan struct{}, wg *sync.WaitGroup, logger log.
}

imagePollTimer := time.NewTimer(d.RegistryPollInterval)
loopLogger := log.NewContext(logger).With("thing", "git-poll-loop")

// Ask for a sync, and to poll images, straight away
d.askForSync()
d.askForImagePoll()
for {
select {
case <-stop:
loopLogger.Log("case", "stop")
logger.Log("stopping", "true")
return
case <-d.pollImagesSoon:
loopLogger.Log("case", "pollImagesSoon")
d.pollForNewImages(logger)
imagePollTimer.Stop()
imagePollTimer = time.NewTimer(d.RegistryPollInterval)
case <-imagePollTimer.C:
loopLogger.Log("case", "imagePollTimer")
d.askForImagePoll()
case <-d.syncSoon:
loopLogger.Log("case", "syncSoon")
pullThen(d.doSync)
case <-gitPollTimer.C:
loopLogger.Log("case", "gitPollTimer")
// Time to poll for new commits (unless we're already
// about to do that)
d.askForSync()
case job := <-d.Jobs.Ready():
loopLogger.Log("case", "jobReady")
jobLogger := log.NewContext(logger).With("jobID", job.ID)
jobLogger.Log("state", "in-progress")
// It's assumed that (successful) jobs will push commits
Expand Down

0 comments on commit 891b3d6

Please sign in to comment.