Skip to content

Commit

Permalink
change service states logging level to notice (#52)
Browse files Browse the repository at this point in the history
  • Loading branch information
Mararok authored Jan 16, 2020
1 parent d3b5778 commit e7557eb
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/SAREhub/Commons/Service/ServiceSupport.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,11 @@ abstract class ServiceSupport implements Service
public function start()
{
if (!$this->isStarted()) {
$this->getLogger()->info('service starting ...');
$this->getLogger()->notice('service starting ...');
$this->doStart();
$this->started = true;
$this->stopped = false;
$this->getLogger()->info('service started');
$this->getLogger()->notice('service started');
}
}

Expand All @@ -37,7 +37,7 @@ public function tick()
try {
$this->stop();
} catch (\Exception $e2) {
// we wants only orginal exception
// we wants only original exception
}

throw $e;
Expand All @@ -48,12 +48,12 @@ public function stop()
{
if ($this->isStarted()) {
try {
$this->getLogger()->info('service stopping ...');
$this->getLogger()->notice('service stopping ...');
$this->doStop();
} finally {
$this->started = false;
$this->stopped = true;
$this->getLogger()->info('service stopped');
$this->getLogger()->notice('service stopped');
}
}
}
Expand Down Expand Up @@ -114,4 +114,4 @@ protected function doStop()
{

}
}
}

0 comments on commit e7557eb

Please sign in to comment.