Cleanup: no need for stacked timing loops

pull/6/head
Daniel Smith 2014-06-20 12:57:22 -07:00
parent 5de9071b5c
commit d57531d924
1 changed files with 1 additions and 8 deletions

View File

@ -85,14 +85,7 @@ func (p *PodCache) UpdateAllContainers() {
}
}
func (p *PodCache) synchronizeContainers() {
ticker := time.Tick(p.period)
for _ = range ticker {
p.UpdateAllContainers()
}
}
// Loop runs forever, it is expected to be placed in a go routine.
func (p *PodCache) Loop() {
util.Forever(func() { p.synchronizeContainers() }, 0)
util.Forever(func() { p.UpdateAllContainers() }, p.period)
}