()
| 225 | } |
| 226 | |
| 227 | stopMonitor() { |
| 228 | const monitor = this.monitor; |
| 229 | |
| 230 | this.isStopped = true; |
| 231 | if (this.timer) { |
| 232 | clearTimeout(this.timer); |
| 233 | this.timer = null; |
| 234 | } |
| 235 | |
| 236 | logger.info(`Stop monitor ${monitor.name}(${monitor.id})`); |
| 237 | } |
| 238 | |
| 239 | async restartMonitor() { |
| 240 | this.stopMonitor(); |
no test coverage detected