时间轮

This commit is contained in:
meixiongfeng 2023-06-15 21:35:32 +08:00
parent e6ecb1e31d
commit 5903234295

View File

@ -185,7 +185,10 @@ func (this *TimeWheel) handleTick() {
}
if task.async {
go this.calltask(task, task.args...)
go func(task *Task) {
go this.calltask(task, task.args...)
}(task)
} else {
// optimize gopool
this.calltask(task, task.args...)