refactor the code of resource list function

This commit is contained in:
richardxz
2018-09-17 10:24:01 +08:00
parent f7e607a14c
commit 4bd18b072c
25 changed files with 1564 additions and 306 deletions

View File

@@ -133,7 +133,7 @@ func checkAndResync(ctl Controller, stopChan chan struct{}) {
func listAndWatch(ctl Controller) {
defer handleCrash(ctl)
defer ctl.CloseDB()
stopChan := make(chan struct{})
go ctl.sync(stopChan)