set up context name for ampool
This commit is contained in:
@@ -266,7 +266,8 @@ func main() {
|
|||||||
ctx = context.WithValue(ctx, CONTEXTVAL_NAME, "main")
|
ctx = context.WithValue(ctx, CONTEXTVAL_NAME, "main")
|
||||||
|
|
||||||
// Set up ampool.
|
// Set up ampool.
|
||||||
ampool = util.AmNewPool(ctx, config.GlobalConfig.Tuning.WorkerTasks, config.GlobalConfig.Tuning.Queues.WorkerTasks)
|
ampool = util.AmNewPool(context.WithValue(ctx, CONTEXTVAL_NAME, "ampool"), config.GlobalConfig.Tuning.WorkerTasks,
|
||||||
|
config.GlobalConfig.Tuning.Queues.WorkerTasks)
|
||||||
go func() {
|
go func() {
|
||||||
<-ctx.Done()
|
<-ctx.Done()
|
||||||
ampool.Shutdown()
|
ampool.Shutdown()
|
||||||
|
|||||||
Reference in New Issue
Block a user