404
}
405
406
>
func newTaskQueueConfig(tq *tqid.TaskQueue, config *Config, ns namespace.Name) *taskQueueConfig {
config.go
407
>
taskQueueName := tq.Name()
408
>
taskType := tq.TaskType()
409
>
priorityLevels := priorityKey(config.PriorityLevels(ns.String(), taskQueueName, taskType))
410
>
priorityLevels = max(priorityLevels, min(priorityLevels, maxPriorityLevels), 1)
411
>
defaultPriorityKey := (priorityLevels + 1) / 2
412
>
413
>
return &taskQueueConfig{
414
>
RangeSize: config.RangeSize,
415
>
NewMatcherSub: func(cb func(dynamicconfig.GradualChange[bool])) (dynamicconfig.GradualChange[bool], func()) {
416
return config.NewMatcherSub(ns.String(), taskQueueName, taskType, cb)
417
},