/** * Stop running a task */ public function stop() { $this->_sleepFlag = false; $this->updateState(); $this->_tm->setStoped($this->_pid); $this->_tm->clearSignals($this->_pid); if (!is_null($this->_logger)) { $this->_logger->log('stop'); } exit; }