Skip to content

Commit 49b02be

Browse files
committed
fix: keep the watcher boot-failure log at error level
Review feedback: the mismatched guard in the watcher-enabled boot-failure path was aligned downwards, to warn. Align it upwards instead and keep the message at error, since it reports a failure during boot rather than a termination at steady state. The sibling "worker script has failed on restart" branch stays at warn: it was already self-consistent and outside this change's scope. Happy to raise that one too if the same reasoning should apply to it.
1 parent dd2d832 commit 49b02be

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

threadworker.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -177,8 +177,8 @@ func tearDownWorkerScript(handler *workerThread, exitStatus int) {
177177

178178
if watcherIsEnabled {
179179
// worker script has probably failed due to script changes while watcher is enabled
180-
if globalLogger.Enabled(globalCtx, slog.LevelWarn) {
181-
globalLogger.LogAttrs(globalCtx, slog.LevelWarn, "(watcher enabled) worker script has not reached frankenphp_handle_request()", slog.String("worker", worker.name), slog.Int("thread", handler.thread.threadIndex))
180+
if globalLogger.Enabled(globalCtx, slog.LevelError) {
181+
globalLogger.LogAttrs(globalCtx, slog.LevelError, "(watcher enabled) worker script has not reached frankenphp_handle_request()", slog.String("worker", worker.name), slog.Int("thread", handler.thread.threadIndex))
182182
}
183183
} else {
184184
// rare case where worker script has failed on a restart during normal operation

0 commit comments

Comments
 (0)