-
Notifications
You must be signed in to change notification settings - Fork 11
Manager
Zheng Lv edited this page Jun 26, 2016
·
4 revisions
Manager is in charge of dispatching workers.
Manager holds worker instances. At Run(), Manager starts all its workers
with worker.RunSync(). It polls all the workers at a specified interval. It
triggers a worker to sync if the worker has been idle for another specified
interval. (The interval can be configured per worker. See
Configuration for details).
Start(), Stop() will temporarily resume, pause the Manager from polling
workers. Exit() will terminate RunSync() control flow. These three
functions are all synchronized.
Status holds the status of a manager and all its workers. GetStatus() can get
a snapshot (currently not atomic, however,) from a manager.