()
| 221 | } |
| 222 | |
| 223 | func (n *node) stopAllTasks() { |
| 224 | defer n.closer.Done() // CLOSER:1 |
| 225 | <-n.closer.HasBeenClosed() |
| 226 | |
| 227 | glog.Infof("Stopping all ongoing registered tasks...") |
| 228 | n.opsLock.Lock() |
| 229 | defer n.opsLock.Unlock() |
| 230 | for op, closer := range n.ops { |
| 231 | glog.Infof("Stopping op: %s...\n", op) |
| 232 | closer.SignalAndWait() |
| 233 | } |
| 234 | glog.Infof("Stopped all ongoing registered tasks.") |
| 235 | } |
| 236 | |
| 237 | // GetOngoingTasks returns the list of ongoing tasks. |
| 238 | func GetOngoingTasks() []string { |
no test coverage detected