From cdce452edc5e9cf9127789a868d01864d3276af5 Mon Sep 17 00:00:00 2001 From: Matthew Holt Date: Thu, 4 May 2023 16:30:34 -0600 Subject: logging: Actually honor the SoftStart parameter --- modules/logging/netwriter.go | 3 +++ 1 file changed, 3 insertions(+) (limited to 'modules/logging') diff --git a/modules/logging/netwriter.go b/modules/logging/netwriter.go index 954a09b..1939cb7 100644 --- a/modules/logging/netwriter.go +++ b/modules/logging/netwriter.go @@ -97,6 +97,9 @@ func (nw NetWriter) OpenWriter() (io.WriteCloser, error) { } conn, err := reconn.dial() if err != nil { + if !nw.SoftStart { + return nil, err + } // don't block config load if remote is down or some other external problem; // we can dump logs to stderr for now (see issue #5520) fmt.Fprintf(os.Stderr, "[ERROR] net log writer failed to connect: %v (will retry connection and print errors here in the meantime)\n", err) -- cgit v1.2.3