From 0cffbeda8ccbe9186bceb0594769aa9ee10209d7 Mon Sep 17 00:00:00 2001 From: Adrian Nackov Date: Tue, 28 Jan 2025 09:20:15 +0000 Subject: [PATCH] Reference #1258: fix timestamp debug message --- pkg/workceptor/kubernetes.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkg/workceptor/kubernetes.go b/pkg/workceptor/kubernetes.go index c766685ff..b2d6872bf 100644 --- a/pkg/workceptor/kubernetes.go +++ b/pkg/workceptor/kubernetes.go @@ -416,12 +416,13 @@ func (kw *KubeUnit) KubeLoggingWithReconnect(streamWait *sync.WaitGroup, stdout msg := line timestamp := ParseTime(split[0]) if timestamp != nil { - kw.GetWorkceptor().nc.GetLogger().Debug("No timestamp received, log line: '%s'", line) if !timestamp.After(sinceTime) && !successfulWrite { continue } sinceTime = *timestamp msg = split[1] + } else { + kw.GetWorkceptor().nc.GetLogger().Debug("No timestamp received, log line: '%s'", line) } _, err = stdout.Write([]byte(msg))