From da82aa9fc578a3c5ceedfba43facab0011f9b502 Mon Sep 17 00:00:00 2001 From: "Fabian @ Blax Software" Date: Thu, 11 Dec 2025 11:31:14 +0100 Subject: [PATCH] IA logging, BH restart --- src/Console/Commands/RestartServer.php | 2 ++ src/Console/Commands/StartServer.php | 5 ++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/src/Console/Commands/RestartServer.php b/src/Console/Commands/RestartServer.php index bb64c98..90cb643 100644 --- a/src/Console/Commands/RestartServer.php +++ b/src/Console/Commands/RestartServer.php @@ -31,6 +31,8 @@ class RestartServer extends Command */ public function handle() { + \Log::channel('websocket')->info('WebSocket restart server command called ...'); + Cache::forever( 'blax:websockets:restart', $this->currentTime() diff --git a/src/Console/Commands/StartServer.php b/src/Console/Commands/StartServer.php index a50a315..39e4c08 100644 --- a/src/Console/Commands/StartServer.php +++ b/src/Console/Commands/StartServer.php @@ -185,7 +185,10 @@ class StartServer extends Command $this->lastRestart = $this->getLastRestart(); $this->loop->addPeriodicTimer(10, function () { - if ($this->getLastRestart() !== $this->lastRestart) { + if ( + ($this->getLastRestart() . '') + !== ($this->lastRestart . '') + ) { \Log::channel('websocket')->info('Restart detected, triggering soft shutdown...', [ 'previous_restart' => $this->lastRestart, 'current_restart' => $this->getLastRestart(),