Commit 4c57934f authored by vicotor's avatar vicotor

close resource check

parent 8f1d135d
......@@ -393,6 +393,7 @@ func (n *Node) PopWorker(ctx context.Context, rdb *redis.Client, task *odysseus.
priority: i,
managers: managerList,
}
if false {
if !checkWorkerHasResource(rdb, worker.addr, task.TaskType) {
n.addWorkerBack(worker)
if checked := checkedWorker[worker.workerid]; checked {
......@@ -402,6 +403,7 @@ func (n *Node) PopWorker(ctx context.Context, rdb *redis.Client, task *odysseus.
continue
}
}
}
return worker, nil
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment