package
Version:
v0.0.0-...-30e45d9
Opens a new window with list of versions in this module.
Published: Feb 6, 2017
License: Apache-2.0
Opens a new window with license information.
Imports: 2
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
Job represents job
func NewJob(task func()) Job
NewJob creates new Job
Queue manages workers and job
NewQueue makes new manager
func (queue *Queue) ForceStop()
ForceStop forces job manager without waiting job complete
func (queue *Queue) Stop()
Stop stops all worker after all job get done
func (queue *Queue) Wait()
Wait until all job get done
type Worker struct {
CloseCh chan bool
}
Worker subcribes manager's work queue and execute it
NewWorker makes new working process
Source Files
¶
Click to show internal directories.
Click to hide internal directories.