We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents a6bce63 + cb2aca0 commit 3c1740fCopy full SHA for 3c1740f
pool.go
@@ -20,10 +20,9 @@ type pool struct {
20
}
21
22
// Delegate job to a workers
23
+// will block if channel is full, you might want to wrap it with goroutine to avoid it
24
func (p *pool) Delegate(args ...interface{}) {
- go func() {
25
- p.queue <- buildQueueValue(args)
26
- }()
+ p.queue <- buildQueueValue(args)
27
28
29
// Start given number of workers that will take jobs from a queue
0 commit comments