Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { // GoroutinePoolSize maximum number of running goroutine instances. GoPoolSize int `yaml:"goPoolSize" json:"goPoolSize"` // Size size of queue. If it exhausted Submit returns error. Size int `yaml:"size" json:"size"` // MaxIdleTime sets up the interval time of cleaning up goroutines, 0 means never cleanup. MaxIdleTime time.Duration `yaml:"maxIdleTime" json:"maxIdleTime"` }
Config configuration for task queue.
type Queue ¶
type Queue struct {
// contains filtered or unexported fields
}
Queue representation of task queue.
func (*Queue) SubmitForOneWorker ¶ added in v2.2.4
SubmitForOneWorker function adds tasks to the Queue by key. The tasks in the Queue are executed in the order they are submitted by the Goroutine.
Click to show internal directories.
Click to hide internal directories.