From 21a14bcc80c5715684f62188f16b5ec12821e668 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Rousseau Date: Mon, 19 Feb 2018 15:07:37 +0100 Subject: [PATCH] =?UTF-8?q?correction=20niveau=20de=20log=20(passage=20de?= =?UTF-8?q?=20info=20=C3=A0=20debug)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Foundation/Fuse/Handler/CommandHandler.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/Digitick/Foundation/Fuse/Handler/CommandHandler.php b/src/Digitick/Foundation/Fuse/Handler/CommandHandler.php index 18f0c04..1728297 100644 --- a/src/Digitick/Foundation/Fuse/Handler/CommandHandler.php +++ b/src/Digitick/Foundation/Fuse/Handler/CommandHandler.php @@ -65,19 +65,19 @@ public function execute (AbstractCommand $command) { try { $result = $this->executeCommand($command); - $this->log(LogLevel::INFO, "Success for command group " . $command->getKey()); + $this->log(LogLevel::DEBUG, "Success for command group " . $command->getKey()); $this->circuitBreaker->reportSuccess($command->getKey()); if ($isCacheable) { $this->log(LogLevel::DEBUG, "Store result in cache. Key = $cacheKey"); $this->cacheManager->set($cacheKey, $result, $command->getTtl()); } } catch (LogicException $exc) { - $this->log(LogLevel::DEBUG, "Logic exception. Call onLogicError"); - $this->log(LogLevel::INFO, "Success for command group " . $command->getKey()); - $this->circuitBreaker->reportSuccess($commaqnd->getKey()); + $this->log(LogLevel::ERROR, "Logic exception. Call onLogicError"); + $this->log(LogLevel::ERROR, "Failure for command group " . $command->getKey()); + $this->circuitBreaker->reportSuccess($command->getKey()); return $command->onLogicError($exc); } catch (ServiceException $exc) { - $this->log(LogLevel::DEBUG, "Service exception. Call onServiceError"); + $this->log(LogLevel::ERROR, "Service exception. Call onServiceError"); $this->log(LogLevel::ERROR, "Failure for command group " . $command->getKey()); $this->circuitBreaker->reportFailure($command->getKey()); return $command->onServiceError($exc);