- tasksch中,任务完成后要将worker置空,否则被管理的任务的worker会hold住大量对象
This commit is contained in:
@@ -24,6 +24,6 @@ func (m *SyncMapWithTimeout) Delete(key interface{}) {
|
||||
if value, ok := m.timers.Load(key); ok {
|
||||
timer := value.(*time.Timer)
|
||||
timer.Stop()
|
||||
m.timers.Delete(key)
|
||||
}
|
||||
m.timers.Delete(key)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user